texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[6519] <ol start=>


From: Gavin D. Smith
Subject: [6519] <ol start=>
Date: Thu, 13 Aug 2015 09:55:04 +0000

Revision: 6519
          http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=6519
Author:   gavin
Date:     2015-08-13 09:55:02 +0000 (Thu, 13 Aug 2015)
Log Message:
-----------
<ol start=>

Modified Paths:
--------------
    trunk/ChangeLog
    trunk/tp/Texinfo/Convert/HTML.pm
    trunk/tp/t/results/converters_tests/enumerate_above_ten.pl

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog     2015-08-12 22:01:51 UTC (rev 6518)
+++ trunk/ChangeLog     2015-08-13 09:55:02 UTC (rev 6519)
@@ -1,3 +1,8 @@
+2015-08-13  Gavin Smith  <address@hidden>
+
+       * tp/Texinfo/Convert/HTML.pm (_convert_enumerate_command): Use
+       <ol start="NUMBER"> for numeric argument other than 1.
+
 2015-08-12  Karl Berry  <address@hidden>
 
        * doc/texinfo.texi (@code{@@enumerate}): be clearer that

Modified: trunk/tp/Texinfo/Convert/HTML.pm
===================================================================
--- trunk/tp/Texinfo/Convert/HTML.pm    2015-08-12 22:01:51 UTC (rev 6518)
+++ trunk/tp/Texinfo/Convert/HTML.pm    2015-08-13 09:55:02 UTC (rev 6519)
@@ -2913,11 +2913,17 @@
   if ($self->in_string()) {
     return $content;
   }
-  if ($content ne '') {
-    return "<ol>\n" . $content . "</ol>\n";
-  } else {
+  if ($content eq '') {
     return '';
   }
+  if ($command->{'extra'}{'enumerate_specification'}
+      and $command->{'extra'}{'enumerate_specification'} =~ /^\d*$/
+      and $command->{'extra'}{'enumerate_specification'} ne '1') {
+    return "<ol start=\"$command->{'extra'}{'enumerate_specification'}\">\n"
+           . $content . "</ol>\n";
+  } else {
+    return "<ol>\n" . $content . "</ol>\n";
+  }
 }
 
 $default_commands_conversion{'enumerate'} = \&_convert_enumerate_command;

Modified: trunk/tp/t/results/converters_tests/enumerate_above_ten.pl
===================================================================
--- trunk/tp/t/results/converters_tests/enumerate_above_ten.pl  2015-08-12 
22:01:51 UTC (rev 6518)
+++ trunk/tp/t/results/converters_tests/enumerate_above_ten.pl  2015-08-13 
09:55:02 UTC (rev 6519)
@@ -173,7 +173,7 @@
 ';
 
 
-$result_converted{'html_text'}->{'enumerate_above_ten'} = '<ol>
+$result_converted{'html_text'}->{'enumerate_above_ten'} = '<ol start="14">
 <li> a
 </li></ol>
 ';




reply via email to

[Prev in Thread] Current Thread [Next in Thread]