unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Default minor modes
@ 2008-08-30 12:22 Maurí­cio
  2008-08-30 12:34 ` Lennart Borgman (gmail)
  0 siblings, 1 reply; 2+ messages in thread
From: Maurí­cio @ 2008-08-30 12:22 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

I use:

(setq default-major-mode 'mail-mode)

to set a default major mode on
startup. How can I define default
minor modes to be used when I
change major modes or open new
buffers?

Thanks,
Maurício





^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Default minor modes
  2008-08-30 12:22 Default minor modes Maurí­cio
@ 2008-08-30 12:34 ` Lennart Borgman (gmail)
  0 siblings, 0 replies; 2+ messages in thread
From: Lennart Borgman (gmail) @ 2008-08-30 12:34 UTC (permalink / raw)
  To: Maurí­cio; +Cc: help-gnu-emacs

Maurí­cio wrote:
> Hi,
> 
> I use:
> 
> (setq default-major-mode 'mail-mode)
> 
> to set a default major mode on
> startup. How can I define default
> minor modes to be used when I
> change major modes or open new
> buffers?


Use the major mode hooks.

Each major mode should have (and those I know of have) a hook that is
run at the end of turning it on:

  (add-hook 'default-major-mode-hook 'TURN-ON-MY-MINOR-MODES)




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-08-30 12:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-08-30 12:22 Default minor modes Maurí­cio
2008-08-30 12:34 ` Lennart Borgman (gmail)

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).