How to unselect text ? lazarus / 9-Editor ---------------------------------------------------------------------- 440bx · 2025-05-01 22:54 Hello, When Editor->General->Selection->persistent block is set and some text has been selected in the editor, it seems the only way to unselect the text is to select some other text. The question is: is there a way to unselect the selected text without having to select some other text ? Also: is there a simple way to invert the selection ? Thank you for your help. ---------------------------------------------------------------------- dsiders · 2025-05-01 23:45 Quote from: 440bx on May 02, 2025, 12:54:37 am When Editor->General->Selection->persistent block is set and some text has been selected in the editor, it seems the only way to unselect the text is to select some other text. The question is: is there a way to unselect the selected text without having to select some other text ? Also: is there a simple way to invert the selection ? None that I'm aware of - for either question. When I try to use it... it feels counter-intuitive. Especially when the Overwrite Block option is enabled (and consequently does nothing). So, I leave it off. ---------------------------------------------------------------------- 440bx · 2025-05-01 23:54 Quote from: dsiders on May 02, 2025, 01:45:55 amNone that I'm aware of - for either question. Thank you @dsiders.  I'm selecting and de-selecting a space (from anywhere) to de-select whatever was previously selected.  It feels a bit hokey but, looks like there is no simple way anyway.  Thanks again. ---------------------------------------------------------------------- Martin_fr · 2025-05-01 23:58 Select and unselect. E.g. (when away from the persistent selection) - Shift + Right to select 1 char - Shift + Left to unselect that char There is a "Hide block", but not sure that may be visible hide only. You can also set the begin to before the end Ctrl-k + k "set block begin/end" => the old ones. What would be "invert"? The only way I understand it, would be to have 2 selections - first from start of text to where the old select began - 2nd from end of old select to end of text And only one selection is supported. ---------------------------------------------------------------------- 440bx · 2025-05-02 00:14 Quote from: Martin_fr on May 02, 2025, 01:58:10 amYou can also set the begin to before the end Ctrl-k + k "set block begin/end" => the old ones. That suggestion put me on the right track.  Ctrl-k + h turns the selection off. Quote from: Martin_fr on May 02, 2025, 01:58:10 amWhat would be "invert"? Whatever was selected gets deselected and whatever was not selected, gets selected. Yes, that can cause more than one area to be selected but, not always.  For instance, if the first line of a file is selected then inverting it, selects the entire file, except the first line. It's usually handy to exclude some text from being searched. Thank you Martin.  That helped.