emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: Flyspell-mode breaks CUA mode


From: Richard M. Stallman
Subject: Re: Flyspell-mode breaks CUA mode
Date: Thu, 03 Nov 2005 16:40:42 -0500

    Why is it setting deactivate-mark?  I thought that was only set by the
    sort of interactive command that shouldn't be used in hooks etc.,
    which makes this problem sound more like a simple bug rather than a
    design problem....

Any change to the buffer sets deactivate-mark.  So flyspell's
post-command-hook should bind deactivate-mark to prevent that.

Does this fix it?

*** flyspell.el 01 Nov 2005 20:34:12 -0500      1.83
--- flyspell.el 03 Nov 2005 11:46:05 -0500      
***************
*** 895,901 ****
  (defun flyspell-post-command-hook ()
    "The `post-command-hook' used by flyspell to check a word in-the-fly."
    (interactive)
!   (let ((command this-command))
      (if (flyspell-check-pre-word-p)
        (save-excursion
          '(flyspell-debug-signal-pre-word-checked)
--- 895,903 ----
  (defun flyspell-post-command-hook ()
    "The `post-command-hook' used by flyspell to check a word in-the-fly."
    (interactive)
!   (let ((command this-command)
!       ;; Prevent anything we do from affecting the mark.
!       deactivate-mark)
      (if (flyspell-check-pre-word-p)
        (save-excursion
          '(flyspell-debug-signal-pre-word-checked)




reply via email to

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