texinfo-commits
[Top][All Lists]
Advanced

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

texinfo/tp/Texinfo/Convert Plaintext.pm Text.pm


From: Patrice Dumas
Subject: texinfo/tp/Texinfo/Convert Plaintext.pm Text.pm
Date: Sun, 09 Jan 2011 11:55:06 +0000

CVSROOT:        /sources/texinfo
Module name:    texinfo
Changes by:     Patrice Dumas <pertusus>        11/01/09 11:55:06

Modified files:
        tp/Texinfo/Convert: Plaintext.pm Text.pm 

Log message:
        rename kept_misc_commands as formatting_misc_commands.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/Texinfo/Convert/Plaintext.pm?cvsroot=texinfo&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/Texinfo/Convert/Text.pm?cvsroot=texinfo&r1=1.28&r2=1.29

Patches:
Index: Plaintext.pm
===================================================================
RCS file: /sources/texinfo/texinfo/tp/Texinfo/Convert/Plaintext.pm,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -b -r1.47 -r1.48
--- Plaintext.pm        1 Jan 2011 19:13:02 -0000       1.47
+++ Plaintext.pm        9 Jan 2011 11:55:06 -0000       1.48
@@ -55,10 +55,8 @@
 
 $VERSION = '0.01';
 
-my %kept_misc_commands = %Texinfo::Convert::Text::kept_misc_commands;
-# 'sp', 'center', 'exdent',
-#                     'item', 'itemx', 'tab', 'headitem',
-#    'node',
+# misc commands that are of use for formatting.
+my %formatting_misc_commands = 
%Texinfo::Convert::Text::formatting_misc_commands;
 
 my $NO_NUMBER_FOOTNOTE_SYMBOL = '*';
 
@@ -75,7 +73,7 @@
   'verbatiminclude', 'insertcopying', 
   'listoffloats', 'printindex',
   'contents', 'shortcontents', 'summarycontents') {
-  $kept_misc_commands{$kept_command} = 1;
+  $formatting_misc_commands{$kept_command} = 1;
 }
 my %text_no_brace_commands = %Texinfo::Convert::Text::text_no_brace_commands;
 my %text_brace_no_arg_commands = 
%Texinfo::Convert::Text::text_brace_no_arg_commands;
@@ -94,7 +92,7 @@
 my @out_formats = @Texinfo::Common::out_formats;
 
 foreach my $def_command (keys(%def_commands)) {
-  $kept_misc_commands{$def_command} = 1 if ($misc_commands{$def_command});
+  $formatting_misc_commands{$def_command} = 1 if 
($misc_commands{$def_command});
 }
 
 my %preformatted_context_commands = %preformatted_commands;
@@ -105,7 +103,7 @@
 my %ignored_misc_commands;
 foreach my $misc_command (keys(%misc_commands)) {
   $ignored_misc_commands{$misc_command} = 1 
-    unless ($kept_misc_commands{$misc_command});
+    unless ($formatting_misc_commands{$misc_command});
 }
 
 my %ignored_commands = %ignored_misc_commands;

Index: Text.pm
===================================================================
RCS file: /sources/texinfo/texinfo/tp/Texinfo/Convert/Text.pm,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -b -r1.28 -r1.29
--- Text.pm     13 Dec 2010 01:08:20 -0000      1.28
+++ Text.pm     9 Jan 2011 11:55:06 -0000       1.29
@@ -526,7 +526,7 @@
    },
 );
 
-our %kept_misc_commands;
+our %formatting_misc_commands;
 foreach my $command ('sp', 'center', 'exdent', 
                      'item', 'itemx', 'tab', 'headitem',
     'node',
@@ -552,7 +552,7 @@
     'majorheading',
     'chapheading',
     'centerchap') {
-  $kept_misc_commands{$command} = 1;
+  $formatting_misc_commands{$command} = 1;
 }
  
 my %ignored_types;
@@ -936,7 +936,7 @@
                      and $root->{'args'}->[0]->{'type'} 
                      and ($root->{'args'}->[0]->{'type'} eq 'misc_line_arg'
                          or $root->{'args'}->[0]->{'type'} eq 'misc_arg') 
-                     and !$kept_misc_commands{$root->{'cmdname'}})))));
+                     and !$formatting_misc_commands{$root->{'cmdname'}})))));
   my $result = '';
   if (defined($root->{'text'})) {
     $result = $root->{'text'};
@@ -971,7 +971,7 @@
       if ($root->{'args'}) {
         $result = convert($root->{'args'}->[0], $options) ."\n";
       }
-    } elsif ($kept_misc_commands{$root->{'cmdname'}} and $root->{'args'}) {
+    } elsif ($formatting_misc_commands{$root->{'cmdname'}} and 
$root->{'args'}) {
       if ($root->{'cmdname'} eq 'sp') {
         if ($root->{'extra'} and $root->{'extra'}->{'misc_args'}
             and $root->{'extra'}->{'misc_args'}->[0]) {



reply via email to

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