[Cuis-dev] XML in Erudite
Mariano Montone
marianomontone at gmail.com
Sat Jun 15 19:35:54 PDT 2024
Hi all,
I'm working on Erudite books authored using XML. Because, if EPUB
uses it (HTML actually ...), then why not? :P
The real reason is to try to make Erudite books more structured (like
support for lists, etc) and easily extensible.
I think books have a domain, and the authoring language should reflect
that. And so the markup should be easy to extend (I can imagine a
<DrGeoExample> element, for example ).
XML is very generic, and I'm not having to apply any special rules, like
with the PEG parser. And so extending the grammar it is just a matter of
subclassing from existing Markup nodes.
Also, the source being more structured has better potential for applying
transformations to other formats.
I attach an screenshot with an example. There you can see a custom
<info> node as an example that can be implemented with a class and a
couple of methods.
I have the impression that extension in documentation systems is not
used much, but I think it is a very good idea; and specially like the
idea of an "object oriented markup language".
I'm interested in your thoughts, either about this, or other
documentation systems that support extension (I looked at DocBook but
I'm not sure how easy are to implement the extensions. TexInfo supports
custom elements via macros, but an object oriented design for the markup
has advantages IMO).
Cheers!
Mariano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: XMLErudite.png
Type: image/png
Size: 130801 bytes
Desc: not available
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240615/7e61f08c/attachment-0001.png>
More information about the Cuis-dev
mailing list