<br><br><div class="gmail_quote">On Wed, Jul 20, 2011 at 2:31 AM, Patrick Gundlach <span dir="ltr"><<a href="mailto:patrick@gundla.ch">patrick@gundla.ch</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
Am 20.07.2011 um 11:22 schrieb Ulrike Fischer:<br>
<div class="im"><br>
> Am Tue, 19 Jul 2011 21:57:08 -0700 schrieb Johannes Wilm:<br>
><br>
>> Hey,<br>
>> I have had issues with converting latex to epub/html/mobipocket for years. I<br>
>> started using lualatex some months ago and it works quite well for all my<br>
>> other purposes.<br>
>><br>
>> Today I then stumbled over the \setupbackend which is available in Context<br>
>> and which allows for HTML/epub to be produced easily by using some lua code.<br>
>> Now as I understand it, given that lualatex uses the same binary and hat the<br>
>> conversion likely happens by first letting the binary read the entire DOM<br>
>> and then exporting it, it seems that the same scripts really should work for<br>
>> lualatex as well, right?<br>
><br>
> Theoretically: yes.<br>
<br>
</div>There is a little bit more to it, though it can be simulated otherwise. For example with ConTeXt you have more structured sectioning commands. I don't remember what it was but something like<br>
<br>
\startsection<br>
...<br>
\stopsection<br>
<br>
where in LaTeX you have \section{...}, but when does the section end? Is it always clear?<br></blockquote><div><br></div><div>So you are saying that the binary, after reading a latex file, isn't quite aware of the DOM-structure of the file, while after reading a Context-file it is? </div>
<div><br></div><div>It seems that this information is less needed when building an HTML-file instead of a PDF. I mean, it needs to do something like chapter-heading -> H1, but after that it couldn't care less about whether or not that chapter ends.</div>
</div><br clear="all">I will look at the sources you mentioned.<br><div><br>-- <br>Johannes Wilm<br><a href="http://www.johanneswilm.org" target="_blank">http://www.johanneswilm.org</a><br>tel: +1 (520) 399 8880<br><div style="display:inline">
</div><br>
</div>