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

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

Re: How can I turn on abbrev mode by default?


From: jan
Subject: Re: How can I turn on abbrev mode by default?
Date: 18 Oct 2003 12:57:27 -0700
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1

Dan Anderson <dan@mathjunkies.com> writes:

> > Go to the customization for cperl-mode-hook by doing:
> > 
> >   M-x customize-option RET cperl-mode-hook
> > 
> > Then click on INS and type into the field:
> > 
> >   abbrev-mode
> 
> When I do that it tells me "No match".  CPerlmode is installed in my
> .emacs.d/lisp directory.  Could this be the problem?

Another approach is to just add this to your .emacs file.

(add-hook 'hack-local-variables-hook
          #'(lambda ()
              (when (eq major-mode 'cperl-mode)
                (abbrev-mode 1))))

But why not turn it on all the time. Abbrevs are mode sensitive
anyway. It's even simpler too.

(add-hook 'hack-local-variables-hook
          #'(lambda () (abbrev-mode 1)))

-- 
jan






reply via email to

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