[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: region-active-p
From: |
Andreas Röhler |
Subject: |
Re: region-active-p |
Date: |
Mon, 22 Oct 2007 08:09:01 +0200 |
User-agent: |
KMail/1.9.5 |
Am Sonntag, 21. Oktober 2007 16:48 schrieb Miles Bader:
> Stefan Monnier <address@hidden> writes:
> >> The name `region-active-p'
> >> implies that it doesn't matter whether the region is empty.
> >
> > Not necessarily. I don't consider an empty region as being really
> > "active".
>
> And in many cases an empty-but-"active" region can be pretty confusing
> if you don't realize what's going on... (e.g., undo with an
> empty-but-"active" region used to be _extremely_ confusing, though that
> seems to have been fixed).
>
> -Miles
That's it. I correct my posting from yesterday so far.
It makes no sence to have two forms--`exist' and
`active'-- else.
So I get two new forms:
(defsubst region-exists-p ()
"..."
(not (null (mark))))
(defun region-active-p ()
"..."
(and mark-active transient-mark-mode
(not (eq (region-beginning) (region-end)))))
Installing both makes code in both directions
compatible at that point.
Andreas Röhler
- Re: region-active-p, (continued)
- Re: region-active-p, Richard Stallman, 2007/10/31
- Re: region-active-p, Richard Stallman, 2007/10/31
- Re: region-active-p, Miles Bader, 2007/10/31
- Re: region-active-p, Richard Stallman, 2007/10/31
- Re: region-active-p, Miles Bader, 2007/10/31
- Re: region-active-p, Stefan Monnier, 2007/10/31
- Re: region-active-p, Andreas Röhler, 2007/10/29
- Re: region-active-p,
Andreas Röhler <=
- Re: region-active-p, Stephen J. Turnbull, 2007/10/21
- Re: region-active-p, Reiner Steib, 2007/10/21