I’ve come across a limitation when it comes to the interaction between running keybind with a
StateCommands and using a
state.changeByRange helper within that
Namely, the problem is that a
StateCommand is expected to return a scalar boolean:
false if CM should move on to other runners bound to that same key, or
true if it should not. The issue I’m having is that when I enable multi-cursor mode, I want to operate over a number of ranges when the keybind is pressed. For some of these ranges, the a certain keybind’s runner might be “sufficient”, i.e. I don’t want that range to be processed by other possible runners with lower precedence. But for some ranges that high precedence runner might not be relevant, at which point I would want to pass those ranges on to the subsequent runners for that keybind.
So in essence, when I’m using a multi-cursor editor, I want a
StateCommand to be able to return an array of booleans, one for each corresponding range. Ranges assigned as
true are not passed on to subsequent runners, ranges with
Does that make sense? I couldn’t see a way to handle this desired behavior with the existing implementation.