Wonderful... those three lines are helpful. Could they make it to Emacs base or to the manual? On Wed, 10 Apr 2024 at 15:41, Eli Zaretskii wrote: > > From: Pedro Andres Aranda Gutierrez > > Date: Wed, 10 Apr 2024 09:08:08 +0200 > > > > Place the following file as init.el in a directory (e.g. ~/.demacs.d) > > > > ---cut here--- > > (setq inhibit-startup-screen t) > > > > (defun auto-complete-text-off () > > (message "Trying to turn off ispell completion...") > > (setopt text-mode-ispell-word-completion nil)) > > > > (add-hook 'org-mode-hook #'auto-complete-text-off) > > (add-hook 'org-mode-hook #'(lambda() > > (ispell-change-dictionary "en_GB") > > (flyspell-mode t))) > > ---cut here--- > > > > Open a text file and C-h C-v completion-at-point-functions. You should > see > > ispell-completion-at-point in the list of completion functions > > > > Open a .org file and C-h C-v completion-at-point-functions. You see > > ispell-completion-at-point in the list of completion functions, when the > expected behaviour > > is that ispell-completion-at-point is *not* in the list. > > You cannot set this option in a mode hook, that's not how it is > supposed to be used. If you customize the option to nil, any buffer > under Text mode or its derivative created afterwards will have the > completion turned off, that's the intended use of the option. > > If you want to disable the completion selectively in a mode hook of > some descendant of Text mode, you need to remove > ispell-completion-at-point from the appropriate hook explicitly: > > (defun auto-complete-text-off () > (message "Trying to turn off ispell completion...") > (remove-hook 'completion-at-point-functions > #'ispell-completion-at-point t)) > > I see no bug here, just a misunderstanding. > > Eshel, am I missing something here? > -- Fragen sind nicht da, um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler Headaches with a Juju log: unit-basic-16: 09:17:36 WARNING juju.worker.uniter.operation we should run a leader-deposed hook here, but we can't yet