ppOpt

Definition: ppOpt(sequence options)
Description: Permanently (or until next ppOpt call) change selected formatting options.
Comments: The options are specified as a pair-sequence, selected from:

Odd element Even element
pp_File 0:no output (used by ppf())
1:display to Screen (the default),
n:an open file handle
pp_Nest nest level (see main page for examples), default 0
pp_Maxlen Split lines at column, default 78
pp_Indent Auto-indent amount, default 0
pp_Pause Pause every n lines, default=23. Specify 0 for no pause
pp_StrFmt  0: print strings as eg "abc" (default)
-1: ditto, but without quotes.
-2: as 0, but chars number-only like +1
-3: as -1, ""
 1: as number only, eg {97, 98, 99}
 3: as number&text, eg {97a, 98b, 99c}
pp_IntFmt Integer format, default "%d". NB: applies to pp_StrFmt 1 as well.
pp_FltFmt Float format, default "%.10g"
Both pp_IntFmt and pp_FltFmt can contain extra text, eg "#%08x (integer)", "%04.1 km", or "%.2f US$"
When using these routines to format values which may or may not have a fractional element, both the integer and float formats should be set.
pp_Ascii Min/max ascii character, default {' ',#7F}
If sequences are passed, they define ranges.
Eg, for ISO 8859-1, use {{#20,#A0},{#7E,#FF}}, since characters 0..31 and 127..159 are system codes.
(Note it is {start1,start2,...},{end1,end2,...})
pp_Date "": no special date handling (Default)
"%04d-%02d-%02d": eg 2003-12-31
"%02d/%02d/%04d": eg 31/12/2003
Sequences of 3 integers, in the form {day,month,year} or {year,month,day},
with 1<=day<=31, 1<=month<=12, and 1900<=year<=3000 recognised as dates.
pp_Brkt "{}" (default) outputs '{' at the start of a (nested) sequence and '}' at the end.
Must be two characters.
pp_Q22 Show quotes as #22 (default 0, ie \")

 
The odd elements (first column) are builtin constants [automatically defined in psym.e/syminit()].
Example:
ppOpt({pp_StrFmt,0,pp_Nest,2,pp_Pause,0}})
ppOpt({pp_Maxlen,9999999})  -- stop ppf() putting \n in results.
See Also: pp, ppf