unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Compacting calls to add-hook
@ 2008-07-03 14:55 Nordlöw
  2008-07-03 15:55 ` weber
  2008-07-03 16:19 ` Juanma Barranquero
  0 siblings, 2 replies; 3+ messages in thread
From: Nordlöw @ 2008-07-03 14:55 UTC (permalink / raw)
  To: help-gnu-emacs

Can we make the following repetitive code more compact (perhaps using
a map-function)?:

    (add-hook 'c-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'c++-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'text-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'emacs-lisp-mode-hook '(lambda () (outline-minor-mode
t)))
    (add-hook 'sh-mode-hook '(lambda () (outline-minor-mode t)))2
    (add-hook 'octave-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'matlab-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'help-mode-hook '(lambda () (outline-minor-mode t)))
    (add-hook 'info-mode-hook '(lambda () (outline-minor-mode t)))

/Nordlöw


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

end of thread, other threads:[~2008-07-03 16:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-03 14:55 Compacting calls to add-hook Nordlöw
2008-07-03 15:55 ` weber
2008-07-03 16:19 ` Juanma Barranquero

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