[Po4a-commits] "po4a/lib/Locale/Po4a Text.pm,1.20,1.21"

Nicolas FRANCOIS nekral-guest at alioth.debian.org
Mon Oct 13 19:45:31 UTC 2008


Update of /cvsroot/po4a/po4a/lib/Locale/Po4a
In directory alioth:/tmp/cvs-serv13893/lib/Locale/Po4a

Modified Files:
	Text.pm 
Log Message:
	* lib/Locale/Po4a/Text.pm, t/data-30/Lists.po: Added support for
	Horizontal Labeled Lists.


Index: Text.pm
===================================================================
RCS file: /cvsroot/po4a/po4a/lib/Locale/Po4a/Text.pm,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- Text.pm	13 Oct 2008 19:15:42 -0000	1.20
+++ Text.pm	13 Oct 2008 19:45:28 -0000	1.21
@@ -321,6 +321,23 @@
             undef $self->{bullet};
             undef $self->{indent};
         } elsif ($asciidoc and not defined $self->{verbatim} and
+                 ($line =~ m/^(\s*)(\S.*)((?:::|;;)\s+)(.*)$/)) {
+            my $indent = $1;
+            my $label = $2;
+            my $labelend = $3;
+            my $labeltext = $4;
+            # Found Horizontal Labeled Lists
+            do_paragraph($self,$paragraph,$wrapped_mode);
+            $paragraph=$labeltext."\n";
+            $wrapped_mode = 1;
+            $self->{bullet} = "";
+            $self->{indent} = $indent;
+            my $t = $self->translate($label,
+                                     $self->{ref},
+                                     "Labeled list",
+                                     "wrap" => 0);
+            $self->pushline("$indent$t$labelend");
+        } elsif ($asciidoc and not defined $self->{verbatim} and
                  ($line =~ m/^(\s*)([[:alnum:]].*)(::|;;|\?\?|:-)$/)) {
             my $indent = $1;
             my $label = $2;
@@ -335,7 +352,7 @@
                                      $self->{ref},
                                      "Labeled list",
                                      "wrap" => 0);
-            $self->pushline("$t$labelend\n");
+            $self->pushline("$indent$t$labelend\n");
         } elsif ($asciidoc and not defined $self->{verbatim} and
                  ($line =~ m/^\:(\S.*?)(:\s*)(.*)$/)) {
             my $attrname = $1;




More information about the Po4a-commits mailing list