HACKER Q&A
📣 alephnan

Rectangles vs. multi-cursor text editor?


Emacs supports rectangular editing. Other text editors have multiple cursors which kind of solve the same problem.

Which one do you think is superior?


  👤 johncoltrane Accepted Answer ✓
The two approaches aim to solve different problems:

- Multiple cursors is for when you want to apply the same edit to multiple pieces of text.

- Rectangular editing (or visual-block mode in Vim) is for when you want to apply the same edit to multiple, horizontally aligned pieces (often of text of the same length).

The overlap between those problems is rather obvious, as the "rectangular" scenario is really just a special case of the "multiple cursors" scenario.

So, when the current scenario could be solved with either approach, which one to use is mostly a matter of availability, familiarity, and practicality.


👤 vkazanov
A used to use rectangular editing, but switched to the multiple-cursors package years ago. It just works better: both more generic and intuitive.

👤 weitzj
Rectangular