Some custom tex evironment expansion