2

One useful feature of Emacs is the ability to save the layout of the current frame to a register C-x r f <letter> and restore it later C-x r j <letter>.

In screen it can be a little tedious trying to reconstruct a layout after closing all but one buffer with C-a Q or something similar. From what I can gather screen does not have anything resembling emacs registers. I'm trying to figure out a way to simulate the emacs feature. Does screen have the ability to dump its current layout state to a file that can be read from later?

1

No - the only files which screen writes are enumerated in screen.h:

#define DUMP_TERMCAP    0 /* WriteFile() options */
#define DUMP_HARDCOPY   1
#define DUMP_EXCHANGE   2
#define DUMP_SCROLLBACK 3

and those are documented in the manual page (none are the layout as such).

  • As a follow-up question, is it even possible to inspect the layout of a running screen process? If there's some way to call screen <arguments> and get the layout, I am just as happy redirecting that to a file and then writing a script to reconstitute the original screen layout. – Gregory Nisbet Oct 6 '16 at 22:49
  • 1
    It's just in memory - I don't know how much work would be needed to make a dump of the layout. – Thomas Dickey Oct 6 '16 at 23:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.