rere-0.1: Regular-expressions extended with fixpoints for context-free powers

Safe HaskellTrustworthy
LanguageHaskell2010

RERE.LaTeX

Description

Pretty-print structures as LaTeX code.

Note: doesn't work with MathJax.

Requires xcolor package. You need to define colors, for example:

\colorlet{rerelit}{red!80!black}    % literal characters
\colorlet{reresym}{green!50!black}  % symbols: eps and emptyset
\colorlet{rereidn}{blue}            % identifiers
\colorlet{rerestr}{red!50!blue}     % strings (subscripts)
Synopsis

Documentation

putLatex :: RE Void -> IO () Source #

Pretty-print RE as LaTeX code.

putLatexTrace :: RE Void -> String -> IO () Source #

Run match variant, collect intermediate steps, and pretty-print that trace.

putLatexCFG :: Vec n Name -> CFG n Void -> IO () Source #

Pretty-print CFG given the names.