[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: * tp/Texinfo/Common.pm (%default_main_program_cus
From: |
Patrice Dumas |
Subject: |
branch master updated: * tp/Texinfo/Common.pm (%default_main_program_customization), tp/Texinfo/Convert/HTML.pm (builtin_default_css_text), tp/texi2any.pl, doc/texinfo.texi (HTML Customization Variables), NEWS: add SHOW_BUILTIN_CSS_RULES, to output the default builtin CSS rules, and exit right after. |
Date: |
Fri, 07 Jan 2022 08:43:20 -0500 |
This is an automated email from the git hooks/post-receive script.
pertusus pushed a commit to branch master
in repository texinfo.
The following commit(s) were added to refs/heads/master by this push:
new 8241105d43 * tp/Texinfo/Common.pm
(%default_main_program_customization), tp/Texinfo/Convert/HTML.pm
(builtin_default_css_text), tp/texi2any.pl, doc/texinfo.texi (HTML
Customization Variables), NEWS: add SHOW_BUILTIN_CSS_RULES, to output the
default builtin CSS rules, and exit right after.
8241105d43 is described below
commit 8241105d43c306c549188571a3dacd06120dd1e7
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Fri Jan 7 14:43:06 2022 +0100
* tp/Texinfo/Common.pm (%default_main_program_customization),
tp/Texinfo/Convert/HTML.pm (builtin_default_css_text),
tp/texi2any.pl, doc/texinfo.texi (HTML Customization Variables),
NEWS:
add SHOW_BUILTIN_CSS_RULES, to output the default builtin CSS
rules, and exit right after.
---
ChangeLog | 9 +++++++++
NEWS | 2 +-
doc/texinfo.texi | 3 +++
tp/TODO | 2 ++
tp/Texinfo/Common.pm | 13 +++++++------
tp/Texinfo/Convert/HTML.pm | 13 +++++++++++++
tp/texi2any.pl | 7 +++++++
7 files changed, 42 insertions(+), 7 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 45610a4373..e0573a7325 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2022-01-06 Patrice Dumas <pertusus@free.fr>
+
+ * tp/Texinfo/Common.pm (%default_main_program_customization),
+ tp/Texinfo/Convert/HTML.pm (builtin_default_css_text),
+ tp/texi2any.pl, doc/texinfo.texi (HTML Customization Variables),
+ NEWS:
+ add SHOW_BUILTIN_CSS_RULES, to output the default builtin CSS
+ rules, and exit right after.
+
2022-01-06 Patrice Dumas <pertusus@free.fr>
* tp/Texinfo/ParserNonXS.pm (_end_line),
diff --git a/NEWS b/NEWS
index 2e966c227b..a5cacc05d2 100644
--- a/NEWS
+++ b/NEWS
@@ -26,7 +26,7 @@ See the manual for detailed information.
. Rename OVERVIEW_LINK_TO_TOC as SHORT_TOC_LINK_TO_TOC, rename
BEFORE_OVERVIEW as BEFORE_SHORT_TOC_LINES and AFTER_OVERVIEW as
AFTER_SHORT_TOC_LINES.
- . remove CSS_LINES customization variable.
+ . remove CSS_LINES customization variable and add SHOW_BUILTIN_CSS_RULES.
. HTML output:
. use <code> tag for the output of @t instead of <tt>
diff --git a/doc/texinfo.texi b/doc/texinfo.texi
index 9ca29e5099..170ef4536c 100644
--- a/doc/texinfo.texi
+++ b/doc/texinfo.texi
@@ -16402,6 +16402,9 @@ If set, when output is split, use the argument of the
chapter
structuring command (e.g., @code{@@chapter} or @code{@@section})
in the @code{<title>} instead of the argument to @code{@@node}.
+@item SHOW_BUILTIN_CSS_RULES
+Output the built-in default CSS rules on the standard output and exit.
+
@item SHOW_TITLE
If set, output the title at the beginning of the document;
default true.
diff --git a/tp/TODO b/tp/TODO
index fc0c129f20..15e5013234 100644
--- a/tp/TODO
+++ b/tp/TODO
@@ -13,6 +13,8 @@ xmllint --nonet --noout --valid commands.xml
Before next release
===================
+LaTeX collect packages.
+
Bugs
====
diff --git a/tp/Texinfo/Common.pm b/tp/Texinfo/Common.pm
index 2430a3cb3f..462c13e453 100644
--- a/tp/Texinfo/Common.pm
+++ b/tp/Texinfo/Common.pm
@@ -227,16 +227,17 @@ my %default_main_program_command_line_options = (
# used in main program, defaults documented in manual
my %default_main_program_customization = (
- 'SORT_ELEMENT_COUNT_WORDS' => undef,
- 'SORT_ELEMENT_COUNT' => undef,
- 'TEXI2DVI' => 'texi2dvi',
- 'TREE_TRANSFORMATIONS' => undef,
- 'DUMP_TREE' => undef,
- 'DUMP_TEXI' => undef,
'CHECK_NORMAL_MENU_STRUCTURE' => 0, # output warnings when node with
# automatic direction does directions in menu are not consistent
# with sectionning, and when node directions are not consistent
# with menu directions.
+ 'DUMP_TREE' => undef,
+ 'DUMP_TEXI' => undef,
+ 'SHOW_BUILTIN_CSS_RULES' => 0,
+ 'SORT_ELEMENT_COUNT' => undef,
+ 'SORT_ELEMENT_COUNT_WORDS' => undef,
+ 'TEXI2DVI' => 'texi2dvi',
+ 'TREE_TRANSFORMATIONS' => undef,
);
# defaults for the main program. In general transmitted to converters as
defaults
diff --git a/tp/Texinfo/Convert/HTML.pm b/tp/Texinfo/Convert/HTML.pm
index 8a129c47df..7d3c3cbbcc 100644
--- a/tp/Texinfo/Convert/HTML.pm
+++ b/tp/Texinfo/Convert/HTML.pm
@@ -1901,6 +1901,19 @@ foreach my $mark_command
(keys(%{$default_no_arg_commands_formatting{'css_string
}
}
+# used to show the built-in CSS rules
+sub builtin_default_css_text()
+{
+ my $css_text = '';
+ foreach my $css_rule (sort(keys(%css_map))) {
+ if ($css_map{$css_rule} ne '') {
+ $css_text .= "$css_rule {$css_map{$css_rule}}\n";
+ }
+ }
+ return $css_text;
+}
+
+
sub _convert_no_arg_command($$$)
{
my $self = shift;
diff --git a/tp/texi2any.pl b/tp/texi2any.pl
index 4d28dd9202..2e3ba14f7e 100755
--- a/tp/texi2any.pl
+++ b/tp/texi2any.pl
@@ -1110,6 +1110,13 @@ foreach my $parser_settable_option
(@parser_settable_options) {
}
}
+# special case, show all the built in HTML CSS rules and exit
+if (get_conf('SHOW_BUILTIN_CSS_RULES')) {
+ require Texinfo::Convert::HTML;
+ print STDOUT Texinfo::Convert::HTML::builtin_default_css_text();
+ exit(0);
+}
+
# Main processing, process all the files given on the command line
my @input_files = @ARGV;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: * tp/Texinfo/Common.pm (%default_main_program_customization), tp/Texinfo/Convert/HTML.pm (builtin_default_css_text), tp/texi2any.pl, doc/texinfo.texi (HTML Customization Variables), NEWS: add SHOW_BUILTIN_CSS_RULES, to output the default builtin CSS rules, and exit right after.,
Patrice Dumas <=
- Prev by Date:
branch master updated: * tp/Texinfo/ParserNonXS.pm (_end_line), tp/Texinfo/XS/parsetexi/Parsetexi.pm (_set_itemize_commands_arg) (_set_errors_node_lists_labels_indices, get_parser_info): remove @itemize command argument detected as command_as_argument in itemize_commands_arg in global information as it is not needed anymore.
- Next by Date:
branch master updated: * tp/Texinfo/Convert/Converter.pm (%xml_text_entity_no_arg_commands_formatting), tp/Texinfo/Convert/DocBook.pm, tp/Texinfo/Convert/HTML.pm, tp/Texinfo/Convert/TexinfoXML.pm: replace %default_xml_no_arg_commands_formatting{'normal'} by %xml_text_entity_no_arg_commands_formatting.
- Previous by thread:
branch master updated: * tp/Texinfo/ParserNonXS.pm (_end_line), tp/Texinfo/XS/parsetexi/Parsetexi.pm (_set_itemize_commands_arg) (_set_errors_node_lists_labels_indices, get_parser_info): remove @itemize command argument detected as command_as_argument in itemize_commands_arg in global information as it is not needed anymore.
- Next by thread:
branch master updated: * tp/Texinfo/Convert/Converter.pm (%xml_text_entity_no_arg_commands_formatting), tp/Texinfo/Convert/DocBook.pm, tp/Texinfo/Convert/HTML.pm, tp/Texinfo/Convert/TexinfoXML.pm: replace %default_xml_no_arg_commands_formatting{'normal'} by %xml_text_entity_no_arg_commands_formatting.
- Index(es):