unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
@ 2016-03-14 15:28 Drew Adams
  2022-05-12 16:27 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 8+ messages in thread
From: Drew Adams @ 2016-03-14 15:28 UTC (permalink / raw)
  To: 23010

This report was requested by Kaushal Modi in bug #22991.  See that
bug for more context.

This request is for a help key, to show the current state/modes of
Isearch.  The info shown should include all of the possible toggle
states, such as case folding, whitespace folding, regexp/literal, and
char folding, as well as indicate the various toggle keys for these.

This is a _temporary_ stopgap.  What is needed for the next release is a
well designed implementation that provides for easy configuration by
users and switching among _sets_ of character equivalence classes,
toggling of such sets, and toggling of individual equivalence classes.
A useful and supple design will no doubt change the needs for both state
toggling keys (probably at least one "toggle" prefix key) and any help
display about the current state/mode.

For now, the state/mode help could be bound to a new, dedicated key.  Or
it could added to the current mode help, `C-h m'.

Unless it were added to the top of the `C-h m' output, a separate help
key (and separate *Help* content) would probably be better, so users can
easily see all of the state info without scrolling the help window etc.

It is important to provide a succinct summary in a few lines, and then
follow that by any additional detailed info that might be helpful.

Such additional info could give details about the behavior of the
different modes, as well as info about how to change among them.  Yes,
some of that info might repeat some of what is in the `C-h m' output,
but that's OK.

Another possibility might be to add this info to the regular `C-h m'
output, but have a new help key that takes you directly to the part of
that output that shows the current modes and explains the possibile
modes, i.e., scrolls to that part.  That would have the advantage of
providing this info in the context of isearch help in general.

Again, it is likely that the help output for this and the key(s) for
displaying it will change soon.  The char-folding feature is very
immature, and will hopefully be developed quite a bit further.  What
directions that might take are unknown now.


In GNU Emacs 25.1.50.1 (i686-pc-mingw32)
 of 2015-12-10
Repository revision: 6148555ee5a3d0139ae517803718b3e0357933c7
Windowing system distributor 'Microsoft Corp.', version 6.1.7601
Configured using:
 'configure --prefix=/c/Devel/emacs/snapshot/trunk --enable-checking=yes
 --enable-check-lisp-object-type --without-compress-install 'CFLAGS=-Og
 -ggdb3' LDFLAGS=-Lc:/Devel/emacs/lib 'CPPFLAGS=-DGC_MCHECK=1
 -Ic:/Devel/emacs/include''





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2016-03-14 15:28 bug#23010: 25.1.50; Isearch help key to indicate current search state/mode Drew Adams
@ 2022-05-12 16:27 ` Lars Ingebrigtsen
  2022-05-12 16:34   ` Drew Adams
  2022-06-13 12:48   ` Lars Ingebrigtsen
  0 siblings, 2 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-05-12 16:27 UTC (permalink / raw)
  To: Drew Adams; +Cc: 23010, Juri Linkov

Drew Adams <drew.adams@oracle.com> writes:

> This request is for a help key, to show the current state/modes of
> Isearch.  The info shown should include all of the possible toggle
> states, such as case folding, whitespace folding, regexp/literal, and
> char folding, as well as indicate the various toggle keys for these.

I think this sound like it could be vaguely helpful.  I've added Juri to
the CCs; perhaps he has some comments.

I think the utility would be pretty marginal, though -- few users alter
these things dynamically, but go with one single set of states most of
the time.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-12 16:27 ` Lars Ingebrigtsen
@ 2022-05-12 16:34   ` Drew Adams
  2022-05-12 17:30     ` Juri Linkov
  2022-06-13 12:48   ` Lars Ingebrigtsen
  1 sibling, 1 reply; 8+ messages in thread
From: Drew Adams @ 2022-05-12 16:34 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 23010@debbugs.gnu.org, Juri Linkov

> > This request is for a help key, to show the current state/modes of
> > Isearch.  The info shown should include all of the possible toggle
> > states, such as case folding, whitespace folding, regexp/literal, and
> > char folding, as well as indicate the various toggle keys for these.
> 
> I think this sound like it could be vaguely helpful.  I've added Juri
> to the CCs; perhaps he has some comments.
> 
> I think the utility would be pretty marginal, though -- few users alter
> these things dynamically, but go with one single set of states most of
> the time.

Why do you think few users do so?  We've added more
and more such change-state (e.g. toggle) keys over
time.  And we generally try to indicate the current
state (e.g. in the mode-line).

If the state were more visible/available then maybe
more users would "alter these things dynamically"?





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-12 16:34   ` Drew Adams
@ 2022-05-12 17:30     ` Juri Linkov
  2022-05-12 17:43       ` Drew Adams
  0 siblings, 1 reply; 8+ messages in thread
From: Juri Linkov @ 2022-05-12 17:30 UTC (permalink / raw)
  To: Drew Adams; +Cc: Lars Ingebrigtsen, 23010@debbugs.gnu.org

