From 70cebcb86474ab46cc7d4edec107e07cf80ad9a2 Mon Sep 17 00:00:00 2001 From: Reinhold Kainhofer Date: Mon, 7 Apr 2008 10:33:39 +0200 Subject: [PATCH] texi2html: Fix translation of section titles texi2html inserts a whitespace at the beginning and the end of a section title, i.e. "

Chapter blah

", while makeinfo didn't use a space "

Chapter blah

". Update the regexp that extracts the section titles accordingly to allow spaces right after and before ... --- buildscripts/html-gettext.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/html-gettext.py b/buildscripts/html-gettext.py index 65efe8f283..7b381349b5 100644 --- a/buildscripts/html-gettext.py +++ b/buildscripts/html-gettext.py @@ -88,7 +88,7 @@ for filename in args[3:]: page = re.sub (r'([^<]*?) - ([^<]*?)', title_gettext, page) # ugh page = re.sub (r'(?ms))()?(Appendix )?([A-Z\d.]+ |)(.+?)(?(3)):?', a_href_gettext, page) - page = re.sub (r'(Appendix |)([A-Z\d.]+ |)?([^<]+)', h_gettext, page) + page = re.sub (r'\s*(Appendix |)([A-Z\d.]+ |)?([^<]*[^< ])\s*', h_gettext, page) page = re.sub (r'(.+?)', crossmanual_ref_gettext, page) # this is necessary for entries not translated by a_href_gettext page = re.sub (r'(.+?)', crossmanual_ref_gettext, page) -- 2.39.5