GNOME Bugzilla – Bug 111091
'Column mode' support similar to UltraEdit
Last modified: 2004-12-22 21:47:04 UTC
From the UltraEdit manual: ************************************************** Column Mode This command changes the operation of the editor for selecting text. When column mode is selected highlighted text is based on the character column position of the first character selected to the column of the last character of text selected. Text selected in this mode does not automatically include all text between the start and end position, but includes all text in the columns between the first and last character selected. Column mode editing is sometimes referred to as block mode editing as the act of selecting text forms a rectangle. Cut, Copy and Paste work with the selected text. Column mode editing requires the Word Wrap be turned off and a fixed pitch font be selected. When column mode is enabled, additional column features are enabled; Insert/Fill Columns, Delete Columns, Cut Columns and Insert Number. Shortcut Keys: ALT+C ************************************************** Full block mode editing support is, in my opinion, one of the features of UE that sets it apart from all other editors. As gedit seems to be getting much inspiration from UE, it would seem fitting for it to also support column mode. Skeptical of its usefulness? Consider the following examples: Example 1: I was recently working on writing some queries for DB2. After writing ~15 queries and starting to test them, I realized that DB2 requires a backslash at the end of every line. In a normal editor, this would be quite a pain. However, with column mode, I simply selected the column I wanted and hit the backslash key ONCE. Much easier with column mode! Example 2: I've got a 50 line block of text that I realize needs to be indented in order to be wrapped in an if() condition. In an ordinary editor, this could be a real pain. With column mode, I simply select the first column of the next, and hit spacebar 3 times. That's it! Example 3: I was recently editing a log file which contained timestamps in the following format: [hh:mm:ss] The target application required the format to be: (hh-mm) The log was ~10000 lines long, so changing all these timestamps could be been a horrifying problem. However, with column mode all I had to do was select the column containing the first '[', then hit '(' ONCE to replace all of them. The ':' and ']' were replaced the same way. Removing the ':ss' was as easy as highlighting those 3 columns and hitting Delete. Done! If anyone wants more information on column mode, either try it out on UltraEdit (Alt+C, or 'Column-->Column Mode'), email me (blueeskimo at gmx.net), or msg me on IRC (#gedit on irc.gimp.org, nick EsKi).
*** This bug has been marked as a duplicate of 96436 ***