# Light markup languages for TeX users

I was wondering if people could share their experience with various mark up languages.

In particular, I am interested in situations for which you consider light markups preferable to TeX. I am also interested in the level of TeX output support by different markups.

My initial contact with markups started through PmWiki which has its own markup. After brief investigation I settled on txt2tags as my light markup of choice. I am contemplating using it to keep the notes from the meetings with my academic advisees. Is there any light markup with some kind a support for mathematics? Moreover is there a way to use a markup and TeX interchangeably. I am thinking of a situation in which one would take a class notes for example in a light markup.

-
I find that I'm faster with TeX than with any "light markup". The existence of macros and its familiarity makes TeX far easier to type quickly than anything else I've found. So I go the other way: if I need "light markup" then I use TeX and export it to the "light markup" format. –  Loop Space Apr 23 '12 at 7:01

## Markdown with pandoc extensions

1. Markdown is commonly used in many places, including all stackexchange sites and README files on github.

2. Once you get the hang of it, Markdown is easy to use.

3. Markdown has very little (almost none) configuration options. This means that when you are writing notes, you will not be distracted with presentation issues.

4. Pandoc converts Markdown to LaTeX, ConTeXt, doc, epub, docbook, HTML, and a few other formats!

5. You can use any LaTeX command in Markdown. Pandoc passes them untouched when generating LaTeX files. When generating HTML, pandoc parses a few LaTeX commands (simple tables and math formulas) and converts them to HTML.

### Drawbacks (if you are interested in multiple output formats):

1. Markdown provides almost no configuration options. This means that often you end up abusing the limited notation. For example, in my notes I use ``...`` tags to denote everything that should appear in monospace font (code snippets, filenames, shell commands); in TeX documents, I'd rather use semantic markup like `\type{...}`, `\filename{...}`, `\shell{...}`, etc. But these are ignored in non-TeX output.

2. Does not support conditional inclusion of text (a la ConTeXt modes). This is often a deal-breaker for me. Again, one can input the raw TeX macros and they work for TeX output but are ignored in other output formats.

3. Managing images is a bit tricky if you want both HTML and PDF outputs and want to `png` for HTML and `pdf` for PDF. If you are just interested in PDF output, then sticking to `pdf` images is fine.

4. The Metapost/TikZ figures included in the source code are ignored in non-TeX output formats.

## Other Markdown-to-TeX processors

-
I don't know why you shouldn't be able to include TikZ figures, seems to work fine for me. A way to add missing features could be a script doing some conversion before feeding it to pandoc. –  Henrik Hansen Apr 23 '12 at 5:43
you can just write `\type{...}` and it should work. –  morbusg Apr 23 '12 at 6:14
I meant that if you want to generate both HTML and PDF output (which is one of the advantage of lightweight markup languages), TeX macros and TikZ/Metapost figures do not work properly. I'll update my answer to clarify this. –  Aditya Apr 23 '12 at 6:23
Not really worth adding as a separate answer so I'll just add it to this one. The ruby version of Markdown, Maruku, has a few extras that might be worth investigating, including a LaTeX export. Moreover it can be integrated with itextomml to produce MathML in the XHTML output. –  Loop Space Apr 23 '12 at 6:59
Adding to Andrew's comment: ruby also has a rather hackable lib called kramdown. –  morbusg Apr 23 '12 at 7:21
show 1 more comment