replace PsEngine wrapper class with namespace
simplify SaveAs TXT/PDF conversion checks