Category: latex


I can’t believe I just came across something so simple, but I’m glad I did. I do all of my plotting in gnuplot and all of my presentation in LaTeX with the Beamer class. Here is what I do to get plots from gnuplot into LaTeX and it’s much simpler than what I used to do (it should be noted that I do all of my LaTeX in gedit, this might not compile the same way in other programs.

1. Output the plot from gnuplot as an .eps image with the following added at the beginning of your .plt file:

set term postscript
set output “/home/user/plot.eps”

2. Move the image into the folder where your .tex file is and run:

epstopdf plot.eps

to create a .pdf of your image.

3. Add the new .pdf as you would any graphic in LaTeX.

Why would I even bother writing something so simple? Because before I tried this I was compiling my LaTeX file like 4 times while also running some other scripts that converted the .eps file to a .ps then to a .dvi then finally to a .pdf. This cut out all of those steps, AND, the resulting .pdf from the epstopdf script looks much clearer than any method I have tried previously. If anyone knows anything simpler, please let me know. The Debian package that contains the epstopdf script can be found here.

Advertisements

LaTeX plugin for Geany

The Statler forum over at the CrunchBang site is letting users vote on which applications they want included in the Statler alpha release. I noticed that Geany was third in text editor voting, and since I am unfamiliar with Geany, I decided to check it out. Turns out they have support for plugins, and have a LaTeX plugin. What is odd is that I have never seen anyone in a “Which Linux LaTeX editor to you use” thread mention Geany. Geany and all of the plugins and the LaTeX plugin are in the Lucid repositories (I have Lubuntu on my netbook) and have no additional dependencies.

The LaTeX plugin has its own menu under “tools” and appears to have more menu options than any LaTeX editor plugin I have tried other than gedit. Geany appears to be more of an IDE than a text editor, so there are also a ton of other options cluttering up the menus. There also doesn’t appear to be an auto spell checking option, which is crucial for me.

The Geany LaTeX plugin is easy to install, and would be a good alternative for people that don’t have access to the gedit LaTeX plugin or people that are already Geany users.

Geany LaTeX plugin

Best Linux LaTeX editor

I don’t sip the LaTeX Kool-Aid, I chug it. The combination of my hatred for Microsoft Word and the need to write papers and slide-shows heavy with equations made this a marriage of love and not convenience. I’ve read many threads on which LaTeX editor Linux users prefer, and I’d like to toss my two cents into the conversation. My vitals: I use Debian+LXDE, I am not a computer programmer (which affected my experience with Vim), and I’m not much of a Linux user. Here’s a list of what I’ve used and I feel gedit is hands down the best.

1. Kile. In 2008 when I first began searching for a LaTeX editor, Kile appeared to be the most popular and the most polished. Since I was new to Linux, I didn’t mind the Qt libraries that are needed for Kile. Kile is a very solid LaTeX editor, but as I’ve evolved from GNOME -> XFCE -> LXDE, I have both put a premium on lightweight desktops and learned to really dislike KDE. I have never gotten it to work correctly, on any computer. If you like KDE, Kile is for you, but I hate KDE and I won’t make an exception for this very good program. Also, as of the last time I used Kile, there was no auto spell checking, and I need auto spell checking.

2. Vim. The next time I set out for a LaTeX editor, I added the constraint that it couldn’t be written in Qt. This eliminated Kile, TeXMaker and TeXWorks. And Vim was the most popular amongst more experienced Linux users, which I thought I was. I used Vim for about 6 months, but ultimately it defeated me. First, as noted above, I have never been a computer programmer, and I’m too old to learn the keyboard shortcuts. And you can’t use a mouse to highlight text for cutting and pasting. And while the Vim addons manager package for Ubuntu is nice, I always had to tweak something in the .vimrc file, either for Vim to recognize a .tex file or to compile beamer class files. If you know Vim and like hacking away in the terminal, I’m sure this rocks, but I suck at both. Also, no auto spell checking.

3. Gummi. Gummi is a very new editor, but has a lot of promise. It appears lightweight and has some nice features, but as of this writing there is no auto spell checking. Once again, I can’t spell for dick.

4. LyX. I have only tested LyX and hated it , but other people seem to love it. Here’s why I don’t recommend it: 1) it’s in Qt so that’s strike 1, and 2) it’s WYSIWYM, which defeats the purpose of using LaTeX to begin with, I’m using LaTeX because I’m a document control freak. If you need the functionality of LaTeX, do yourself a favor and learn LaTeX.

5. gedit. Is the winner for best Linux LaTeX editor, in a landslide. First, it’s in Gtk, so it fits into my LXDE lifestyle. Second, it’s easy as hell to install; pop open synaptic, check select three packages (gedit, gedit-latex-plugins, and gedit-plugins) and you’re done. Gedit will recognize .tex files immediately, and compile to whatever you like. Adding the extra plugins package adds bracket completion and word completion. Combine this with an already very robust text editor, and you have the easiest, most powerful LaTeX editor available. And gedit has auto spell checking capabilities.