Word/Line select

32 views
Skip to first unread message

Nicholai Benalal

unread,
Nov 16, 2016, 5:25:12 PM11/16/16
to scintilla...@googlegroups.com
Hi,


Scintilla has good actions for double and triple clicking with the mouse. However, it would be really great to have the same action available from the keyboard.



I understand that I could reimplement this stuff on the application side but , but wouldn't it make more sense to have that bound to something like SCI_SELECTWORD and SCI_SELECTLINE?

Best,

Nicholai







Neil Hodgson

unread,
Nov 17, 2016, 2:16:22 AM11/17/16
to scintilla...@googlegroups.com
Nicholai Benalal:

> Scintilla has good actions for double and triple clicking with the mouse. However, it would be really great to have the same action available from the keyboard.
>
> I understand that I could reimplement this stuff on the application side but , but wouldn't it make more sense to have that bound to something like SCI_SELECTWORD and SCI_SELECTLINE?

This is unlikely to be used often enough to get a default key binding but it could be a no-parameter API that can be bound by clients that want it.

To be included, it should work for multiple selections and do something reasonable for rectangular selections. Should include documentation in the “Selection and information” section.

Neil

Nicholai Benalal

unread,
Nov 17, 2016, 9:22:54 AM11/17/16
to scintilla...@googlegroups.com

On 17 November 2016 at 08:16:18 +01:00, Neil Hodgson <nyama...@me.com> wrote:

This is unlikely to be used often enough to get a default key binding but it could be a no-parameter API that can be bound by clients that want it.
OK, that also sounds fine. I didn't really consider the fact that all SCI_* actions would have key bindings but I guess that's the default case for Scintilla. 

Out of curiosity, why isn't word select used so much? I personally use it a lot with the mouse but it's annoying to get your hands off the keyboard. For instance Visual Studio has ctrl-W for that. To me, that function would be more useful than the existing word extend left/right but that probably has a lot to do with user preferences.

To be included, it should work for multiple selections and do something reasonable for rectangular selections. Should include documentation in the “Selection and information” section.


As for the implementation, it sounds a bit complicated to support multiple selections and rectangular selections. Not sure I would know exactly how that should be done. I was more thinking to have the exact same actions as the corresponding mouse clicks but I can see your point.

Neil Hodgson

unread,
Nov 17, 2016, 5:17:34 PM11/17/16
to scintilla...@googlegroups.com
Nicholai Benalal:

> Out of curiosity, why isn't word select used so much?

Its likely that the word forward and back extend selection are used since they are based on the word forward and back movement commands. Or people use the mouse.

> I personally use it a lot with the mouse but it's annoying to get your hands off the keyboard. For instance Visual Studio has ctrl-W for that.

Ctrl+W is more commonly bound to closing the file or page.

> As for the implementation, it sounds a bit complicated to support multiple selections and rectangular selections. Not sure I would know exactly how that should be done.

Look at the closest similar command that works in multiple selection mode SCI_WORDLEFTEXTEND.

> I was more thinking to have the exact same actions as the corresponding mouse clicks but I can see your point.

If it only worked for single selection then a bug report would surely soon arrive.

One of the hassles with contributing to a mature project is that a lot of existing features will interact with any new one and they should work together in a consistent way.

Neil

Reply all
Reply to author
Forward
0 new messages