help-gnu-emacs
[Top][All Lists]
Advanced

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

RE: List of major modes? // "switch-to-mode"??


From: Drew Adams
Subject: RE: List of major modes? // "switch-to-mode"??
Date: Fri, 11 Nov 2005 11:04:43 -0800

    thanks for your detailed explanations. Icicles is very useful indeed.

    Too bad the package installs stuff right upon loading (and actually
    activates the mode as well!), which it shouldn't do...

It should do just what it does. It follows the conventions for a minor mode.
Those conventions were discussed recently in emacs-devel (e.g. wrt a non-nil
initial value for the mode), and I've confirmed that Icicles is doing things
the right way in this regard.

You can easily prevent activating the mode upon load. Simply put this in
your .emacs, before loading icicles.el.

 (setq icicle-mode nil)

The mode will then be inactive when you load the library, and remain so
until you explicitly activate it.

    I'll look more into configuration things later.

There's nothing to configure, unless you want to change some of the
user-option values.

    For now, I'll try to find a predicate that reliably determines a list
    of major modes. That isn't trivial, as the ongoing discussion shows.
    In particular when only autoload information is available, it seems
    like it's pretty much impossible.
    This is sad, because a novice user would certainly be interested in a
    list of installed major modes.

See my previous message - I doubt you will find a fool-proof test for
major-modeness that correctly excludes minor modes.

If you have control over the installation (e.g. Aquamacs), then why can't
you test against an explicit list of the known, installed major modes?

Another possibility (workaround) is to augment your predicate with a test
against a known list of minor modes that aren't in `minor-mode-alist' etc.

HTH - Drew





reply via email to

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