On Tue, May 19, 2026 at 11:47:27PM +0200, Patrice Dumas wrote: > > > Should I proceed? > > > > I did not actually understand the reason why nesting @html in @ifepub > > (or nesting @ifebub in @html) would not work. > > @ifepub/@ifhtml are removed when parsing, therefore they cannot be used, > at conversion time, to select a different Texinfo code to convert when > converting from epub.pm or when converting from HTML.pm as they > have been removed already. And we need to have separate code, as the > metadata are different, and both are output for EPUB, for EPUB there > is both EPUB specific metadata output in a separate file and the whole > manual in XHTML files with metadata too.
Does it really matter that we don't have a way to access the EPUB metadata section with raw formatting commands? I don't think anybody has been asking for that functionality. It seems likely that there would be similar limitations for parts of other output formats. It is a limitation of using raw formatting commands as the structure of the Texinfo source doesn't exactly parallel the format of output files. > > When you say "metadata", does this mean something different for HTML ouput > > and EPUB output? > > Yes. For HTML, it is code appearing in <head>, like > <meta name="Generator" content="program"> > > For EPUB, it is XML appearing in a separate file, in the <metadata> > element, looking like > <dc:creator>Me</dc:creator> > > > Is this for the case when @html is nested inside of > > @documentinfo for the purpose of outputing inside of <head>? > > For HTML, yes. Is it possible to override the processing of @html in the code for EPUB and output to the separate <metadata> element as you describe? There only appears to be a problem here if, in EPUB output, somebody wants to output to both the <head> element and the <metadata> element.
