move most of dumpTextPass to an include file so it can be subclassed