There are good alternatives, depending on the type of document being written. For instance, for technical documentation that does not contain to many equations[1], DocBook is often used. Since DocBook uses XML (or SGML previously), it is easy to transform with XSLT. The DocBook project provides excellent stylesheets for xhtml and xsl-fo output, making it easy to target the web and printed media. It is easy to customize output, by overriding templates in the default stylesheets.
Also, DocBook documents can be validated automatically using DTDs or RelaxNG schema. (Yes, XML is full of buzzword bingo :).)
[1] Equations can be typeset with MathML, but since most software only supports presentation MathML this is not ideal.
Before I forget: yes, hand-editing XML is no fun. I did this for years when writing the 'Slackware Basics' book. It is tedious and annoying, even with the excellent nxml-mode for emacs.
For Natural Language Processing for the Working Programmer, we use the <oXygen/> XML editor, which really takes the pain out of writing DocBook documentation. It provides WYSIWYG mode that also renders inline or xincluded XML, such as SVG and MathML. I rarely switch back to the non-WYSIWYG mode, unless I want to reorder some elements quickly.
FYI, asciidoc is great, provides a pipeline to docbook (and thence on to PDF), and is a joy to edit (not quite as concise as, say, markdown, but not ambiguously-defined, either). See my other comment on this thread about it.
asciidoc is nice, but the tag set in DocBook is far broader. Also, DocBook makes it easy to add new elements. But if you need just the basic functionality of DocBook, it is great.
True enough. I've needed some bits of docbook that don't have a direct asciidoc corollary twice, and just used asciidoc passthrough blocks to use them. It's a very practical solution to a leaky abstraction, while allowing me to stay in asciidoc 99.7% of the time.
DocBook is not really a TeX alternative, since it is merely a markup language and does no typesetting of its own. There are actually many DocBook workflows that do the final typesetting in TeX.
Actually, I think this is an asset. DocBook is modular, and consists of DTDs/schemas and stylesheets to translate DocBook content to other XML documents (or plain text). Since TeX is so tightly-coupled to typesetting, it kinda sucks for producing non-typesetted formats.
Using TeX to do the final typesetting in a DocBook workflow is quite old-fashioned. For years, I have used the XSL-FO stylesheet to create XSL-FO output. You can pass this to an XSL-FO typesetter, such as Apache FOP or RenderX.
This workflow has several advantages:
* You can easily tweak output by overriding templates.
* Commonly-used FO renderers render SVG and MathML. You can use one vector graphics format to create XHTML, ePub, and PDF/print output.
* Each step and output, except for the rendering step is XML and can be validated and transformed easily.
Yup, except that XSL-FO output is of shitty quality, especially if you are doing heavy math typesetting, and I know at least one pretty successful open access publisher doing this DocBook->TeX workflow for all their puplications.
Also, DocBook documents can be validated automatically using DTDs or RelaxNG schema. (Yes, XML is full of buzzword bingo :).)
[1] Equations can be typeset with MathML, but since most software only supports presentation MathML this is not ideal.