Tag Archives: LaTeX

Hints and tips on LaTeX

Using MultiMarkDown

I tend to move between different computers/devices and OSes all the time, and have started to become very tired of storing text data in different formats that are either not compatible or tend to mess up the formatting between different applications (e.g. RTF files).

To avoid this I am now testing to write all my text-based documents (notes, memos, letters, etc.) using MultiMarkDown. This is a so-called Lightweight markup language, similar to e.g. Textile. The reason I chose MultiMarkDown is mainly because I liked the syntax over that of Textile, and that MultiMarkDown seems more alive than its predecessor MarkDown.

The nice thing about using MultiMarkDown is that I can use any text editor on any OS (OSX, iOS, Android, Windows, Linux) to edit the files. The syntax is super simple, barely more than I would use if I wrote plain text files. And, most importantly, there are some nice facilities to help convert MultiMarkDown files to HTML, LaTeX or ODT.

Here are some of the things I have used to get started:

  • The nice installer for OSX
  • bundle for TextMate
  • The full manual (I probably didn’t need to read that, but it was good to see that there is more to this than I might need…)
  • There is also a trick to make TextMate show a live preview of the file (by using the HTML preview window).
  • And I also found a nice quicklook plugin that will show the formatted document when looking at text files with multimarkdown in OSX.

We’ll see how it goes, but I already feel life is easier when passing files back and forth to e.g. PlainText on my iPad.

Use Preview instead of Adobe Reader in Texmate

I just installed Adobe Reader on my new computer, only to discover that it hijacked the PDF preview window in TextMate when working on LaTeX documents. This also happened the last time I installed a new system, and I couldn’t remember what I did to change it back to using Preview as the default PDF viewer.

After googling around, I remembered that TextMate is just using the regular browser settings when it comes to displaying PDF files. For some weird reason, you have to go in the Adobe Reader preferences to change this back. Unfortunately, on my system the uncheck box for this functionality is grayed out:


Finally, I just decided to delete Adobe’s PDF viewer plugin altogether, by deleting this file:

/Library/Internet Plug-Ins/AdobePDFViewer.plugin

This solved the problem, both in Textmate and in my browsers. If anyone wonders, Preview is much, much faster than Adobe Reader and I also think it displays the fonts nicer.

Avoid subscript in Matlab titles

I am working on some plots in Matlab, where I am using the filename as the title of the plot. In many of the files I am using underscores (_) as separator, and the result is that Matlab creates a subscript.

So for a file called b_staccato_004, I get a title bstaccato004.

After some googling I found that this is because Matlab per default treats such text strings as LaTeX code. The solution is to use the interpreter message locally:

title(filename, 'interpreter', 'none')

or it can be set globally using:

set(0, 'DefaulttextInterpreter', 'none')



LaTeX formatting issues

I am about to submit an article for review, and had to format in a special way. Here is a quick summary of what I did:

No paragraph indents:

but a single line between:
Left text justification:
 \begin{flushleft} ...  \end{flushleft}
Double spacing: