Accepts a pikchr script as input and outputs the rendered script as an SVG graphic. The INFILE and OUTFILE options default to stdin resp. stdout, and the names "-" can be used as aliases for those streams.
- On success, adds a DIV wrapper around the resulting SVG output which limits its max-width to its computed maximum ideal size.
- Like -div but indents the div.
- Like -div but centers the div.
- Like -div but floats the div left.
- Like -div but floats the div right.
- Sets the 'source' CSS class on the div, which tells CSS to hide the SVG and reveal the source by default.
- Stores the input pikchr's source code in the output as a separate element adjacent to the SVG one. Implied by -div-source.
- Process the input using TH1 before passing it to pikchr.
- Disable $var and $<var> TH1 processing. Use this if the pikchr script uses '$' for its own purposes and that causes issues. This only affects parsing of '$' outside of TH1 script blocks. Code in such blocks is unaffected.
- When using -th, output the post-TH1'd script instead of the pikchr-rendered output.
- Trace TH1 execution (for debugging purposes).
The -div-indent/center/left/right flags may not be combined.
TH1-related Notes and Caveats:
If the -th flag is used, this command must open a fossil database for certain functionality to work (via a checkout or the -R REPO flag). If opening a db fails, execution will continue but any TH1 commands which require a db will trigger a fatal error.
In Fossil skins, TH1 variables in the form $varName are expanded as-is and those in the form $<varName> are htmlized in the resulting output. This processor disables the htmlizing step, so $x and $<x> are equivalent unless the TH1-processed pikchr script invokes the TH1 command [enable_htmlify 1] to enable it. Normally that option will interfere with pikchr output, however, e.g. by HTML-encoding double-quotes.
Many of the fossil-installed TH1 functions simply do not make any sense for pikchr scripts.