--- EtText2HTML.pm 2004-03-26 00:50:27.000000000 +0000 +++ ../../../../../Text-EtText-2.3/lib/Text/EtText/EtText2HTML.pm 2019-07-05 16:05:08.000000000 +0100 @@ -250,7 +250,7 @@ }geis; # protect WebMake perl code, <{set}> decls, etc. - $$html =~ s{<{(.*?)}>}{ + $$html =~ s{<\{(.*?)\}>}{ $_ = $1; $self->protect_html(\$_); "<{$_}>"; }geis; @@ -304,12 +304,12 @@ my ($self, $html) = @_; local ($_); - $$html =~ s{^\s+\[([^\]]+)\]\:\s+(\S+)\s*$}{ - $self->{links}->{$1} = $2; "\n"; + $$html =~ s{^\s+\[([^\]]+)\]\:\s+(\S+)\s*?$/}{ + ( $self->{links}->{$1} = $2 ) =~ s/&(?!amp;)/&/g; ''; }giem; - $$html =~ s{^\s+Auto:\s+\[([^\]]+)\]\:\s+(\S+)\s*$}{ - $self->{auto_links}->{$1} = $2; "\n"; + $$html =~ s{^\s+Auto:\s+\[([^\]]+)\]\:\s+(\S+)\s*?$/}{ + ( $self->{auto_links}->{$1} = $2 ) =~ s/&(?!amp;)/&/g; ''; }giem; } @@ -345,9 +345,17 @@ local ($_); # [[this is a link [label]] - $$html =~ s{\[\[(.+?)\s+\[(.+?)\]\]}{ #" + # make sure we don't get caught on a glossary link followed by link-label + $$html =~ s{\[\[ # double left square brackets + ([^\]]+?) # anything but closing square bracket + \s+ # whitespace + \[ # opening square bracket + ([^\]]+?) # anything but closing square bracket + \]\] # double closing square brackets + }{ + $self->link_write (1, $2, $1); - }ges; + }gesx; # glossary links. if (defined $self->{glossary}) { @@ -574,19 +582,19 @@ # do headings. $$html =~ s{(^\n+|\n\n)([^\n]+)[ \t]*\n-{3,}\n}{ my ($pre, $text, $name) = ($1, $2, make_a_name($2)); - "$1

$2

\n\n"; + "$1

$2

\n\n"; }ges; $$html =~ s{(^\n+|\n\n)([^\n]+)[ \t]*\n={3,}\n}{ my ($pre, $text, $name) = ($1, $2, make_a_name($2)); - "$1

$2

\n\n"; + "$1

$2

\n\n"; }ges; $$html =~ s{(^\n+|\n\n)([^\n]+)[ \t]*\n\~{3,}\n}{ my ($pre, $text, $name) = ($1, $2, make_a_name($2)); - "$1

$2

\n\n"; + "$1

$2

\n\n"; }ges; $$html =~ s{(^\n+|\n\n)([0-9A-Z][^a-z]+)[ \t]*\n\n}{ my ($pre, $text, $name) = ($1, $2, make_a_name($2)); - "$1

$2

\n\n"; + "$1

$2

\n\n"; }ges; # now create HRs. Currently we don't bother looking at the --- Lists.pm 2002-10-05 14:07:29.000000000 +0100 +++ ../../../../../Text-EtText-2.3/lib/Text/EtText/Lists.pm 2019-07-05 15:45:27.000000000 +0100 @@ -420,9 +420,9 @@ $start = '
'; $end = '
'; } elsif ($self->{listblock} == $LIST_BQ && $self->{listtype} =~ /^>/) { # looks good in Netscape ;) - $start = '
'; $end = '
'; + $start = '

'; $end = '

'; } elsif ($self->{listblock} == $LIST_BQ) { - $start = '
'; $end = '
'; + $start = '

'; $end = '

'; } my $pstart = ''; @@ -511,7 +511,7 @@ s!

!!gs; # oops, don't wrap headings in P tags - s/

([^\n]+[^\n]+<\/h\d+>[^\n]+\n)<\/p>/$1/gs; + s/

(\s*]*>[^\n]+<\/h\d>\s*)<\/p>/$1/gs; $_; }