[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: buffer-auto-mode-alist (was: Scratch buffer annoyance)

From: Richard Stallman
Subject: Re: buffer-auto-mode-alist (was: Scratch buffer annoyance)
Date: Mon, 20 Aug 2007 14:31:24 -0400

    I think the best way to implement this feature is to add a new hook
    `after-create-buffer-hook' containing a function that sets buffer
    mode according to `buffer-auto-mode-alist'.  This hook could be called
    from `get-buffer-create'.

I would rather put the code directly into `get-buffer-create' and
avoid using a hook to run it.  When a feature is standardly on, it
is cleaner not to do it using a hook.

    This hook will also help to remove defadvice for `create-file-buffer'
    in uniquify.el when a uniquify renaming function will be appended
    after buffer-auto-mode-alist renaming function in this hook.

That might be a good reason this hook.  But we do not want to depend
on the order of hook functions.  So we should handle
`buffer-auto-mode-alist' explicitly before running the hook.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]