Emacs - Multiple columns one buffer

后端 未结 7 1155
眼角桃花
眼角桃花 2020-12-04 05:16

I\'m trying to edit some assembly code which tends to be formatted in long but thin listings. I\'d like to be able to use some of the acres of horizontal space I have and s

相关标签:
7条回答
  • 2020-12-04 05:18

    The "Multipager" plugin for Vim can do this with VIM splits for people who want to get this behavior in Vim.

    Get it from Dr. Chip's page: http://mysite.verizon.net/astronaut/vim/index.html#MPAGE

    Docs: http://mysite.verizon.net/astronaut/vim/doc/mpage.txt.html

    0 讨论(0)
  • 2020-12-04 05:27

    Vim can do this using :vsplit - and you can have the same buffer open in multiple "windows" (which are actually sections within a single "window").

    Documentation here

    0 讨论(0)
  • 2020-12-04 05:35

    See follow-mode. Excerpt:

    Follow mode is a minor mode that makes two windows, both showing the same buffer, scroll as a single tall “virtual window.” To use Follow mode, go to a frame with just one window, split it into two side-by-side windows using C-x 3, and then type M-x follow-mode. From then on, you can edit the buffer in either of the two windows, or scroll either one; the other window follows it. In Follow mode, if you move point outside the portion visible in one window and into the portion visible in the other window, that selects the other window—again, treating the two as if they were parts of one large window.
    0 讨论(0)
  • 2020-12-04 05:36

    Use vertical-split with C-x 3. This will split the current buffer into two columns that you can switch between with C-x o.

    0 讨论(0)
  • 2020-12-04 05:37

    this is the default behaviour of emacs when splitting the window (C-x 3 for vertical split) you get two columns which both have the current buffer open

    0 讨论(0)
  • 2020-12-04 05:40

    I use this function to invoke follow-mode, although it would need customization for a different screen size:

    ;;; I want a key to open the current buffer all over the screen.
    (defun all-over-the-screen ()
      (interactive)
      (delete-other-windows)
      (split-window-horizontally)
      (split-window-horizontally)
      (balance-windows)
      (follow-mode t))
    
    0 讨论(0)
提交回复
热议问题