HTML Rule Sets

Top  Previous  Next

 

Like PCL rule sets, HTML rule sets are stored in a text file.  Each set is headed by a unique name in square brackets:

 

[AgingReport]

keywords…

 

UnForm selects a rule set to use based on either the "-r ruleset" command line option, or detect keywords in each rule set. Detect keywords cause UnForm to scan the first page of input, then search for a match where all detect keyword(s) for a given rule set match the contents of the page.

 

Once a rule set is selected, UnForm begins processing each page of text using the rules specified.  Each page is first stripped of any PCL escape sequences so that just text remains, then the array of text rows is converted to HTML based on the rules.  This HTML is then placed in the output according to the style of output defined by the rule set.

 

If no rule set is selected, then UnForm will process each page as plain text, using HTML <pre> and </pre> tags, with horizontal rules between pages (where form-feeds occur in the input).

 

The following keywords are identical in use and function with printer rule sets:

*cols
*const
*detect
*page
*rows

 

The hline and vline keywords are identical, except that they always perform an erase of the horizontal and vertical lines found.

 

Keywords unique to HTML generation are defined on the following pages.