-) Don't match quoted commands, i.e. @@node inside an @example section.
-) Properly use multiline matching, so we can use ^ and $ to detect the
start/end of each line
This fixes the problem that the xlatex node was not detected
include_re = re.compile (r'@include ((?!../lily-).*?)\.texi$', re.M)
whitespaces = re.compile (r'\s+')
-section_translation_re = re.compile (r'@(node|(?:unnumbered|appendix)(?:(?:sub){0,2}sec)?|top|chapter|(?:sub){0,2}section|(?:major|chap|(?:sub){0,2})heading|translationof) (.*?)\s*\n')
+section_translation_re = re.compile (r'^@(node|(?:unnumbered|appendix)(?:(?:sub){0,2}sec)?|top|chapter|(?:sub){0,2}section|(?:major|chap|(?:sub){0,2})heading|translationof) (.*?)\s*$', re.MULTILINE)
def expand_includes (m, filename):
filepath = os.path.join (os.path.dirname (filename), m.group(1)) + '.texi'