[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

9. Window Configurations

Hyperbole includes the `wconfig.el' package which lets you save and restore window configurations, i.e. the window layout and buffers displayed within an Emacs frame. This is useful to save a particular working context and then to jump back to it at a later time during an Emacs session. It is also useful during demonstrations to pull up many informational artifacts all at once, e.g. all of the windows for a particular subsystem. None of this information is stored between Emacs sessions, so your window configurations will last only through a single session of use.

The wconfig library provides two distinct means of managing window configurations. The first means associates a name with each stored window configuration. The name can then be used to retrieve the window configuration later. The second means uses a ring structure to save window configurations and then allows browsing through the sequence of saved configurations.

The Win/ menu entry on the Hyperbole top-level menu displays a menu of window configuration commands:

 
WinConfig>  AddName  DeleteName  RestoreName  PopRing  SaveRing  YankRing

 
Menu Item       Command                   Description
====================================================================
AddName         wconfig-add-by-name       Name current wconfig
DeleteName      wconfig-delete-by-name    Delete wconfig with name
RestoreName     wconfig-restore-by-name   Restore wconfig by name

PopRing         wconfig-delete-pop        Restore and delete wconfig
SaveRing        wconfig-ring-save         Store wconfig to ring
YankRing        wconfig-yank-pop          Restore next wconfig
====================================================================

Saving and restoring window configurations by name is the easiest method, but it requires that you input the chosen name from the keyboard. The ring commands permit saving and restoring through mouse interaction only, if so desired. The prior section, 4. Smart Keys, mentions how to save and restore window configurations with the Smart Keys. Since the ring commands are a bit more complex than their by-name counterparts, the following paragraphs explain them in more detail.

Wconfig creates a ring structure that operates just like the Emacs kill-ring, section `Kill Ring' in The GNU Emacs Manual, but its elements are window configurations rather than text regions. One can add an element to the ring based upon the current window configuration. After several elements are in the ring, one can walk through all of them in sequence until the desired configuration is restored.

SaveRing executes the wconfig-ring-save command which saves the current window configuration to the ring.

YankRing executes the wconfig-yank-pop command. It restores the window configuration from the currently pointed to configuration in the ring. It does not delete this configuration from the ring but it does move the pointer to the prior ring element. Repeated calls to this command thus restore successive window configurations until the ring pointer wraps around. Simply stop when a desired configuration appears and use {q} to quit from the minibuffer menu.

PopRing calls the wconfig-delete-pop command. It is used to restore a previously saved configuration and at the same time delete it from the ring. Simply stop when a desired configuration appears and use {q} to quit from the minibuffer menu.

The maximum number of elements the ring can hold is set by the wconfig-ring-max variable whose default is 10. Any saves beyond this value cause deletion of the oldest element in the ring before a new one is added.


[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

This document was generated by XEmacs shared group account on December, 19 2009 using texi2html 1.65.