[ Combined Document ] | Contents | Previous | Next


How do I use TeX with Emacs?

(Note: If you use anti-virus software, see the warnings above.)

You will need to get an implementation of TeX The TeX User's Group (TUG) maintains a list of TeX implementations at:

MiKTeX

 MiKTeX is a native Windows implementation of the TeX document processing system. The MiKTeX project page is at http://www.miktex.org.

 The project page has instructions on where to download the distribution and how to install it.

AUCTeX

AUCTeX is a package for writing LaTeX files in Emacs. The AUCTeX project page is at http://sunsite.auc.dk/auctex, and has links for downloading the distribution and reading the manual. Lars Schmidt-Thieme <lschmidt@ix.urz.uni-heidelberg.de> has written instructions on how to use AucTex with MikTex and Emacs.

FPTeX

FTTex is another port of a TeX system for windows - it is much closer to the Unix TeX, for more details please see : http://www.tug.org/interest.html#free.

Putting it all together

Willem Minten <Willem.Minten@esat.kuleuven.ac.be> has put together a page that has everything you need to get MiKTex, AucTeX, and Emacs working together. If you're starting from scratch, look here first.

How do I perform spell checks, using Ispell?

Ispell version 3 is the latest official supported version of the ispell package for Windows.

Ispeel 3.1 has support for multiple languages, and may be used in flyspell-mode.

The Cygnus port of ispell 3.1 works well with Emacs and the flyspell package. [Details]

Emacs for SGML editing and publishing on Windows

Lennart Staflin has written a mode called PSGML for editing SGML documents. The latest beta release also supports XML. All releases may be found at:

An SGML validator is included in James Clark's DSSSL Engine, Jade.

Markus Hoenicka has prepared an NT-specific installation guide for PSGML, Jade and many related and useful packages at:

Another good source of information for creating, managing, and processing TEI documents in SGML or XML. is:

Emacs and Encryption, using GPG - or PGP

GNU Privacy Guard is a free replacement for PGP which runs on many Unix systems, and also Windows. GPG can be found at http://www.gnupg.org.

GPG, and PGP can both be used with the version of mail-crypt find mailcrypt at ...

How do I use an Intellimouse with Emacs?

The Emacs 20.3 pretests and above support the Intellimouse on both NT and Win9X. Emacs 19.34.6 supports it on NT, but not on Windows 95.

Clicking the mouse wheel is interpreted as a mouse-2 event, which is normally bound to mouse-yank-at-click (i.e., paste). Since it is easy to accidentally click the mouse wheel, you might find that you inadvertantly paste text as you scroll the wheel. To prevent this from happening, you can disable the mouse-2 binding in your startup file:

(global-unset-key [mouse-2])

Walt Buehring <buehring@i2.com> has extended the implementations of mouse-wheel-scroll-line and mouse-wheel-scroll-screen. To use, download and place in your startup or site-init files.

For more details on interpreting mouse-wheel events in elisp, see Michael Duggan's <md5i@schenley.com> description of the implementation.

Interactions with FlyWheel

Apparently, FlyWheel and Emacs Intellimouse support don't work together. You can selectively disable FlyWheel for Emacs using a registry entry; see the FlyWheel README for how to disable it for a specific application.

Why does Emacs ignore my mouse wheel?

Emacs is incompatible with the latest versions of mouse wheel devices. To get your mouse wheel to work with Emacs, you'll need to select some options in the device setup panels.

How do I use perl-mode with Emacs?

A perl-mode comes with the Emacs distribution, and will be used when you load and edit Perl files.

Users have also recommended an alternate mode named cperl-mode. You can get this from ftp://ftp.math.ohio-state.edu/pub/users/ilya/perl/.

How do I use the perl debugger with Emacs?

From Jay Rogers <jay@rgrs.com>:

There are potentially two problems that cause the perl debugger to hang when started in emacs. One's an emacs problem while the other's a perl problem.

First, get Emacs 19.34.4 or later for Windows 95/NT. It contains a fix that allows emacs to read all ASCII characters from the perl debugger, including the dreaded ^Z (aka EOF in DOS). It also groks the "drive:path" filename notation.

