texinfo-commits
[Top][All Lists]
Advanced

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

[no subject]


From: Patrice Dumas
Date: Sat, 30 Mar 2024 11:57:44 -0400 (EDT)

branch: master
commit a62169f57011fc9e42c474002f100e4cedef26af
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Sat Mar 30 16:40:39 2024 +0100

    * tp/Texinfo/Convert/HTML.pm (_default_format_special_body_about):
    reorder code to be in the same order as C code, to get the same debug
    output.
---
 ChangeLog                  | 6 ++++++
 tp/Texinfo/Convert/HTML.pm | 9 +++++----
 2 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 86eaa637b4..79437b3289 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2024-03-30  Patrice Dumas  <pertusus@free.fr>
+
+       * tp/Texinfo/Convert/HTML.pm (_default_format_special_body_about):
+       reorder code to be in the same order as C code, to get the same debug
+       output.
+
 2024-03-30  Patrice Dumas  <pertusus@free.fr>
 
        * tp/Texinfo/Structuring.pm (units_directions): fix getting
diff --git a/tp/Texinfo/Convert/HTML.pm b/tp/Texinfo/Convert/HTML.pm
index 946f441e39..f30d95747d 100644
--- a/tp/Texinfo/Convert/HTML.pm
+++ b/tp/Texinfo/Convert/HTML.pm
@@ -11448,10 +11448,10 @@ EOT
     # if the button spec is an array we do not know what the button
     # looks like, so we do not show the button but still show explanations.
     if (ref($button_spec) ne 'ARRAY') {
-      my $button_name_string
-          = $self->direction_string($direction, 'button', 'string');
       # FIXME strip FirstInFile from $button to get active icon file?
       if ($active_icons and $active_icons->{$direction}) {
+        my $button_name_string
+          = $self->direction_string($direction, 'button', 'string');
         $about
          .= &{$self->formatting_function('format_button_icon_img')}($self,
                          $button_name_string, $active_icons->{$direction})
@@ -11462,13 +11462,14 @@ EOT
       }
     }
     $about .= "</td>\n";
+    # same order for getting the direction strings as in C code
+    my $button_name = $self->direction_string($direction, 'button');
+    $button_name = '' if (!defined($button_name));
     my $direction_description
       = $self->direction_string($direction, 'description');
     $direction_description = '' if (!defined($direction_description));
     my $direction_example = $self->direction_string($direction, 'example');
     $direction_example = '' if (!defined($direction_example));
-    my $button_name = $self->direction_string($direction, 'button');
-    $button_name = '' if (!defined($button_name));
     $about .=
 '    '.$self->html_attribute_class('td', ['name-direction-about']).'>'
     ."$button_name</td>



reply via email to

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