Support LaTeX in img.latex
Also, some utf8 support improvements.