[Geany-devel] Geany multicursors patch
Colomban Wendling
lists.ban at xxxxx
Fri May 25 15:09:47 UTC 2012
Hi,
Le 22/05/2012 20:40, Davide Andreoli a écrit :
> 2012/5/21 Dimitar Zhekov <dimitar.zhekov at gmail.com
> <mailto:dimitar.zhekov at gmail.com>>
>
>> [...]
>>
>>> 3. is there a way to really show multiple carets?
>>
>> No easy way AFAIK.
>
>
> hey! you are wrong :P
>
> I found the easy way (that also solve the issue 2). I just enabled
> scintilla
> multiple selections ! in fact scintilla is able to do exactly what I was
> searching for :)
> (thank go to elextr that point me to the right direction in IRC)
>
> ...and now the patch is just a 3 liner:
>
> +++ b/src/editor.c
> @@ -4677,6 +4677,11 @@ static ScintillaObject
> *create_new_sci(GeanyEditor *editor)
> /* virtual space */
> SSM(sci, SCI_SETVIRTUALSPACEOPTIONS,
> editor_prefs.show_virtual_space, 0);
>
> + /* multiple selection */
> + SSM(sci, SCI_SETMULTIPLESELECTION, 1, 0);
> + SSM(sci, SCI_SETADDITIONALSELECTIONTYPING, 1, 0);
> + SSM(sci, SCI_SETRECTANGULARSELECTIONMODIFIER, SCMOD_SUPER, 0);
>
>
> [...]
I was about to dig into the Scintilla doc to check whether that
functionality did already exist when I started reading the thread, but I
see you and Lex already found out it did :)
This is a lot better than the initial implementation and looks like an
awesome feature :)
> [...]
>
>>> note: this is my first geany patch... plese be kind :P
Hey, welcome to the dark side of the force^W application then! :)
Cheers,
Colomban
More information about the Devel
mailing list