From: Keith David Bershatsky <esq@lawlist.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 25992@debbugs.gnu.org
Subject: bug#25992: perform-replace leaves mark-active when not transient-mark-mode
Date: Mon, 06 Mar 2017 21:55:47 -0800 [thread overview]
Message-ID: <m2lgsh4om4.wl%esq@lawlist.com> (raw)
In-Reply-To: <m2k283yxg0.wl%esq@lawlist.com>
Thank you very much for the suggestion to check 'mark' prior to calling either 'region-beginning' or 'region-end', as an alternative to testing the variable 'mark-active'.
Keith
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
DATE: Mon, 06 Mar 2017 20:45:32 +0200
FROM: Eli Zaretskii <eliz@gnu.org>
>
> transient-mark-mode
>
> > Date: Mon, 06 Mar 2017 09:06:56 -0800
> > From: Keith David Bershatsky <esq@lawlist.com>
> > Cc: 25992@debbugs.gnu.org
> >
> > In a custom test to determine whether the region is active, I had been testing mark-active prior to using (region-beginning) and/or (region-end) to avoid trowing an error "The mark is not set now, so there is no region". When the following is true `(and mark-active (= (region-beginning) (region-end)))`, my custom function should return nil.
>
> Why can't you just check whether the function 'mark' returns nil?
next prev parent reply other threads:[~2017-03-07 5:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-06 2:02 bug#25992: perform-replace leaves mark-active when not transient-mark-mode Keith David Bershatsky
2017-03-06 16:26 ` Eli Zaretskii
2017-03-06 17:06 ` Keith David Bershatsky
2017-03-06 18:45 ` Eli Zaretskii
2017-03-07 5:55 ` Keith David Bershatsky [this message]
2017-03-07 15:37 ` Eli Zaretskii
2017-03-07 17:32 ` Keith David Bershatsky
2017-03-07 19:25 ` Eli Zaretskii
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=m2lgsh4om4.wl%esq@lawlist.com \
--to=esq@lawlist.com \
--cc=25992@debbugs.gnu.org \
--cc=eliz@gnu.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).