From 99961f52866ac7b1adda5ea92ea3e9d2c1363a77 Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Mon, 4 Aug 2008 02:19:28 +0200 Subject: Extend make and po4a to support templates. --- Locale/Po4a/Text.pm | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'Locale/Po4a') diff --git a/Locale/Po4a/Text.pm b/Locale/Po4a/Text.pm index 5236095..0cc2cc8 100644 --- a/Locale/Po4a/Text.pm +++ b/Locale/Po4a/Text.pm @@ -179,6 +179,12 @@ sub parse { $paragraph=""; $wrapped_mode = 1; $self->pushline($line."\n"); + } elsif ($line =~ /^-- $/) { + # Break paragraphs on email signature hint + do_paragraph($self,$paragraph,$wrapped_mode); + $paragraph=""; + $wrapped_mode = 1; + $self->pushline($line."\n"); } elsif ( $line =~ /^=+$/ or $line =~ /^_+$/ or $line =~ /^-+$/) { @@ -237,6 +243,7 @@ sub parse { $wrapped_mode = 0 if ( $paragraph =~ /^>/ms # blockquote or $paragraph =~ /^( {8}|\t)/ms # monospaced + or $paragraph =~ /^\$(\S+[{}]\S*\s*)+/ms # Xapian macro or $paragraph =~ /[<>]/ms # maybe html or $paragraph =~ /^\s*\[\[\!\S[^\]]+$/ms # macro begin ); -- cgit v1.2.3