Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I've found several questions about editors for writing LaTeX documents ( LaTeX Editors/IDEs seems to be the definitive one). But I'd like to know which editors are out there that help you develop LaTeX packages or classes; editors that make it easier to program in LaTeX; a completely different activity.

When I'm programming I don't really care about symbol lookup, instant previews, SyncTeX or anything like that. I'd be more interested in features such as those in the following non-exhaustive list:

  • an integrated build system and syntax highlighter that understand .dtx (and friends)
  • smart auto-complete that draws from included packages
  • hyper-linking between command definitions and usages
  • tool-tips that show command documentation
  • native support for etoolbox, etextools, latex3 and the like (in some shape or form)
  • step-by-step expansion preview of selected code (a form of debugging)
  • ability to recognize / select tokens (in addition to characters)
  • an \expandafter-helper (you just point, the editor inserts the necessary \expandafters)
  • automatic searching on CTAN

Well, I could go on, but you get the point.

I call upon all package authors: Which editor do you like? And why? (One editor per answer, please.)

share|improve this question
Ah, but an \expandafter-helper would take all fun out of it! :) –  cgnieder Dec 2 '12 at 20:13
:-) Actually, I'm quite fond of \expandnext (and friends) from etextools. Wow, did my life get easier when I discovered those. Also, LaTeX3 seems to have nice facilities for expansion control. I listed this feature mainly to give a taste of the kind of thing I'm looking for in an editor. –  mhelvens Dec 2 '12 at 20:18
Does it have to have a precompiler to see what the argument is ? Where do you want to point exactly to have the array of exapndafters? –  percusse Dec 2 '12 at 20:30
@tohecz I disagree with the closing, voting to reopen. The OP is listing very specific examples of what would be helpful in such an editor. The answers can be objective, contentwise, even though the voting will likely be subjective -- but that's the case with many of our very popular questions, take e.g. What packages do people load by default in LaTeX? or Showcase of beautiful typography done in TeX & friends –  doncherry Dec 3 '12 at 19:31
See also Editor for DTX files –  Joseph Wright Dec 4 '12 at 8:03
show 5 more comments

7 Answers

My vote will also go to Emacs.

Using the auctex package with Emacs facilitates easy compilation, syntax highlighting and for those that do use menus there are a lot of TeX/LaTeX resources to be found within the editor with auctex loaded. For the rest of us there are short-codes available through the keyboard - just search for an auctex cheat sheet on the net. However, if you haven't used Emacs or vi/vim before maybe you would like to go for a editor like TeXShop or WinEdt.

Last year a question regarding dtx files and WinEdt was asked and answered. Editor for DTX files

share|improve this answer
add comment

emacs ​​​​​​​​​​​​​​​​​​​​​​​​

share|improve this answer
I am resisting adding the obvious rebuttal to this: vi. :-) –  Peter Grill Dec 3 '12 at 2:39
-1, would not read again ;). (I don't think I need to explain why I don't deem this an adequate answer ...) –  doncherry Dec 3 '12 at 3:44
@Manuel : Even if it's not its main purpose, emacs can perfectly be used like notepad, with mouse-driven menus instead of strange keyboard shortcuts. It doesn't mean you get locked away from all the "good stuff", you just learn about them at your own pace. –  T. Verron Dec 3 '12 at 7:18
@DavidCarlisle You could turn this into an answer by providing an explanation/justification. –  Marc van Dongen Dec 3 '12 at 7:56
I had to override an urge to upvote this because I like emacs. But the truth is this isn't a good answer. This is a good answer. –  Seamus Dec 3 '12 at 22:07
show 1 more comment

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

I use TeXstudio (before called TeXmakerX being a branch from TeXmaker) for some time now and I think it is the best TeX-editor by large.

You can find out more about it at: its SourceForge site.

