Thanks to Gleb, Adrian and Hrvoje.
Shouldn't the help say something about the transient nature of setting
this variable:
`zmacs-region-stays' is a built-in boolean variable.
-- loaded from "filladapt"
Value: nil
Documentation:
Whether the current command will deactivate the region.
Commands which do not wish to affect whether the region is currently
highlighted should set this to t. Normally, the region is turned off after
executing each command that did not explicitly turn it on with the function
zmacs-activate-region. Setting this to true lets a command be non-intrusive.
See the variable `zmacs-regions'.
The same effect can be achieved using the `_' interactive specification.
I propose the following patch:
--- src/editfns.c~ Sat Jul 29 16:31:59 2000
+++ src/editfns.c Thu Aug 3 21:56:11 2000
@@ -2444,6 +2444,8 @@
See the variable `zmacs-regions'.
The same effect can be achieved using the `_' interactive specification.
+
+`zmacs-region-stays' is reset to nil before each command is executed.
*/ );
zmacs_region_stays = 0;
>>>> On Fri, 4 Aug 2000 01:05:39 +0200, Hrvoje Niksic
<hniksic(a)fly.srk.fer.hr> said:
Hrvoje> On Thu, Aug 03, 2000 at 06:18:37PM -0400, Vin Shelton wrote:
> I'm trying to code an interactive function which I want to
run under
> both XEmacs and FSFmacs. I want this function to maintain the region,
> so under XEmacs, I would use:
> (interactive "_")
> "_" is not a valid argument for (interactive) in FSFmacs, however, so
> how can I write this function?
Hrvoje> I believe this should do it:
Hrvoje> (setq zmacs-region-stays t)
- vin