[Top][All Lists]

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

bug#36871: 26.1; I-search-toggle-csse-fold

From: a_subscriber
Subject: bug#36871: 26.1; I-search-toggle-csse-fold
Date: Thu, 1 Aug 2019 14:13:28 +0300

So, is this e bug?
It will be fix in future version of Emacs?

-----Original Message-----
From: Noam Postavsky <address@hidden> 
Sent: Thursday, August 1, 2019 03:06
To: a_subscriber <address@hidden>
Cc: 'Eli Zaretskii' <address@hidden>; address@hidden
Subject: Re: bug#36871: 26.1; I-search-toggle-csse-fold

retitle 36871 isearch-toggle-case-fold outside of isearch causes unexpected
fontification tags 36871 = confirmed severity 36871 minor quit

"a_subscriber" <address@hidden> writes:

> 1. Start emacs -Q
> 2. Input some text (see step1.jpg)
> 3. M-x isearch-toggle-case-fold   (see step2.jpg)
> 4. C-s (isearch) HELLO  (see step3.jpg) 5. C-g 6. M-x 
> isearch-toggle-case-fold 7. and see result on step4.jpg

Ah, it's not the region, it's highlighting from a not-quite-activated
isearch.  The problem is that isearch-toggle-case-fold wasn't really
expected to be called outside of isearch.  I think throwing an error in this
case makes sense (I tried also just avoiding the call to isearch-update when
isearch-mode is nil which does avoid the OP's problem, but the actual
toggling part doesn't work).

--- i/lisp/isearch.el
+++ w/lisp/isearch.el
@@ -1971,6 +1971,8 @@ isearch-define-mode-toggle
          ,(format "Toggle %s searching on or off.%s" mode
                   (if docstring (concat "\n" docstring) ""))
+         (unless isearch-mode
+           (user-error "isearch not active"))
          ,@(when function
              `((setq isearch-regexp-function
                      (unless (eq isearch-regexp-function #',function)

reply via email to

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