It has many nice properties and functions. The most important ones:

  • Multi-platform (Mac, Unix, Windows) : you can use one tool everywhere
  • concept of master documents (really nice when you have many included files in your main TeX file) : no need for directives like 'root', no need to switch files
  • online preview of the tested file
  • macros/scripting
  • tool-tips with command documentation
  • code folding
  • document structure view
  • bookmarks
  • some directive support, e.g. for spell-checking language

And some others:

  • SVN integration (auto-commit at save, get revision at undo, etc.)
  • auto-build (compiles bibtex/latex as many times as necessary)
  • auto-completion (based on autogenerated .cwl files)
  • syntax highlighting (tex, latex, lua, qtscript, xml, dtx, ...)
  • spell and grammar checking
  • many wizards and assistants
  • symbol list (latex symbols and more: pstricks, metapost, tikz, asymptote) with favorites
  • support for many TeX-tools (bibtex, makeindex, etc.)
  • customisation options and profiles
  • and more ...

I will just add that I'm not related to the authors of the program, I just use it and find it very useful.

share|improve this answer
TeXstudio may be good, but about half of those features are not relevant for programming. :-) It would help if you could clean up your answer a bit to more specifically target the original question. –  mhelvens Dec 7 '12 at 9:30
add comment

TeXworks has few good properties that might be considered helpful:

  • It understands the directive

    %!TEX root=test.tex

    which might be useful in a .sty or .cls file so that you don't have to switch windows to compile the test document.

  • It has instant PDF preview of the test file.

  • It shows both compilation log and editor window, allowing you to edit the source file during the compilation (however, the compilation runs on the originial file). This allows for very fast and efficient typo corrections.

share|improve this answer
Note that TeXworks reads the entire file before allowing editing, which can be a bit 'interesting' with larger source files. (I use TeXworks routinely, so this is not a complaint, just an observation.) –  Joseph Wright Dec 4 '12 at 8:02
add comment

If you don't forget of KDE, you can use Kile. It is good, flexible, fast and whatever else you like. Auto-completion, highlight, patterns included.

share|improve this answer
Welcome to TeX.sx! –  lockstep Dec 7 '12 at 9:41
I use kile for every LaTeX-related task, i.e., also for package writing, but not because it would have any particluar feature that's helpful for package writing. It simply is the first editor I ever used for LaTeX and I got stuck over the years –  cgnieder Dec 7 '12 at 10:29
Kile also supports structural view of your document. You can easily find matter section wise, frame wise etc. Also it has nice support for labels and ref. One can easily check if some label went wrong. –  manjusha Apr 8 '13 at 10:22
add comment

Can't believe that no one mentioned VIM. It handles e.g. syntax highlighting for dtx files out of the box, but the biggest gain (I can think of) is: You get used to an editor which may serve you for almost all editing tasks (see this tip from the Pragmatic Programmer).

share|improve this answer
The same could be said for emacs and others. Is latexsuite particularly useful for programming? –  mhelvens Apr 3 '13 at 7:24
@mhelvens, yes EMacs is proposed above and yes latexsuite is very useful for writing latex code. –  math Apr 3 '13 at 19:34
Note that 'writing LaTeX code' is not the same as 'LaTeX programming'. Please read the original question more carefully. It is not about preparing LaTeX documents, but about developing packages. I mentioned certain specific features that would be useful for that. Does latexsuite have any of those features? –  mhelvens Apr 4 '13 at 14:34
Nope, but VIM does handle e.g. dtx files out of the box with correct syntax highlighting. –  math Apr 4 '13 at 17:29
That's valid. I request that you edit your answer to more directly address the issue. –  mhelvens Apr 5 '13 at 18:06
add comment

Most LaTeX-IDEs are quite convenient: all functions are only one klick away. But in most of them the editor sucks. If you have ever tried a good editor like vim or emacs you never wanna switch back. So I suggest to make your choice of the IDE depending on the editor (or if it's able to use an external editor).

You can also use Emacs or Vim with "plugins". I use Vim with the latex-suite and I've heard the Emacs with AucTeX is even more powerfull.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.