[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Texi2html-cvs] texi2html examples/mediawiki.init test/manuals/...
From: |
Patrice Dumas |
Subject: |
[Texi2html-cvs] texi2html examples/mediawiki.init test/manuals/... |
Date: |
Mon, 05 Oct 2009 08:44:37 +0000 |
CVSROOT: /cvsroot/texi2html
Module name: texi2html
Changes by: Patrice Dumas <pertusus> 09/10/05 08:44:36
Modified files:
examples : mediawiki.init
test/manuals/res/ccvs_mediawiki: cvs `cvs: About this Manual'
`cvs: Short Table of Contents'
`cvs: Table of Contents'
test/manuals/res/ccvs_mediawiki_nosplit: cvs
test/manuals/res_all/ccvs_mediawiki: cvs `cvs: Index'
test/manuals/res_all/ccvs_mediawiki_nosplit: cvs `cvs: Index'
test/manuals/res_info/ccvs_mediawiki: cvs `cvs: Index'
test/manuals/res_info/ccvs_mediawiki_nosplit: cvs `cvs: Index'
Log message:
Add heading_text for mediawiki and use the generic formatting
functions when possible.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/texi2html/examples/mediawiki.init?cvsroot=texi2html&r1=1.25&r2=1.26
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res/ccvs_mediawiki/cvs?cvsroot=texi2html&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res/ccvs_mediawiki/cvs:%32About%32this%32Manual?cvsroot=texi2html&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res/ccvs_mediawiki/cvs:%32Short%32Table%32of%32Contents?cvsroot=texi2html&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res/ccvs_mediawiki/cvs:%32Table%32of%32Contents?cvsroot=texi2html&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res/ccvs_mediawiki_nosplit/cvs?cvsroot=texi2html&r1=1.18&r2=1.19
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_all/ccvs_mediawiki/cvs?cvsroot=texi2html&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_all/ccvs_mediawiki/cvs:%32Index?cvsroot=texi2html&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_all/ccvs_mediawiki_nosplit/cvs?cvsroot=texi2html&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_all/ccvs_mediawiki_nosplit/cvs:%32Index?cvsroot=texi2html&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_info/ccvs_mediawiki/cvs?cvsroot=texi2html&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_info/ccvs_mediawiki/cvs:%32Index?cvsroot=texi2html&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_info/ccvs_mediawiki_nosplit/cvs?cvsroot=texi2html&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/texi2html/test/manuals/res_info/ccvs_mediawiki_nosplit/cvs:%32Index?cvsroot=texi2html&r1=1.7&r2=1.8
Patches:
Index: examples/mediawiki.init
===================================================================
RCS file: /cvsroot/texi2html/texi2html/examples/mediawiki.init,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -b -r1.25 -r1.26
--- examples/mediawiki.init 4 Oct 2009 21:51:05 -0000 1.25
+++ examples/mediawiki.init 5 Oct 2009 08:44:34 -0000 1.26
@@ -8,7 +8,7 @@
# Load the file with command-line
# option -init-file mediawiki.init
#
-# $Id: mediawiki.init,v 1.25 2009/10/04 21:51:05 pertusus Exp $
+# $Id: mediawiki.init,v 1.26 2009/10/05 08:44:34 pertusus Exp $
use strict;
@@ -60,17 +60,17 @@
%mediawiki_special_file_name = ();
}
-$print_title = \&mediawiki_print_title;
+$heading_text = \&mediawiki_heading_text;
-sub mediawiki_print_title()
+sub mediawiki_heading_text($$$)
{
- my $title = '';
- $title = $Texi2HTML::THISDOC{'simpletitle'} if
(defined($Texi2HTML::THISDOC{'simpletitle'}) and
$Texi2HTML::THISDOC{'simpletitle'} !~ /^\s*$/);
- if ($title ne '')
- {
- return "== $title ==\n";
- }
- return undef;
+ my $command = shift;
+ my $text = shift;
+ my $level = shift;
+
+ return '' if ($text !~ /\S/);
+ $level = 1 if ($level == 0);
+ return (("=" x $level) . "= $text =" . ("=" x $level) . "\n");
}
###################################################################
@@ -95,7 +95,6 @@
}
-
# This function produces an anchor
#
# arguments:
@@ -182,70 +181,6 @@
-# When the value begins with & the function with that name is used to do the
-#
-# Otherwithe the value is the html element used to enclose the text, and if
-# there is a " the resulting text is also enclosed within `'
-
-# default is {'args' => ['normal'], 'attribute' => ''},
-$style_map{'titlefont'} = {'function' => \&mediawiki_titlefont};
-#$style_map{'option'} = {'args' => ['code'],
-# 'attribute' => 'code',
-# 'quote' => '"'};
-#$style_map{'samp'} = {'args' => ['code'],
-# 'attribute' => 'code',
-# 'quote' => '"'};
-
-
-
-$print_misc = \&mediawiki_print_misc;
-$titlepage = \&mediawiki_titlepage;
-
-sub mediawiki_print_misc
-{
- my $fh = shift;
- my $new_file = shift;
- my $misc_page = shift;
-
- my $buttons = address@hidden;
- &$print_misc_header($fh, $buttons, $new_file, $misc_page);
- print $fh "== $Texi2HTML::NAME{'This'} ==\n";
- main::print_lines($fh);
- &$print_misc_footer($fh, $buttons, $new_file);
-}
-
-sub mediawiki_titlepage($$$$)
-{
- my $titlepage_lines = shift;
- my $titlepage_text = shift;
- my $titlepage_no_texi = shift;
- my $titlepage_simple_text = shift;
-
- $Texi2HTML::TITLEPAGE = $titlepage_text;
- $Texi2HTML::TITLEPAGE = $titlepage_text;
- if ($titlepage_text eq '')
- {
- my $title = '';
- $title = $Texi2HTML::THISDOC{'simpletitle'} if
(defined($Texi2HTML::THISDOC{'simpletitle'}) and
$Texi2HTML::THISDOC{'simpletitle'} !~ /^\s*$/);
- if ($title ne '')
- {
- $Texi2HTML::TITLEPAGE = "== $title ==\n";
- }
- }
-
- return $Texi2HTML::TITLEPAGE;
-}
-
-sub mediawiki_titlefont($$$)
-{
- shift;
- my $args = shift;
- return "\n== $args->[0] ==\n" if $args->[0] =~ /\S/;
- return '';
-}
-
-
-
# This function formats a footnote reference and the footnote text associated
# with a given footnote.
# The footnote reference is the text appearing in the main document pointing
@@ -266,10 +201,12 @@
# have been updated
# the text for the reference pointing on the footnote text
-$foot_line_and_ref = \&mediawiki_foot_line_and_ref;
-$foot_section = \&mediawiki_default_foot_section;
+# currently not used, default case is good enough, but still this is
+# not mediwikified.
+#$foot_line_and_ref = \&mediawiki_foot_line_and_ref;
+#$foot_section = \&mediawiki_default_foot_section;
-sub medaiwiki_foot_line_and_ref($$$$$$$)
+sub mediawiki_foot_line_and_ref($$$$$$$)
{
my $number_in_doc = shift;
my $number_in_page = shift;
@@ -302,56 +239,6 @@
return $lines;
}
-
-
-# This function formats a heading for an element
-#
-# argument:
-# an element. It is a hash reference for a node or a sectionning command.
-# The interesting keys are:
-# 'text': the heading text
-# 'name': the heading text without section number
-# 'node': true if it is a node
-# 'level': level of the element. 0 for @top, 1 for chapter, heading,
-# appendix..., 2 for section and so on...
-# 'tag_level': the sectionning element name, raisesections and lowersections
-# taken into account
-
-$heading = \&mediawiki_heading;
-
-sub mediawiki_heading($$$$$;$$)
-{
- my $element = shift;
- my $command = shift;
- my $texi_line = shift;
- my $line = shift;
- my $in_preformatted = shift;
- my $one_section = shift;
- my $element_heading = shift;
-
- #return '' if (defined($command) and $command eq 'node' and
!$element_heading);
- my $level = 3;
- if (!$element->{'node'})
- {
- $level = $element->{'level'};
- }
- else
- {
- return '' unless ($element->{'this'} and !$element->{'with_section'});
- }
- $level = 1 if ($level == 0);
-
- my $text = $element->{'text'};
-
- return '' if ($text !~ /\S/);
- if (defined($element->{'tocid'}) and $TOC_LINKS)
- {
- $text = &$anchor ('',
"$Texi2HTML::THISDOC{'toc_file'}#$element->{'tocid'}", $text);
- }
- return (("=" x $level) . "= $text =" . ("=" x $level) . "\n");
-}
-
-
$button_formatting = \&mediawiki_button_formatting;
sub mediawiki_button_formatting
Index: test/manuals/res/ccvs_mediawiki/cvs
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res/ccvs_mediawiki/cvs,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- test/manuals/res/ccvs_mediawiki/cvs 4 Oct 2009 21:51:30 -0000 1.9
+++ test/manuals/res/ccvs_mediawiki/cvs 5 Oct 2009 08:44:34 -0000 1.10
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<table class="header" cellpadding="1" cellspacing="1" border="0">
<tr><td valign="middle" align="left">[ < ]</td>
Index: test/manuals/res/ccvs_mediawiki/cvs: About this Manual
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res/ccvs_mediawiki/cvs:
About this Manual,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res/ccvs_mediawiki/cvs: About this Manual 4 Oct 2009
21:51:30 -0000 1.7
+++ test/manuals/res/ccvs_mediawiki/cvs: About this Manual 5 Oct 2009
08:44:34 -0000 1.8
@@ -6,6 +6,7 @@
<td valign="middle" align="left">|[[#SEC_About| ? ]]|</td>
</tr></table>
== About This Document ==
+
<p>
This document was generated on <i>a sunny day</i> using
[http://www.nongnu.org/texi2html/ <i>texi2html</i>].
</p>
Index: test/manuals/res/ccvs_mediawiki/cvs: Short Table of Contents
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res/ccvs_mediawiki/cvs:
Short Table of Contents,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res/ccvs_mediawiki/cvs: Short Table of Contents 4 Oct
2009 21:51:30 -0000 1.7
+++ test/manuals/res/ccvs_mediawiki/cvs: Short Table of Contents 5 Oct
2009 08:44:34 -0000 1.8
@@ -6,6 +6,7 @@
<td valign="middle" align="left">|[[cvs: About this Manual#SEC_About| ?
]]|</td>
</tr></table>
== Short Table of Contents ==
+
<div class="shortcontents">
<ul>
<li><div id="stoc-Overview-1"></div>[[cvs: Overview#Overview|Overview]]</li>
Index: test/manuals/res/ccvs_mediawiki/cvs: Table of Contents
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res/ccvs_mediawiki/cvs:
Table of Contents,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- test/manuals/res/ccvs_mediawiki/cvs: Table of Contents 4 Oct 2009
21:51:30 -0000 1.9
+++ test/manuals/res/ccvs_mediawiki/cvs: Table of Contents 5 Oct 2009
08:44:34 -0000 1.10
@@ -6,6 +6,7 @@
<td valign="middle" align="left">|[[cvs: About this Manual#SEC_About| ?
]]|</td>
</tr></table>
== Table of Contents ==
+
<div class="contents">
<ul>
Index: test/manuals/res/ccvs_mediawiki_nosplit/cvs
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res/ccvs_mediawiki_nosplit/cvs,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -b -r1.18 -r1.19
--- test/manuals/res/ccvs_mediawiki_nosplit/cvs 4 Oct 2009 21:51:30 -0000
1.18
+++ test/manuals/res/ccvs_mediawiki_nosplit/cvs 5 Oct 2009 08:44:34 -0000
1.19
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<table class="header" cellpadding="1" cellspacing="1" border="0">
<tr><td valign="middle" align="left">[ < ]</td>
@@ -16915,6 +16916,7 @@
<td valign="middle" align="left">|[[#SEC_About| ? ]]|</td>
</tr></table>
== Table of Contents ==
+
<div class="contents">
<ul>
@@ -17202,6 +17204,7 @@
<td valign="middle" align="left">|[[#SEC_About| ? ]]|</td>
</tr></table>
== Short Table of Contents ==
+
<div class="shortcontents">
<ul>
<li><div id="stoc-Overview-1"></div>[[#Overview|Overview]]</li>
@@ -17239,6 +17242,7 @@
<td valign="middle" align="left">|[[#SEC_About| ? ]]|</td>
</tr></table>
== About This Document ==
+
<p>
This document was generated on <i>a sunny day</i> using
[http://www.nongnu.org/texi2html/ <i>texi2html</i>].
</p>
Index: test/manuals/res_all/ccvs_mediawiki/cvs
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res_all/ccvs_mediawiki/cvs,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- test/manuals/res_all/ccvs_mediawiki/cvs 4 Oct 2009 21:51:33 -0000
1.6
+++ test/manuals/res_all/ccvs_mediawiki/cvs 5 Oct 2009 08:44:35 -0000
1.7
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<div class="header">
<p>
Index: test/manuals/res_all/ccvs_mediawiki/cvs: Index
===================================================================
RCS file: /cvsroot/texi2html/texi2html/test/manuals/res_all/ccvs_mediawiki/cvs:
Index,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res_all/ccvs_mediawiki/cvs: Index 4 Oct 2009 21:51:33
-0000 1.7
+++ test/manuals/res_all/ccvs_mediawiki/cvs: Index 5 Oct 2009 08:44:35
-0000 1.8
@@ -786,7 +786,7 @@
<td>[[#Index-1_cp_letter-Z|<b>Z</b>]]</td>
<div id="SEC_Overview"></div>
-<h1>Short Table of Contents</h1>
+== Short Table of Contents ==
<div class="shortcontents">
<ul>
@@ -819,7 +819,7 @@
<div id="SEC_Contents"></div>
-<h1>Table of Contents</h1>
+== Table of Contents ==
<div class="contents">
Index: test/manuals/res_all/ccvs_mediawiki_nosplit/cvs
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_all/ccvs_mediawiki_nosplit/cvs,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- test/manuals/res_all/ccvs_mediawiki_nosplit/cvs 4 Oct 2009 21:51:34
-0000 1.6
+++ test/manuals/res_all/ccvs_mediawiki_nosplit/cvs 5 Oct 2009 08:44:35
-0000 1.7
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<div class="header">
<p>
Index: test/manuals/res_all/ccvs_mediawiki_nosplit/cvs: Index
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_all/ccvs_mediawiki_nosplit/cvs:
Index,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res_all/ccvs_mediawiki_nosplit/cvs: Index 4 Oct 2009
21:51:35 -0000 1.7
+++ test/manuals/res_all/ccvs_mediawiki_nosplit/cvs: Index 5 Oct 2009
08:44:35 -0000 1.8
@@ -787,7 +787,7 @@
<td>[[#Index-1_cp_letter-Z|<b>Z</b>]]</td>
<div id="SEC_Overview"></div>
-<h1>Short Table of Contents</h1>
+== Short Table of Contents ==
<div class="shortcontents">
<ul>
@@ -820,7 +820,7 @@
<div id="SEC_Contents"></div>
-<h1>Table of Contents</h1>
+== Table of Contents ==
<div class="contents">
Index: test/manuals/res_info/ccvs_mediawiki/cvs
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_info/ccvs_mediawiki/cvs,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- test/manuals/res_info/ccvs_mediawiki/cvs 4 Oct 2009 21:51:39 -0000
1.6
+++ test/manuals/res_info/ccvs_mediawiki/cvs 5 Oct 2009 08:44:36 -0000
1.7
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<div class="header">
<p>
Index: test/manuals/res_info/ccvs_mediawiki/cvs: Index
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_info/ccvs_mediawiki/cvs: Index,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res_info/ccvs_mediawiki/cvs: Index 4 Oct 2009 21:51:39
-0000 1.7
+++ test/manuals/res_info/ccvs_mediawiki/cvs: Index 5 Oct 2009 08:44:36
-0000 1.8
@@ -786,7 +786,7 @@
<td>[[#Index-1_cp_letter-Z|<b>Z</b>]]</td>
<div id="SEC_Overview"></div>
-<h1>Short Table of Contents</h1>
+== Short Table of Contents ==
<div class="shortcontents">
<ul>
@@ -819,7 +819,7 @@
<div id="SEC_Contents"></div>
-<h1>Table of Contents</h1>
+== Table of Contents ==
<div class="contents">
Index: test/manuals/res_info/ccvs_mediawiki_nosplit/cvs
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_info/ccvs_mediawiki_nosplit/cvs,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- test/manuals/res_info/ccvs_mediawiki_nosplit/cvs 4 Oct 2009 21:51:39
-0000 1.6
+++ test/manuals/res_info/ccvs_mediawiki_nosplit/cvs 5 Oct 2009 08:44:36
-0000 1.7
@@ -1,4 +1,5 @@
== CVS—Concurrent Versions System v4.2 ==
+
<div id="Top"></div>
<div class="header">
<p>
Index: test/manuals/res_info/ccvs_mediawiki_nosplit/cvs: Index
===================================================================
RCS file:
/cvsroot/texi2html/texi2html/test/manuals/res_info/ccvs_mediawiki_nosplit/cvs:
Index,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- test/manuals/res_info/ccvs_mediawiki_nosplit/cvs: Index 4 Oct 2009
21:51:41 -0000 1.7
+++ test/manuals/res_info/ccvs_mediawiki_nosplit/cvs: Index 5 Oct 2009
08:44:36 -0000 1.8
@@ -787,7 +787,7 @@
<td>[[#Index-1_cp_letter-Z|<b>Z</b>]]</td>
<div id="SEC_Overview"></div>
-<h1>Short Table of Contents</h1>
+== Short Table of Contents ==
<div class="shortcontents">
<ul>
@@ -820,7 +820,7 @@
<div id="SEC_Contents"></div>
-<h1>Table of Contents</h1>
+== Table of Contents ==
<div class="contents">
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Texi2html-cvs] texi2html examples/mediawiki.init test/manuals/...,
Patrice Dumas <=