Subject: bug#11378: 24.1.50; Suggestion: Let M-i in isearch cycle `search-invisible'

From: Juri Linkov <[email-masked]>
Date: Thu, 30 May 2013 01:45:53 +0300

> A major difference is that my code does not hesitate to use the
> command to toggle the user option value.  I realize you consider
> that a no-no.  I think that commands to toggle user options are
> often a plus, not a minus.  (Think minor-mode variables, if that helps.
> Or think of toggling an option via the options menu.)

Most togglable search variables should preferably have two versions
anyway: the default value (persistent in case of `defcustom') used
initially for every new search (and often consulted in toggling
commands to get the initial default value) and a transient value
used in the currently active search.

This is what `case-fold-search' and `isearch-case-fold-search'
already do and this is a flexible approach.  I intend to
implement the same approach for other search variables as well,
e.g. adding `search-filter-predicates' to hold the default value
for `isearch-filter-predicates'.  The prefix `search-' is more
appropriate for such variables when they are used outside of isearch.
So `isearch-filter-predicates' could be used to incrementally
add/remove filters in isearch-mode, but to use `search-filter-predicates'
in `query-replace', etc.