Rectangular text selection in Mac OS X

Just yesterday I accidently “discovered” that some Mac OS X applications allow to select text in a rectangular area, as opposed within the regular text flow, with whole lines between the start and end. Simply holding down the Option-key (fork with alt) before selecting trigges it. This appears to work in at least Xcode, Terminal, Console, Textedit and Preview (but not e.g. Safari, nor Mail). Actually it works in most selectable NSTextField instances.

Update: Looks like a new feature of Leopard, 10.5. Poking around some more it’s even possible to extend text selection while holding down the Apple-key, which then adds the inverse selection of the area. That is: unselected parts are selected, and those already selected previous and inside the new area become unselected.

Interesting that they implemented such an “complex” selection theme (that is quite some lines of code to get right).

Leave a Reply

You must be logged in to post a comment.