Using Qt to convert handwriten math to Latex