From 03dffcce0efb65d2e31ee75b2d1a16b6b29f51a4 Mon Sep 17 00:00:00 2001 From: Fred Drake Date: Thu, 18 Mar 1999 16:42:28 +0000 Subject: LaTeX2HTML support for the ltxmarkup package. --- Doc/perl/ltxmarkup.perl | 51 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 Doc/perl/ltxmarkup.perl diff --git a/Doc/perl/ltxmarkup.perl b/Doc/perl/ltxmarkup.perl new file mode 100644 index 0000000..9136e61 --- /dev/null +++ b/Doc/perl/ltxmarkup.perl @@ -0,0 +1,51 @@ +# LaTeX2HTML support for the ltxmarkup package. Doesn't do indexing. + +package main; + + +sub ltx_next_argument{ + my $param; + $param = missing_braces() + unless ((s/$next_pair_pr_rx/$param=$2;''/eo) + ||(s/$next_pair_rx/$param=$2;''/eo)); + return $param; +} + + +sub do_cmd_macro{ + local($_) = @_; + my $macro = ltx_next_argument(); + return "\$macro" . $_; +} + +sub do_cmd_env{ + local($_) = @_; + my $env = ltx_next_argument(); + return "\$env" . $_; +} + +sub do_env_macrodesc{ + local($_) = @_; + my $macro = ltx_next_argument(); + my $params = ltx_next_argument(); + return "\n
" + . "\n
\$macro" + . "\n $params" + . "\n
" + . $_ + . "
"; +} + +sub do_env_envdesc{ + local($_) = @_; + my $env = ltx_next_argument(); + my $params = ltx_next_argument(); + return "\n
" + . "\n
\$env" + . "\n $params" + . "\n
" + . $_ + . "
"; +} + +1; # Must end with this, because Perl is bogus. -- cgit v0.12