Fix encoding bug in LaTeX for ">" characters