emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: region-active-p


From: Stephen J. Turnbull
Subject: Re: region-active-p
Date: Tue, 30 Oct 2007 09:12:59 +0900

Richard Stallman writes:

 > I just double-checked.  What we want for Emacs is closer to your
 > `region-active-p'.  We want it to test for Transient Mark mode with
 > the mark active.
 > 
 >      > I propose to add an optional argument NONEMPTY to region-active-p
 >      > which means "return nil if the region is empty".  How about it?
 > 
 >     No, thank you.  That makes the name inaccurate in XEmacs usage, is not
 >     backwardly compatible
 > 
 > I don't know how to understand "backwardly compatible".  I designed
 > this to make it an upward compatible change for you.  Does "backwardly
 > compatible" mean something else?

Upwardly compatible, yes, but code that uses that argument cannot be
used in current XEmacsen.  The OP, Andreas Roehler, is specifically
going to want to use it, because those are his preferred semantics.
>From the point of view of XEmacs, the additional argument is a clear
nuisance because most of the early uses are presumably going to be by
third parties wishing to eliminate a source of incompatibility, and
they're going to be disappointed.

If you plan to use this API generally in Emacs, then I guess XEmacs
compatibility is a secondary consideration.  If so I would prefer that
you use a different name and the semantics for the argument that
Stefan proposed (or no argument if you also add `region-exists-p' with
XEmacs's semantics).  Then we can add it to XEmacs with less testing
than changing an API, you better semantics (and can ignore the XEmacs
APIs that have semantics that don't look useful to Emacs), and Andreas
gets the semantics that are intuitive to him.

Possible names are `region-usable-p' and `region-nonempty-p'.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]