unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Slawomir Nowaczyk <slawomir.nowaczyk.847@student.lu.se>
Subject: Re: Difference in major mode autoload between 21.3.x and 22.0.x?
Date: Fri, 14 Oct 2005 14:20:22 +0200	[thread overview]
Message-ID: <20051014140554.240E.SLAWOMIR.NOWACZYK.847@student.lu.se> (raw)
In-Reply-To: <434f677a$0$10226$9b4e6d93@newsread2.arcor-online.net>

On Fri, 14 Oct 2005 10:08:25 +0200
Markus Nißl <mnissl@arcor.de> wrote:

#> Slawomir Nowaczyk wrote:
#> > On Wed, 12 Oct 2005 17:15:53 +0200
#> > Markus Nißl <mnissl@arcor.de> wrote:
#> > 
#> > #> Using Emacs 22.0.50.1, xsl-mode is only loaded automatically when 
#> > #> I create a new xsl file. When I open an existing xsl file, xml 
#> > #> mode is loaded instead.

#> > I suppose you should take a look at magic-mode-alist

#> Thank you very much for your information. I now see where the 
#> different behaviour comes from.

A question to the rest of the list: I have seen this being asked a
couple of time recently... maybe it would make sense to change default
value of magic-mode-alist to not include "xml-mode" and "html-mode" ?

It seems to me that magic-mode-alist makes sense if there is only one
mode for visiting certain type of files... and there seems to be a
couple different modes commonly used for xml and html.

#> By far, I'm no Emacs expert ... so, can you give me a hint in 
#> which way I have to modify magic-mode-alist so that xsl-mode is 
#> being started whenever a file with the extension ".xsl" is loaded?

Well, try this (not tested):

(push magic-mode-alist '("<\\?xml " . nil))

I am sure those better versed in elisp can suggest a nicer solution :)

#> In 21.x, it was a breeze for an elisp novice to copy those two 
#> lines and to adjust them to my needs.

I agree, auto-mode-alist is much easier to customise.

-- 
 Best wishes,
   Slawomir Nowaczyk
     ( slawomir.nowaczyk.847@student.lu.se )

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?

  reply	other threads:[~2005-10-14 12:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-12 15:15 Difference in major mode autoload between 21.3.x and 22.0.x? Markus Nißl
2005-10-12 15:24 ` Slawomir Nowaczyk
     [not found] ` <mailman.11034.1129130655.20277.help-gnu-emacs@gnu.org>
2005-10-14  8:08   ` Markus Nißl
2005-10-14 12:20     ` Slawomir Nowaczyk [this message]
     [not found]     ` <mailman.11338.1129292518.20277.help-gnu-emacs@gnu.org>
2005-10-14 13:02       ` Markus Nißl

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051014140554.240E.SLAWOMIR.NOWACZYK.847@student.lu.se \
    --to=slawomir.nowaczyk.847@student.lu.se \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).