aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>2010-09-22 20:22:51 +0000
committerRalf Wildenhues <rwild@gcc.gnu.org>2010-09-22 20:22:51 +0000
commitab940b73bfabe2cec4a26887f959c868388f5117 (patch)
tree2adfb70df9f3f8a0a39ba59bde6a9fda1e0c5b13 /contrib
parent60cf253a8b1ebaabf6dd476a1177a24ab7f6d48c (diff)
Improve formatting of manuals.
contrib/: * texi2pod.pl: Replace @@ before @{ and @}, for @samp{@@}. Also escape characters with grave accents, to be fixed ... (unmunge): ... here. (postprocess): Also handle @/ and @acronym{...}. gcc/: * doc/contrib.texi (Contributors): Allow URL to wrap in PDF output. * doc/cppopts.texi: Fix markup of index entry. * doc/extend.texi (Constructing Calls): Fix markup of __builtin_va_arg_pack and __builtin_va_arg_pack_len definition. (Conditionals, C++ Comments, Pragmas, Unnamed Fields, Thread-Local) (Vague Linkage, C++ Attributes): Fix markup of index entries and keywords. * doc/invoke.texi (Option Summary): Fix spacing. Rewrap to avoid long lines. (C Dialect Options, C++ Dialect Options, Warning Options) (Debugging Options, Spec Files, Darwin Options) (i386 and x86-64 Options, MIPS Options) (RS/6000 and PowerPC Options, Code Gen Options): Fix markup of index entries, avoid abbreviations, allow URLs to wrap, avoid long lines, avoid overlong pages from long @itemx lists. * doc/objc.texi (Garbage Collection): Allow URLs to wrap. * doc/standards.texi (Standards): Likewise. * doc/trouble.texi (Incompatibilities): Fix markup of index entry. gcc/fortran/: * gfortran.texi (Argument list functions): Allow URL to wrap. * intrinsic.texi (GETGID, GETPID, GETUID, IMAGE_INDEX) (IS_IOSTAT_END, IS_IOSTAT_EOR, NUM_IMAGES, THIS_IMAGE) (ISO_FORTRAN_ENV): Fix markup in index entries, and a couple of code markups in the text. * invoke.texi (Fortran Dialect Options) (Error and Warning Options, Directory Options, Code Gen Options): Likewise. Remove @code inside @smallexample. From-SVN: r164533
Diffstat (limited to 'contrib')
-rw-r--r--contrib/ChangeLog7
-rwxr-xr-xcontrib/texi2pod.pl9
2 files changed, 14 insertions, 2 deletions
diff --git a/contrib/ChangeLog b/contrib/ChangeLog
index 000d274be84..b98ef7bc989 100644
--- a/contrib/ChangeLog
+++ b/contrib/ChangeLog
@@ -1,3 +1,10 @@
+2010-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+
+ * texi2pod.pl: Replace @@ before @{ and @}, for @samp{@@}.
+ Also escape characters with grave accents, to be fixed ...
+ (unmunge): ... here.
+ (postprocess): Also handle @/ and @acronym{...}.
+
2010-07-02 Sebastian Pop <sebastian.pop@amd.com>
* check_GNU_style.sh: Do not print warning messages when there are
diff --git a/contrib/texi2pod.pl b/contrib/texi2pod.pl
index fcdc14550ba..5a4bbacdf5e 100755
--- a/contrib/texi2pod.pl
+++ b/contrib/texi2pod.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl -w
-# Copyright (C) 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
+# Copyright (C) 1999, 2000, 2001, 2003, 2010 Free Software Foundation, Inc.
# This file is part of GCC.
@@ -213,10 +213,12 @@ while(<$inf>) {
# Now the ones that have to be replaced by special escapes
# (which will be turned back into text by unmunge())
+ # Replace @@ before @{ and @} in order to parse @samp{@@} correctly.
s/&/&amp;/g;
+ s/\@\@/&at;/g;
s/\@\{/&lbrace;/g;
s/\@\}/&rbrace;/g;
- s/\@\@/&at;/g;
+ s/\@`\{(.)\}/&$1grave;/g;
# Inside a verbatim block, handle @var, @samp and @url specially.
if ($shift ne "") {
@@ -391,9 +393,11 @@ sub postprocess
s/\@(?:code|kbd)\{([^\}]*)\}/C<$1>/g;
s/\@(?:samp|strong|key|option|env|command|b)\{([^\}]*)\}/B<$1>/g;
s/\@sc\{([^\}]*)\}/\U$1/g;
+ s/\@acronym\{([^\}]*)\}/\U$1/g;
s/\@file\{([^\}]*)\}/F<$1>/g;
s/\@w\{([^\}]*)\}/S<$1>/g;
s/\@(?:dmn|math)\{([^\}]*)\}/$1/g;
+ s/\@\///g;
# keep references of the form @ref{...}, print them bold
s/\@(?:ref)\{([^\}]*)\}/B<$1>/g;
@@ -462,6 +466,7 @@ sub unmunge
# Replace escaped symbols with their equivalents.
local $_ = $_[0];
+ s/&(.)grave;/E<$1grave>/g;
s/&lt;/E<lt>/g;
s/&gt;/E<gt>/g;
s/&lbrace;/\{/g;