Fixed bug #1 in the mathtex branch as well.