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.

This question is from my confusion with the editor. In the WinEdt 6.0, there is a button for different kinds of "TeX". How do I know which one I should use and what's the difference? enter image description here

share|improve this question
1  
Latex is fine for now. You will know when you need the other ones. –  Emre Jul 12 '11 at 4:27
    
@Jack: I am not answering your question. Why don't you use TeXStudio that seems very good editor in my life? –  xport Jul 12 '11 at 5:08
    
@xport: Thanks for the link. –  Jack Jul 12 '11 at 5:12
    
@Jack: If you use TeXStudio, you can use the QuickBuild button to automate the execution of a set of commands. For example: You can execute latex followed by dvips followed by ps2pdf automatically by pressing the QuickBuild button. :-) –  xport Jul 12 '11 at 5:19
6  
@Emre: IMH no reason to use latex (except for PSTricks) any longer. I would recommend people to start with pdflatex and think about using xelatex or lualatex when they need special font and unicode support. –  Martin Scharrer Jul 12 '11 at 6:51

2 Answers 2

up vote 19 down vote accepted

For newbies, pdfLaTeX, XeLaTeX and LuaLaTeX are better choice than LaTeX (latex.exe), which needs multiple steps to produce an output file.

pdfLaTeX is traditional choice, it is fast and robust. pdfLaTeX works on old TeX distributions like teTeX, TeX Live 2008- and MiKTeX 2.6-. Almost all modern packages support pdfLaTeX best (except PSTricks).

XeLaTeX and LuaLaTeX are quite new, both have full support of Unicode and can access fonts installed in the OS. LuaLaTeX is the successor of pdfLaTeX, thus may have good compatibility. XeLaTeX has more macro packages now, and it is a little faster than LuaLaTeX. LuaLaTeX is (potentially) much more powerful than XeLaTeX, but there is less support for LaTeX, most is for ConTeXt.


XeLaTeX would be (especially) suitable to you, for better (Unicode) multilingual support and easy font switching. And it supports more image format and PSTricks code.

For you, it is better to use XeLaTeX if you are typesetting Chinese, or write something yourself; and use pdfLaTeX if you are writing articles for academic journals (in English).

share|improve this answer
    
As I understand in your answer, which one I should use partly depends on what TeX distribution I use, right? –  Jack Jul 12 '11 at 5:02
2  
As I know you're Chinese and you are using CTeX distribution (based on MiKTeX 2.8 or 2.9). Thus you should use XeLaTeX for Chinese and use pdfLaTeX for English. –  Leo Liu Jul 12 '11 at 5:04
    
"but there are very few package for LaTeX, most are for ConTeXt." Should that not be the other way around? Also note that XeLaTeX seems to have some issues with PGF/TikZ shadings and fill patterns, especially in combination with the preview package. –  Martin Scharrer Jul 12 '11 at 6:48
1  
@Martin: Leo is writing about luatex and there is much more luatex support in context than in latex (but the support is not split in packages but is in the kernel so "package" is probably not the best wording). –  Ulrike Fischer Jul 12 '11 at 7:14
    
Thanks @Ulrike, now I understand it. I think a better word would be "support" instead of "package(s)". –  Martin Scharrer Jul 12 '11 at 7:42

I will update this answer whenever I get a new information later.


I don't use WinEdt so I don't know what WinEdt does behind the scene when we press each button in your screenshot. As a comparison, pressing a button in TeXnicCenter (another TeX editor for Windows) will execute a set of commands.

NOTE: I will not mention or compare features provided by packages to silently do cross-invocation. For example: By default, pdflatex cannot import EPS and cannot make use of PSTricks code, but currently it is possible by loading epstopdf and auto-pst-pdf packages, respectively.

latex

  1. The input file (file with extension .tex) with graphics/graphicx package can only import EPS images, using dvips as output driver; PDF, PNG and JPEG images are supported using dvipdfmx, but external program extractbb/ebb/xbb should be manually or automatically (in TeX Live 2010+) used.
  2. The input file can contain PSTricks using dvips. Certainly TikZ is always portable.
  3. Invoking latex filename.tex will produce filename.dvi. If the input file imports images, latex does not embed them in the resulting DVI. We must keep DVI and image files as is. If we insist on deleting the image files (and DVI), we must convert the DVI either to
    • PS using dvips and just keep the resulting PS that is self-contained.
    • PDF using dvipdfmx and just keep the resulting PDF that is self-contained. Caution: dvipdfmx cannot be used when the DVI is previously produced from an input file that contains PSTricks code. There're some old drivers, e.g. dvipdf and dvipdfm to convert DVI to PDF format, but dvipdfmx is much powerful, and may be the only choice in TeX Live 2010+.
  4. If we want to get a PDF as the final output, we must convert the DVI to PDF using one of the following methods:
    1. If the input file does not contain PSTricks code, use dvipdfmx.
    2. Otherwise, use dvips followed by ps2pdf.

pdflatex

  1. The input file with graphicx package can only import PNG, JPEG and PDF images. EPS images are not directly supported. (However, epstopdf package may be automatically loaded in TeX Live 2010+ by graphicx)
  2. The input file can only use TikZ code, PSTricks code is not supported by default.
  3. Invoking pdflatex filename.tex will produce filename.pdf output that is self-contained.
  4. If the input file contains long url, the resulting url in the PDF will be nicely split into several lines.

xelatex

  1. The input file with graphicx package can import PNG, JPEG, PDF, EPS images, using xdvipdfmx driver. Like dvipdfm(x), EPS images are converted to PDF by gs on the fly. But the compilation time is sometimes too long.
  2. The input file can use TikZ and PSTricks code.
  3. Invoking xelatex filename.tex will produce filename.pdf output that is self-contained.
  4. The input file supports unicode.

To be continued....

share|improve this answer
    
note: WinEdt is not WinEdit. –  Leo Liu Jul 12 '11 at 6:17

Your Answer

 
discard

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.