README for context.nl * INSTALLATION * 1. Where to put context.el: Put context in your emacs site-lisp path. On Unix systems this probably is: /usr/local/share/emacs/site-lisp On Win9x or NT systems this is a directory like: c:\emacs\site-lisp 2. Where to put the command to load this mode? The new context mode is not automagically recognized. You have to load it in your ~/.emacs file. Put the following command in this file: (load "context") For xemacs based systems you might want to put it in ~/.xemacs-options 3. Is it compatible with AucTeX? IT'S NOT! This mode extends the tex-mode.el distributed with emacs. AucTeX is a separate and distinct package. 4. Are there more options? Yes, you might want to add (some of) the following commands after the (load "context") command: a. Make ConTeXt your default mode (else you will get plain-tex-mode for new and for existing ConTeXt files): (setq tex-default-mode 'context-mode) b. If you run an msdos shell (you use Win98/NT) to compile your tex/context files, this setting might be useful: (setq tex-using-dosshell t) It translates forward slashes ('/') to backward slashes ('\') so directory changes work. c. PDF viewing is now enabled. You can directly start your favorite PDF viewer if you set: (setq tex-output-extension ".pdf") in your .emacs file. You can set your favorite PDF viewer with: (setq tex-dvi-view-command "acroread *") Or, on Windows using a complete path: (tex-dvi-view-command "start \"c:/Program Files/Adobe/Acrobat 4.0/Reader/AcroRd32.exe\" *") 5. Do you support imenu? Yes. Just select create imenu from the ConTeXt submenu. 6. Do you support outline minor mode? Yes, but only tested with the english interface. * TIPS * Emacs is the world's best editor. In this section some tips what ConTeXt mode can do for you. 1. You get new commands at the top of your TeX menu: - run "texutil --references" - and run context itself. So you can compile within emacs itself. 2. ConTeXt-mode can create a context aware imenu. Load a ConTeXt file with some \hoofdstuk or \paragraaf commands and run: imenu-menubar-add-index (press M-x and type this command) You get now a new menu entry called 'index'. Under this menu you find your document structure so you can jump immediately to the right chapter of (sub)paragraph! 3. ConTeXt-mode has ConTeXt are completions. If you are asked to type something, press the first few characters and press TAB. 4. M-q (fill-paragraph) is also ConTeXt-aware. 5. ConTeXt-mode can insert ConTeXt-aware blocks like \startopsomming .. \stopopsomming. Press C-c C-o and type 'opsomming' (or type 'ops' and press TAB). Next you are asked for any options. Just press RET. Now a \startopsomming _ \stopopsomming block is inserted and the cursor is at the correct point. 6. Automatically insert the correct \stop... for the preceding \start... command? Type: \startopsomming and press RET. Now press C-c C-e and you get a \stopopsomming below it. 7. Turn on outline-minor-mode by typing M-x and typing: outline-minor-mode Now outline minor mode is in effect. You see a two new menu entries. You can now hide/expand chapters, sections, etc. 8. Guy Worthington commented that he used the following settings: ------------------------------ (setq context-run-command "perl d:/texmf/miktex/bin/texexec.pl --passon=\"--src\" *") tex-texutil-references-command "perl d:/texmf/miktex/bin/texutil.pl --references *" tex-shell-file-name "cmdproxy" tex-dvi-print-command "gsview32") ;; msdos-tex-shell http://centaur.maths.qmw.ac.uk/Emacs/ (add-hook 'tex-shell-hook (function (lambda () (require 'msdos-tex-shell)))) ------------------------------ I don't know about msdos-tex-shell, but it might work better this way. Myself, I've no problems with Emacs 20.7 on NT4 with the default shell. 9. You can automatically clos a tag when writing XML in Context by pressing C-c C-/. * KNOWN BUGS * 1. Overrides some LaTeX things, so latex-mode doesn't function that well anymore like C-c C-o. In LaTeX mode this should do LaTeX inserts, in ConTeXt mode it should do ConTeXt inserts. 2. Only the dutch and english interface are supported. However, other interfaces should be easy to add.. * ACKNOLEDGEMENTS * - Guy Worthington found a bug in the provide statement: it still referred to contextnl.el, a far older version. - Tomasz Kosinski reported a problem with Emacs 21, that should be fixed with this release.