Macro feature request: prevent calls to run() creating undo snapshots

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Macro feature request: prevent calls to run() creating undo snapshots

Jonathan Jackson-2
Dear List,

I'm writing a macro for which having an undo option is very important.  I
can create a snapshot at the beginning of the macro, but (as mentioned on
the macro documentation) calls to run(...) generate new snapshot data which
means the effect of my macro cannot be undone.  

The option to temporarily disable the Edit->Undo is already implemented in
the macro language:
setOption("DisableUndo",true);
setOption("DisableUndo",false);
Would it be appropriate for this setting to also temporarily disable the
creation of new undo snapshots?  That way a macro could create a snapshot at
the beginning and temporarily disable the generation of new snapshots for
the duration of the macro.  Perhaps, if this option is set in a macro, it
should also be un-set when the macro exits or is interupted to restore the
default behaviour.  

I appreciate such a change may have implications beyond what I have
described - any comments?

regards,
Jon