Second, some versions of the perl debugger itself need to be patched to work with emacs. They are perl versions 5.001 and less, and version 5.004_01. To fix, locate and change the code similar to the following code in lib/perl5db.pl

    if (-e "/dev/tty") {
        $console = "/dev/tty";
        $rcfile=".perldb";
    }
    elsif (-e "con") {
        $console = "";                 <---- change "con" to ""
        $rcfile="perldb.ini";
    }
    else {
        $console = "sys\$command";
        $rcfile="perldb.ini";
    }

Doug Campbell <soup@ampersand.com> also has some suggestions for improving the interaction of perldb and Emacs.

How do I use python-mode with Emacs?

The python-mode shipped with Python 1.5 requires a new custom.el before it can be used with Emacs 19.34. For more information, see the description of python-mode at http://www.python.org/emacs/python-mode/.

How do I use grep with Emacs?

To use grep with Emacs, you first need to obtain a version of grep. Many of the packages listed in the section below on Unix Tools come with a version of grep (and cousins egrep and fgrep). Once you have grep, be sure that it is in your system path or in Emacs' exec-path. Then you should be able grep from within Emacs using "M-x grep".

If you can't get access to grep, then you can use the findstr program that comes with Windows NT and Windows 95 instead. It is much more limited in its searching ability, but if you have simple needs it may be adequate. Peter Breton <pbreton@i-kinetics.com> shows you how to do this.

Some users find the igrep package to be a more useful package for using grep (for example, it supports recursive greps directly). Here are some pointers from other users on what you need to do to get igrep working on your system. You can download igrep from the elisp archive at ftp://ftp.cis.ohio-state.edu/pub/emacs/emacs-lisp/misc/igrep.el.gz.

How do I do a recursive grep?

To do a recursive grep, you need the help of some other utilities. Probably included in the same package that has grep will be find, a program that can recursively traverse directories and invoke programs on the files it finds. To do a recursive grep with find, invoke "M-x grep" and run the following command:

find . -name pattern -exec grep -n string NUL {} ;
(Note that find is not the same program as the find that comes with Windows, rather a port of the GNU Findutils component).

The pattern argument determines which files are matched (e.g., "*.c" for all .c files). The string argument specifies the string that you are searching for. And the NUL argument is a standard way to ensure that grep reports filenames in the matches (grep reports filenames when it is invoked on more than one file, and the NUL device is simply another file that will never contain matches; on Unix, you would use /dev/null).

If you also have the xargs program, than you can make the recursive grep more efficient. Instead of the above command, use:

find . -name pattern -print | xargs grep -n string NUL

The xargs command collects lines from its input and concentates them together as one list of arguments, and invokes the specified program with the argument list (breaking the arguments up into multiple lists and invocations if necessary). The above command first uses find to print out the set of filenames that match pattern, which then gets passed to xargs. xargs concatenates the lines of filenames into lists of arguments and invokes grep on them.

How do I use the EDT emulation mode in Emacs?

To use the EDT emulation package distributed with Emacs, place the following in your startup file:

(setenv "TERM" "pc")
(setq term-setup-hook 'edt-emulation-on)

You might want to also browse through the EDT emulation documentation in etc/edt-user.doc. It describes which keys are emulated, how they are mapped onto the keypad and function keys, etc.

How do I do desktop saving with Emacs?

Desktop saving refers to the ability to save and restore editing sessions (state of frames and buffers) between uses of Emacs. Kevin Greiner <kgreiner@geosys.com > has collected some elisp for using the desktop saving features of Emacs that should prove useful for others interested in the feature.

Jari Aalto <jari.aalto@poboxes.com> also has collected references to packages that save Emacs state and screen and window position.

Chuck Siska <chuck.siska@conexant.com> wrote his own desktop frame window layout save and restore package called desktop-frame.el.


[ Combined Document ] | Contents | Previous | Next
Steve Kemp, FAQ Maintainer
<skx@tardis.ed.ac.uk>
Valid HTML 4.01!
Last Modified : Thursday 1 August 2002