[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Troubles with abbrev-mode
From: |
Tassilo Horn |
Subject: |
Re: Troubles with abbrev-mode |
Date: |
Sat, 30 Sep 2006 00:17:34 +0200 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux) |
Reiner Steib <reinersteib+gmane@imap.cc> writes:
>>> `message-mode' derived from `text-mode': Do we have guidelines /
>>> conventions / best practice in Emacs on how to deal with abbrevs in
>>> derived modes?
>>
>> As I'm not really involved in emacs development I don't know. Should
>> I start a new thread about point 2 in gmane.emacs.devel?
>
> Maybe a good idea.
Gnmpf, I cannot reproduce the problem anymore. I don't even know if the
problem existed sometime at all or if I was confused, which is more
likely.
,----[ ~/uni/repos/heimdall-uni/programs/elisp/th-abbrev.el ]
| [...]
| (define-abbrev-table 'th-emacs-lisp-mode-abbrev-table
| '(("da" "(defalias °)" (lambda ()
| (th-abbrev-set-point)))
| [...] ))))
|
| (add-hook 'emacs-lisp-mode-hook
| (lambda ()
| (setq local-abbrev-table th-emacs-lisp-mode-abbrev-table)
| (th-abbrev-mode-initialize)))
|
| (define-abbrev-table 'th-message-mode-abbrev-table
| '([...]
| ("vg" "Viele Grüße,\n°" (lambda ()
| (th-abbrev-set-point)))))
|
| (add-hook 'message-mode-hook
| (lambda ()
| (setq local-abbrev-table th-message-mode-abbrev-table)
| (th-abbrev-mode-initialize)))
`----
Whenever I add an abbrev interactively it goes into the local
abbrev-table (one of the th-<mode>-abbrev-tables), which is correct.
So the only question is why gnus uses text-mode-abbrev-table (where
interactively added abbrevs go, too) when there's a
message-mode-abbrev-table in `edit-abbrevs' by default.
Regards,
Tassilo
--
A morning without coffee is like something without something else.