Menu

#1123 Multipaste setting in SciTE

Committed
closed
5
2016-01-18
2015-10-13
b2f9h203
No

When I select multiple locations via rectangular select or ctrl+select and when try to paste something, then only at one location the text is actually pasted, but I want it to be pasted in every line.
Also I loose my multi-selection, so that I have to multi-select again if I want to write something after the paste. (so I guess these are actually two bugs/features)

This seems to be related to: https://sourceforge.net/p/scintilla/bugs/1073/
and: https://sourceforge.net/p/scintilla/bugs/1541/

but as far as I understand those bugs are for the Scintilla-API, which is not directly accessable via the SCiTe-Configuration files.
What I therefore suggest is some configuration option in SciTE named selection.multipaste

My selection settings are:

Sets whether switching to rectangular selection mode while making a selection with the mouse is allowed (1) or not (0). Default is 0.

selection.rectangular.switch.mouse=1

(1) Make multiple selections with the mouse by holding down the Ctrl key.

selection.multiple=1

(1) Allow typing, backspace and delete to affect all selections including each line of rectangular selections. When set to 0, typing only affects the main selection.

selection.additional.typing=1


Also I'm using SciTE Version 3.6.0 compiled for GTK+ 3.16.6 Aug 17 2015 10:20:12 with Debian stable/testing and XFCE.

Discussion

  • Neil Hodgson

    Neil Hodgson - 2015-10-14

    This requires exposing SCI_SETMULTIPASTE in SciTE as a setting and documenting it. It is similar to selection.additional.typing so searching for that is all files in SciTE should reveal where to change.

     
  • Neil Hodgson

    Neil Hodgson - 2015-10-14
    • labels: SciTE -->
     
  • Neil Hodgson

    Neil Hodgson - 2015-10-14
    • labels: --> SciTE, selection
     
  • b2f9h203

    b2f9h203 - 2015-12-14

    Ok, so I did like you said. The only weird thing happening is, that if selection.multipaste is not set in a properties-file then SCI_SETMULTIPASTE will be set to SC_MULTIPASTE_EACH by default.
    This documentation http://www.scintilla.org/ScintillaDoc.html#SCI_SETMULTIPASTE says, that SC_MULTIPASTE_ONCE should be default, though.
    Diff created with:

    diff -Nau /opt/new/scite/src/SciTEProps.cxx /opt/scite/src/SciTEProps.cxx > scite-multipaste.diff
    diff -Nau /opt/new/scite/doc/SciTEDoc.html /opt/scite/doc/SciTEDoc.html >> scite-multipaste.diff
    

    /opt/new/ is actually the original source code. I'm sorry for this unfortunate naming, I just changed the source code and forgot that I need the original to crate the diff.

     

    Last edit: b2f9h203 2015-12-14
  • Neil Hodgson

    Neil Hodgson - 2015-12-15
    • assigned_to: Neil Hodgson
    • Group: Completed --> Committed
     
  • Neil Hodgson

    Neil Hodgson - 2015-12-15

    Committed as [c06e0c]. Credited to "Luyomi".

    It defaults to SC_MULTIPASTE_EACH since you are using 1 (SC_MULTIPASTE_EACH) as the defaultValue argument to GetInt.

     

    Related

    Commit: [c06e0c]

  • Neil Hodgson

    Neil Hodgson - 2016-01-18
    • status: open --> closed
     

Log in to post a comment.