Ejemplo n.º 1
0
 def _current_str_list(self, pref=""):
     """Generates a list of strings formatted for displaying help
     Assumes that PhycasTablePrinter._reset_term_width has been called 
     more recently than the last terminal width change)."""
     if pref:
         dpref = pref + "."
     else:
         dpref = pref
     s = "OutFilter." + OutFilter.to_str(self.level)
     opts_help = [PhycasTablePrinter.format_help("%slevel" %dpref, s)]
     for n in self.__dict__["_help_order"]:
         a = self.__dict__[n]
         opts_help.append("")
         opts_help.extend(a._current_str_list("%s%s" % (dpref, n)))
     return opts_help
Ejemplo n.º 2
0
 def _write_latex(self, out, pref="", cmdname=""):
     out.write('\\begin{description}\n')
     out.write('\index{%s!%s.level}\item[\\bftt  %s.level] Controls the amount of output (verbosity) of the command (default: OutFilter.%s)\n' % (cmdname, pref, pref, OutFilter.to_str(self.level)))
     for n in self.__dict__["_help_order"]:
         a = self.__dict__[n]
         which = '%s.%s' % (pref,n)
         a._write_latex_item(out, which, cmdname)
     out.write('\\end{description}\n')