Andrew wrote:New functions (and their keyboard shortcuts on Windows):
SelectAll (ctrl-A or A)
CutSelection (ctrl-X)
CopySelection (ctrl-C)
ClearSelection (delete)
ClearOutside (shift-delete)
I've done a quick trial run with the new script, and these all seem to work well. It looks like some of the math isn't valid for tiled layers, though; mouse clicks specifying selection location tend to have their effects halfway across the screen from where they're supposed to be, when there are two or more tiled layers being displayed.
Lose current selection info, or remember it?
If I remember right, MCell had a setting where it automatically dropped the selection before switching to a different mode. As it stands, starting the Lua script will convert any existing selection into an "mselection" (MCellection?) -- but stopping the Lua script doesn't reverse that. I wonder if it would make sense for that behavior to be symmetrical?
That seems a bit tricky, because sometimes you want the selection back and sometimes you want it to disappear. Maybe holding down Shift while quitting the script could convert the mselection back to a regular selection. Otherwise it's hard to move selection information from MCell mode to Golly mode.
The drop/no-drop part is probably mostly just a training issue: before quitting the script, click outside the selection to drop it back into the universe, or hit [Del] to remove it. That's fine unless you want to also retain the size of the current mselection.
Shrink, Shift-click and Ctrl+Space
Other functions that might be worth importing from regular Golly editing are S to shrink the floating selection, Shift+click to resize it and Ctrl+Space to advance the floating selection's contents by one tick without advancing the rest of the universe. Obviously Shift+Space isn't relevant since that's what regular Space does in this context.
Andrew wrote:The new Paste function (invoked via ctrl-V or V) now uses the clipboard data to create a floating selection in the upper left corner of the viewport (and clears any previous selection, like MCell does).
Might it make sense to paste to the last cut or copy location instead of the upper left corner? Not necessarily, I suppose, if the viewport has moved since then.
I think maybe the center of the viewport might be a less awkward default location, though -- I keep having to go and get each new pasted copy, way off in the corner... just because I haven't adjusted my standard Location for Editing Things to that upper left corner yet!
Andrew wrote:It should be easy enough to add some of the extra MCell functionality I haven't bothered implementing (eg. Invert Selection and Fill Selection).
I'm not likely to ask for either of those. Inverted patterns and filled rectangles don't tend to do anything that I'm very interested in... except in Day and Night-type patterns, anyway.
Keyboard control of selection?
"Nudge" and "move" keyboard functionality could be pretty handy, though -- arrow keys move selection one cell, and maybe Shift+arrow keys move the selection by the current scroll distance?
Selection size readout
I like having the status bar showing the selection size reliably. Come to think of it, it seems like there might be a very minor display bug in Golly: you get to see the selection size when you first click-and-drag, but not when you use Shift+click to alter the selection size. The new size flashes on the status bar for just a moment, then disappears again.
Another readout that could be really useful in the Lua script might be the selection's current offset from the last location where the mouse (or arrow-key movements, possibly?) picked it up.
-----------------------
Several of these items I could certainly work on adding myself -- once I'm past my current extended time crunch, which unfortunately may take another month or two.