Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I block select in Geany?

Tags:

I often need to select a block of text, like a leading character that occurs on many lines. LibreOffice has block selection. How can I do this in Geany?

For example, I want to remove the pipe and the space at the beginning of each line:

| Create another 'Login Role' for the 'auth' user: | Role name: auth | Password: auth | Role privileges: Create database objects 
like image 803
caduceus Avatar asked Sep 16 '13 07:09

caduceus


People also ask

How do I select a column in geany?

With the cursor just before the first entry of the column, press Ctrl + Alt + Shift + End . This will enlarge the cursor over the full column. Now press Ctrl + Shift + Right and the full column will be selected.

How do you comment selected lines in geany?

Yes there is, you just have to highlight the code you want to comment then right-click, mouse over format and and click on "Comment Line(s)" to comment the lines.


1 Answers

It's called "column mode editing". Look here:

  • http://www.geany.org/manual/current/index.html#column-mode-editing-rectangular-selections

Column mode editing (rectangular selections)

There is basic support for column mode editing. To use it, create a rectangular selection by holding down the Control and Shift keys (or Alt and Shift on Windows) while selecting some text. Once a rectangular selection exists you can start editing the text within this selection and the modifications will be done for every line in the selection.

It is also possible to create a zero-column selection - this is useful to insert text on multiple lines.

like image 118
paulsm4 Avatar answered Nov 12 '22 00:11

paulsm4