>> > This request is for a help key, to show the current state/modes of
>> > Isearch.  The info shown should include all of the possible toggle
>> > states, such as case folding, whitespace folding, regexp/literal, and
>> > char folding, as well as indicate the various toggle keys for these.
>> 
>> I think this sound like it could be vaguely helpful.  I've added Juri
>> to the CCs; perhaps he has some comments.
>> 
>> I think the utility would be pretty marginal, though -- few users alter
>> these things dynamically, but go with one single set of states most of
>> the time.
>
> Why do you think few users do so?  We've added more
> and more such change-state (e.g. toggle) keys over
> time.  And we generally try to indicate the current
> state (e.g. in the mode-line).
>
> If the state were more visible/available then maybe
> more users would "alter these things dynamically"?

So do you suggest something like what query-replace does
where typing `?' displays help about replacements?
Such a buffer could have a different name, e.g.
" *Isearch status*" and display the values
of all togglable options.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-12 17:30     ` Juri Linkov
@ 2022-05-12 17:43       ` Drew Adams
  2022-05-13 17:03         ` Juri Linkov
  0 siblings, 1 reply; 8+ messages in thread
From: Drew Adams @ 2022-05-12 17:43 UTC (permalink / raw)
  To: Juri Linkov; +Cc: Lars Ingebrigtsen, 23010@debbugs.gnu.org

> So do you suggest something like what query-replace does
> where typing `?' displays help about replacements?
> Such a buffer could have a different name, e.g.
> " *Isearch status*" and display the values
> of all togglable options.

Please read the bug report.  I made several suggestions
in this regard.  But yes, what you ask was included in
the suggestions.
___

I've also made other suggestions elsewhere, regarding
showing more such state in the mode-line.  And I do
that in isearch+.el.  E.g., mode-line lighter tells
you whether case-sensitive and whether regexp searching:

(if case-fold-search
    (if isearch-regexp " R*SEARCH" " ISEARCH")
  (if isearch-regexp " R*search" " Isearch"))

But adding char-folding and other state would be
unmanageable with just a lighter.  I don't suggest
trying to make the lighter communicate more - the
result would be more confusing than helpful.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-12 17:43       ` Drew Adams
@ 2022-05-13 17:03         ` Juri Linkov
  2022-05-13 21:05           ` Drew Adams
  0 siblings, 1 reply; 8+ messages in thread
From: Juri Linkov @ 2022-05-13 17:03 UTC (permalink / raw)
  To: Drew Adams; +Cc: Lars Ingebrigtsen, 23010@debbugs.gnu.org

> I've also made other suggestions elsewhere, regarding
> showing more such state in the mode-line.  And I do
> that in isearch+.el.  E.g., mode-line lighter tells
> you whether case-sensitive and whether regexp searching:
>
> (if case-fold-search
>     (if isearch-regexp " R*SEARCH" " ISEARCH")
>   (if isearch-regexp " R*search" " Isearch"))

I guess R means Regexp search.  But what does the asterisk
after R mean?  On the mode line it usually indicates the
modified buffer.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-13 17:03         ` Juri Linkov
@ 2022-05-13 21:05           ` Drew Adams
  0 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2022-05-13 21:05 UTC (permalink / raw)
  To: Juri Linkov; +Cc: Lars Ingebrigtsen, 23010@debbugs.gnu.org

> > I've also made other suggestions elsewhere, regarding
> > showing more such state in the mode-line.  And I do
> > that in isearch+.el.  E.g., mode-line lighter tells
> > you whether case-sensitive and whether regexp searching:
> >
> > (if case-fold-search
> >     (if isearch-regexp " R*SEARCH" " ISEARCH")
> >   (if isearch-regexp " R*search" " Isearch"))
> 
> I guess R means Regexp search.  But what does the asterisk
> after R mean?  On the mode line it usually indicates the
> modified buffer.

R*search and R*SEARCH are just meant to indicate a
regexp pattern (the former indicating case-sensitive).

The Isearch+ doc says what it means.  But I don't say
you need to follow what I did exactly.

The point was just to say that with very little screen
real estate (a mode-line lighter) we can show, and
dynamically update, a fair amount of info about the
current Isearch state: whether case-insensitive, and
whether regexp searching.

I intend it only as food for thought.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#23010: 25.1.50; Isearch help key to indicate current search state/mode
  2022-05-12 16:27 ` Lars Ingebrigtsen
  2022-05-12 16:34   ` Drew Adams
@ 2022-06-13 12:48   ` Lars Ingebrigtsen
  1 sibling, 0 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-13 12:48 UTC (permalink / raw)
  To: Drew Adams; +Cc: 23010, Juri Linkov

Lars Ingebrigtsen <larsi@gnus.org> writes:

> I think this sound like it could be vaguely helpful.  I've added Juri to
> the CCs; perhaps he has some comments.
>
> I think the utility would be pretty marginal, though -- few users alter
> these things dynamically, but go with one single set of states most of
> the time.

I think the conclusion here is that it would be of marginal utility, so
I'm closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-06-13 12:48 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-14 15:28 bug#23010: 25.1.50; Isearch help key to indicate current search state/mode Drew Adams
2022-05-12 16:27 ` Lars Ingebrigtsen
2022-05-12 16:34   ` Drew Adams
2022-05-12 17:30     ` Juri Linkov
2022-05-12 17:43       ` Drew Adams
2022-05-13 17:03         ` Juri Linkov
2022-05-13 21:05           ` Drew Adams
2022-06-13 12:48   ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).