LaTeX it's about time to die

XML anyone?

published: October 6, 2009

Studying physics, I get to use LaTeX quite a bit producing reports and articles. In case you don't what LaTeX is, it's essentially a markup language (somewhat akin to HTML, except for the TeX typesetting system) where you place your content into semantic structures. This is then formatted by essentially the same thing as a CSS stylesheet. It allows you to just worry about getting the content right, and the formatting is done for you. Once you've added all the content, you can switch your document from a Book style layout to a report with a single command.

For some reason lot's of people think it's great but it's really not, and here's why:

The syntax

Possibly one of the biggest abominations of LaTeX. If you haven't used it before, here's an example of a simple document:

  1.  
  2. \documentclass{article}
  3. \title{My article about stuff}
  4. \author{Joe Bloggs}
  5. \begin{document}
  6.  
  7.    \maketitle
  8.    Hello world!
  9.    \section{My section title}
  10.    This is the section content \textbackslash
  11.  
  12.    \begin{equation}
  13.   \rho = \frac{3M} {4\pi r^3}
  14.   \end{equation}
  15.  
  16. \end{document}
  17.  

So what's wrong with that? Firstly is the use of \begin{} and \end{} to mark the start and end of a formatting block. It's pointless and just involves typing extra characters, it would be much quicker to just use an HTML-like tag style.

Secondly, notice in the equation the \rho character, that produces the Greek character ρ. Yup, no UTF-8 support.

And thirdly, I'd much prefer for 'methods' to begin like func(args) as is standard, rather than LaTeX style of \func{args}

The IDEs

Although LaTeX is made to be written in a text editor and then compiled there are a few WYSIWYG packages out there, these however present another problem.

Well specifically with BaKoMa Tex. It's one of the more popular packages (and the one we use here at Imperial), but it's pretty shoddy to say the downright least. I've listed a few problems below, but the list is by no means exhaustive:

  • It can't handle .tex files with spaces in the file names. No really, it's 95 all over again.
  • If an error occurs, the only indication to the user in the console window is a small yellow box with exclamation mark in it: BaKoMa TeX console error No highlighting or anything (the console window generally contains a load of info that are not errors too). What's more, clicking on the error does nothing. No you have to right click on that tiny exclamation mark and select 'Jump to source of error' from the popup menu
  • The LaTeX code editor window (shudder), which manages to do achieve some odd results with its scrollbars. Horizontal scrolling is painfully slow, while vertical scrolling (even using the mouse wheel) changes the text selection position to whatever happens to be under the mouse
  • Console messages are generally short and not written in a user friendly manner
  • The program contains numerous spelling mistakes
  • Vista only gripe: it will refuse to install to your Program Files folder citing compatibility issues

The name

Well not so much the name, but how people insist on pronouncing it. Something along the lines of 'Lay-tech' with 'ch' pronouned the same as in 'Bach' is apparently the correct way. Unless my grasp of the English language is very wrong, 'LaTeX' should be pronouned exactly the same as 'latex'. If you want me to call it LayTek or LayTech or whatever, then that's what you're gonna have to call it.

Oh and while you're at it, stop re-inventing the rules of the English language without logical reason.

It was last updated sometime in the 1990s

XML: a better solution

But the final straw in the coffin of LaTeX is been pretty much rendered redundant by XML these days.

Specifically I mean XML, XSL, XSLT and XSLT/FO, MathML and SVG.

XML is used for semantic content storage. The schema (XSD) determines what type of content is allowed in the XML file and provides a semantic meaning to the data.

XSL, together with XSLT and XSLT/FO is used to transform the XML data into something else, it might be HTML+CSS, a PDF or some other format.

MathML is language for producing well-styled mathematical equations.

SVG can be used to draw complex vector images from XML data.

That's a pretty quick overview of how XML can provide a similar format and content-style separation, but with DOM scripting, XQuery and XPath truly dynamic and interactive applications can be achieved.

The final jewel in the crown of XML is it's raison d'âtre: it's extensible. If a feature doesn't exist already there's nothing to stop you adding it (with a few exceptions).

Now what's really missing is a) Good web browsers that can interpret all of these lovely XML based shenanigans, and b) a comprehensive XML editing suite (something like Dreamweaver with fancy code completion minus the bulk).

/rant

tags: LaTeX, XML, math

comments (1)     Page views 571     left side of starright side of starleft side of starright side of starleft side of starright side of starleft side of starright side of starleft side of starright side of star 

« Previous entry | Next entry »

Services

WEB & FLASH DESIGN

  • Standards compliant CSS & XHTML web pages
  • Custom-built dynamic sites based on PHP/MySQL, e.g. blogs, CMS and more
  • Flash adverts, menu design and apps
  • PSD or PNG to XHTML/CSS
  • Flash Lite apps and games for mobile devices/cellphones including Nokia S60, Windows Mobile 6.1 and LG

 

Twitter updates

FOLLOW ME ON TWITTER