[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: turning on SGML mode
From: |
Perry Smith |
Subject: |
Re: turning on SGML mode |
Date: |
Thu, 12 Mar 2020 19:26:16 -0500 |
I think the mode is buffer specific and if the file you are editing has a
suffix that matches a well known suffix, that will trigger the major mode for
that buffer.
Your command doesn’t specify a file to edit but I doubt if you are staying
within the *scratch* buffer.
I think, one option is to replace the setq-default with just (sgml-mode) but,
again, that will be just for the buffer that happens to be the current buffer
when that gets executed. I think you could also add an -f argument to your
command line such as -f '(sgml-mode)'
All this to ask / say: what is an example file name of what you are editing or
… do you actually just say within the *scratch* buffer?
> On Mar 12, 2020, at 4:01 PM, Ulrich Deiters <ulrich.deiters@uni-koeln.de>
> wrote:
>
> Dear all,
>
> I abuse Emacs for my typesetting, i.e., I use Emacs with the psgml
> extension to edit XML documents (where Emacs gives me context-dependent
> menus and automatic syntax checks), translate the XML file to LaTeX,
> and convert the outcome to PDF.
>
> My XML file starts with
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE book SYSTEM "$ATXHOME/xml/book.dtd">
> <article>
> …
>
> and I invoke Emacs by
>
> emacs -l $ATXHOME/interface/cfg_emacs.el -geometry +0+0
>
> where cfg_emacs.el contains definitions of menu points etc.
>
> My problem: Whenever I start Emacs, I need to enter
>
> ESC x sgml-mode
>
> manually. I tried to add
>
> (setq-default major-mode 'sgml-mode)
>
> to the configuration file, but that does not turn on
> the SGML mode. What am I doing wrong?
>
> Kind regards,
>
> Ulrich
>
> --
> Prof. i.R. Dr. Ulrich K. Deiters ______________________________________
> Institut f. Physikalische Chemie \ Greinstr. 4–6, D-50939 Köln
> Universitaet zu Köln /\/\... \ Tel. +49 (0)2232 932964
> _______________________L|L|__|_____\ http://www.uni-koeln.de/deiters/
>