全部博文(137)
分类: LINUX
2010-09-07 23:01:19
A big advantage of latex is that .tex is plain text file so that you can edit latex source files with any text editor. Although vim provides latex syntax-awareness editing, emacs is more widely used because of its tex/latex mode.
The tex mode is installed with emacs and you need to add
(setq tex-dvi-view-command "xdvi")to your .emacs file so that emacs know how to display dvi file. Two important shortcuts are C-c C-f and C-c C-v. The first shortcut calls latex to compile your tex file and the latter call the xdvi to display the generated dvi file. Note that emacs use its own temporary files and you will have to compile your tex file outside of emacs to get a real dvi file.
There is another tex mode called UltraTex provides some very useful features such as latex command auto completion. (You type \b, if \begin is the only latex command in your tex tree, a term used by UltraTex, \begin will be inserted automatically.) This package is available under helpdesk. To make use of this, add the following lines to your .emacs file:
(setq load-path (cons "/home/helpdesk/trial/ultratex/lisp" load-path))You then can start Emacs and customize the packages as desired, by using the commands
(require 'light)
(require 'ultex-setup)
M-x customize-group lightning-completionYou may need to load the ultex package, say by typing M-x load-library ultex or by opening up a TEX file, before you can do the second customization. Please refer to UltraTex webpage for more information.
M-x customize-group ultra-tex
chinaunix网友2010-09-10 20:15:57
很好的, 收藏了 推荐一个博客,提供很多免费软件编程电子书下载: http://free-ebooks.appspot.com