EMACS/AUCTEX and dtx/ins file types

EMACS/AUCTEX and dtx/ins file types

Post by Berge » Thu, 29 Oct 1998 04:00:00



Hello,

I'm running emacs 20.3 and auctex 9.9 on a win95 machine. When I load a file
with the extension .tex I get the menu command for latexing, viewing, etc. But
when I load a file with the extension dtx or ins, don't get the latex, view,
etc commands. What do I have to change to get the*stuff for files with
the extensions dtx and ins.

Thanks,
Scott

 
 
 

EMACS/AUCTEX and dtx/ins file types

Post by Holger Wenze » Thu, 29 Oct 1998 04:00:00


    Bergers> What do I have to change to
    Bergers> get the*stuff for files with the extensions dtx and
    Bergers> ins.

Have a look at the variable auto-mode-alist, which tells emacs what
mode to use for specific filenames and extension.

Put something like

;invoke the appropriate modes when loading the following files
(setq auto-mode-alist
                                        (append auto-mode-alist
                                                                        (list
                                                                         '("\\.dtx\\'" . tex-mode)
                                                                         '("\\.ins\\'" . tex-mode)
                                                                         )))

into your emacs startup file .emacs or whatever this is called under
Windows.

Hth

holger
--
Holger Wenzel                        Institut fuer Technische Mechanik
                                                           RWTH Aachen
phone:  +49/(0)241/80-4624                            Templergraben 64


 
 
 

EMACS/AUCTEX and dtx/ins file types

Post by Kevin Ivor » Thu, 29 Oct 1998 04:00:00



> I'm running emacs 20.3 and auctex 9.9 on a win95 machine. When I load a file
> with the extension .tex I get the menu command for latexing, viewing, etc. But
> when I load a file with the extension dtx or ins, don't get the latex, view,
> etc commands. What do I have to change to get the*stuff for files with
> the extensions dtx and ins.

Here are some lines from my .emacs file. You'll easily figure out what
to do.

;; Add some file names/extensions that Emacs does not recognize automatically
(setq auto-mode-alist
  (append '(("\\.ma?k\\'"     . makefile-mode)
            ("\\.FOR\\'"      . fortran-mode)
            ("\\.dtx\\'"      . latex-mode)
            ("\\.def\\'"      . latex-mode)
            ("\\.clo\\'"      . latex-mode)
            ("\\.ins\\'"      . latex-mode)
            ("\\.dbj\\'"      . latex-mode)
            ("\\.mbs\\'"      . latex-mode)
;           ("\\.e?ps\\'"     . latex-mode) ; fontify PostScript comments
;           ("\\.E?PS\\'"     . latex-mode)
            ("\\.bz2\\(~\\|\\.~[0-9]+~\\)?\\'" nil jka-compr)
;           ("\\.fvwm\\(2\\|95\\)?rc\\'" . fvwm-mode)
            ("\\.js\\'"       . java-mode)
;           ("rc\\'"          . shell-script-mode) ; watch out for .fvwm2rc
            ("\\.s?html?\\'"  . html-helper-mode)
            ("\\.ad\\'"       . x-resource-generic-mode)
            ("\\.pro\\'"      . idl-mode))
          auto-mode-alist))
;;

Kevin
--
  Kevin Ivory                           Tel: +49 5556 979 434
  Max-Planck-Institut fuer Aeronomie    Fax: +49 5556 979 240

D-37191 Katlenburg-Lindau, GERMANY      http://www.veryComputer.com/~kivory2/