Regarding XML export and EPUB
Hello, list. I've been experimenting with the export scripts and the instructions and manuals you can find in: https://wiki.contextgarden.net/XML https://wiki.contextgarden.net/Export https://wiki.contextgarden.net/Epub https://wiki.contextgarden.net/ePub This with the expectation of being able to make an epub file form a context document that epubcheck can accept. I see there is an experimental support for epub, and I have played around with the export options a bit. However, what I would really want to know is. It's possible and if so, how can you map context's elements so they can get translated to specific html tags? I mean, the current export output uses divs with custom attributes and classes, or custom tags; but I would like to map lists to ul, list-items to li, headings to h1, h2, h3, paragraphs to <p> etc. In the manuals I see that you can do the opposite: map xml/html tags to context's elements; I wonder if you can go the other way around, and a good place to start reading about it. Apologies if I missed something obvious. Thank you. -- Andrés Conrado Montoya Andi Kú andresconrado@gmail.com http://sesentaycuatro.com http://messier87.com http://chiquitico.org ---------------------------------------- Los fines no justifican los medios, porque la medida verdadera de nuestro carácter está dada por los medios que estamos dispuestos a utilizar, no por los fines que proclamamos. ---------------------------------------- “You develop an instant global consciousness, a people orientation, an intense dissatisfaction with the state of the world, and a compulsion to do something about it. From out there on the moon, international politics look so petty. You want to grab a politician by the scruff of the neck and drag him a quarter of a million miles out and say, ‘Look at that, you son of a bitch.’” — Apollo 14 astronaut Edgar Mitchell
Am 21.12.2020 um 23:31 schrieb Andres Conrado Montoya
: Hello, list. I've been experimenting with the export scripts and the instructions and manuals you can find in:
https://wiki.contextgarden.net/XML https://wiki.contextgarden.net/Export https://wiki.contextgarden.net/Epub https://wiki.contextgarden.net/ePub
This with the expectation of being able to make an epub file form a context document that epubcheck can accept. I see there is an experimental support for epub, and I have played around with the export options a bit. However, what I would really want to know is. It's possible and if so, how can you map context's elements so they can get translated to specific html tags? I mean, the current export output uses divs with custom attributes and classes, or custom tags; but I would like to map lists to ul, list-items to li, headings to h1, h2, h3, paragraphs to <p> etc. In the manuals I see that you can do the opposite: map xml/html tags to context's elements; I wonder if you can go the other way around, and a good place to start reading about it. Apologies if I missed something obvious.
There’s no built-in mechanism. I’m using XSLT to transform ConTeXt’s exported XML to the HTML I want. Esp. with references (footnotes etc) it’s not trivial. Hraban
participants (2)
-
Andres Conrado Montoya
-
Henning Hraban Ramm