Install PSGML-Jade

  1. Copy and byte-compile the file

    Copy the file psgml-jade.el into your common site-lisp directory, e.g. C:\Programs\emacsen\site-lisp.

    Byte-compile the file psgml-jade.el by typing Alt-x byte-compile-file [Return] site-lisp-path\psgml-jade.el [Return], where site-lisp-path is your site-lisp directory. This creates psgml-jade.elc.

  2. Modify your _emacs

    Insert the following block of code into your _emacs:

         
    ;; load psgml-jade extension
    (setq
      sgml-command-list 
      (list 
       (list "Jade" "c:\\Programs\\OpenJade-1.3\\openjade -c%catalogs -t%backend -d%stylesheet %file" 
         'sgml-run-command t
         '(("jade:\\(.*\\):\\(.*\\):\\(.*\\):E:" 1 2 3)))
       (list "JadeTeX" "jadetex %tex" 
         'sgml-run-command nil)
       (list "JadeTeX PDF" "pdfjadetex %tex"
         'sgml-run-command t)
       (list "dvips" "dvips -o %ps %dvi"
         'sgml-run-command nil)
       (list "View dvi" "windvi %dvi" 
         'sgml-run-background t)
       (list "View PDF" "gsview32 %pdf" 
         'sgml-run-command nil)
       (list "View ps" "gsview32 %ps"
         'sgml-run-command nil))
    )
    
    (setq sgml-sgml-file-extension "sgml")
    
    (setq sgml-dsssl-file-extension "dsl")
    
    (setq sgml-expand-list 
      (list 
       (list "%file" 'file nil)     ; the current file as is
       (list "%sgml" 'file sgml-sgml-file-extension) ;   with given extension
       (list "%tex" 'file "tex")        ;   dito 
       (list "%dvi" 'file "dvi")        ;   dito
       (list "%pdf" 'file "pdf")        ;   dito
       (list "%ps" 'file "ps")      ;   dito
       (list "%dsssl" 'file sgml-dsssl-file-extension) ;   dito
       (list "%dir" 'file nil t)        ; the directory part  
       (list "%stylesheet" 'sgml-dsssl-spec) ; the specified style sheet
       (list "%backend" 'sgml-jade-backend) ; the selected backend
       (list "%catalogs" 'sgml-dsssl-catalogs 'sgml-catalog-files 'sgml-local-catalogs)
                        ; the catalogs listed in sgml-catalog-files and sgml-local-catalogs.
       )
    )
    
    (setq sgml-shell "C:/Programs/emacs211/bin/cmdproxy.exe")
    
    (add-hook 'sgml-mode-hook '(lambda () (require 'psgml-jade)))
          
       
    

    Adjust the path in the line defining sgml-shell to point to your Emacs /bin directory. Adjust the path to the OpenJade binary if necessary. Save your _emacs.