Rectangle functions in emacs

前端 未结 3 1334
甜味超标
甜味超标 2021-01-01 19:46

I\'ve read in several places that the rectangle functions in emacs are very useful. I\'ve read a bit about them, and I can\'t quite figure why. I mean, when you want to kill

3条回答
  •  一整个雨季
    2021-01-01 20:23

    In emacs24+ there's also function for numbering lines:

    (rectangle-number-lines START END START-AT &optional FORMAT)
    
    Insert numbers in front of the region-rectangle.
    
    START-AT, if non-nil, should be a number from which to begin
    counting.  FORMAT, if non-nil, should be a format string to pass
    to `format' along with the line count.  When called interactively
    with a prefix argument, prompt for START-AT and FORMAT.
    

    It is binded to C-x r N by default.

提交回复
热议问题