unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Juri Linkov <juri@jurta.org>
Cc: 18697@debbugs.gnu.org, Dima Kogan <dima@secretsauce.net>
Subject: bug#18697: 25.0.50; [PATCH] hi-lock interactive functions now default to the active region, if there is one
Date: Tue, 14 Oct 2014 13:25:50 -0700 (PDT)	[thread overview]
Message-ID: <31b31698-be0a-4886-bf24-33e93fc5b611@default> (raw)
In-Reply-To: <87iojm1kqa.fsf@mail.jurta.org>

> > What IS pointed out in that thread is that there are other ways
> > to pick up text at point, besides using the active region.  And
> > that gives you much more flexibility than hard-wiring the region
> > content as the default value.
> 
> Not *THE* default value, but a list of several default values
> where the active region is its second default value
> (coming after the symbol at point in that list).

Ah, OK, if that's what you meant.  Yes, a user should be
able to choose that, by cycling - at least in some contexts
(see below).  No, in general it should not be the _default_
default value. ;-)  That is, it should not be the first in
the list.

Even so, it would be good for a command for which the active
region defines the command scope to be able to easily exclude
that value from the defaults list, as it makes no sense in
that context.

IOW, my argument still holds: It is not always the case that
it makes sense for a default value for `read-regexp' to be
the content of the active region.  Sometimes it makes a lot
of sense.  Sometimes it makes _no_ sense.  And sometimes it
can make a little sense - a nice-to-have-available choice.

What `read-regexp' is used for depends on the context.
That context (e.g. a particular command) determines whether
and how much it makes sense for the active region to be
used as a default value.

Again, `read-regexp' is a utility function.  Its use cases
are many and varied.





  reply	other threads:[~2014-10-14 20:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-12 22:35 bug#18697: 25.0.50; [PATCH] hi-lock interactive functions now default to the active region, if there is one Dima Kogan
2014-10-12 23:01 ` Drew Adams
2014-10-14 19:32   ` Juri Linkov
2014-10-14 19:48     ` Drew Adams
2014-10-14 20:04       ` Juri Linkov
2014-10-14 20:25         ` Drew Adams [this message]
2014-10-14 21:45           ` Drew Adams
2014-10-13 11:12 ` Ivan Shmakov
2014-10-14 18:51   ` Stefan Monnier
2019-06-25 21:29 ` Lars Ingebrigtsen
2019-06-28 19:09   ` Juri Linkov
2019-06-29 10:14     ` Lars Ingebrigtsen
2019-06-30 20:58       ` Juri Linkov
2019-07-02 12:41         ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=31b31698-be0a-4886-bf24-33e93fc5b611@default \
    --to=drew.adams@oracle.com \
    --cc=18697@debbugs.gnu.org \
    --cc=dima@secretsauce.net \
    --cc=juri@jurta.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).