By workspace, I mean - I need to save the state of my open buffers (possibly in a user specified workspace file) and quickly switch to another set of open buffers, e.g. to conti
HIROSE Yuuji's revive.el has worked nicely for me for quite some time. I use the standard configuration presented in the comments in revive.el. The documentation is well written and revive is very easy to use and configure. In particular, revive.el has better support than some for reviving configurations that are a bit more complex. It is particularly nice if you combine it with the HIROSE Yuuji's windows.el. They are made to work together. windows.el makes it possible to recall window splits, etc. revive.el is built with an eye toward extensibility toward deeper mode integration for particular setups. But for my uses, I have found it to be quite nice out of the box, though I think I'll next tweak it to revive w3m windows which I currently don't have setup (Update: I do now: see bottom).
Here is my revive config. I include some helpful comments, first for windows.el and then revive.el inline:
(provide 'my-revive-config)
(require 'windows) ; use this with revive so that window splits are recallable
; too
(win:startup-with-window) ; start with window 1
;;;[Key Bindings]
;;;
;;; The default prefix key stroke for Windows is `C-c C-w'. If it
;;; causes you some troubles, see the section `Customizations'.
;;; Here are the default key bindings.
;;;
;;; C-c C-w 1 Switch to window 1 (Q)
;;; C-c C-w 2 Switch to window 2 (Q)
;;; :
;;; C-c C-w 9 Switch to window 9 (Q)
;;; C-c C-w 0 Swap windows with the buffer 0 (Q)
;;; (Select unallocated frame(Emacs 19))
;;; C-c C-w SPC Switch to window previously shown (Q)
;;; C-c C-w C-n Switch to next window
;;; C-c C-w C-p Switch to previous window
;;; C-c C-w ! Delete current window (Q)
;;; C-c C-w C-w Window operation menu
;;; C-c C-w C-r Resume menu
;;; C-c C-w C-l Local resume menu
;;; C-c C-w C-s Switch task
;;; C-c C-w = Show window list (Q)
;;;
;;; The key strokes to select windows from 1 to 9 must be
;;; frequently used, so the alternative key strokes `C-c [Num.]' are
;;; available by default (And any function with (Q)mark can be
;;; invoked without C-w). To disable these quick key strokes, set
;;; the variable win:quick-selection to `nil' in your ~/.emacs.
(autoload 'save-current-configuration "revive" "Save status" t)
(autoload 'resume "revive" "Resume Emacs" t)
(autoload 'wipe "revive" "Wipe Emacs" t)
(define-key ctl-x-map "S" 'save-current-configuration)
(define-key ctl-x-map "F" 'resume)
(define-key ctl-x-map "K" 'wipe)
;;;
;;;[How to use]
;;;
;;; Call `save-current-configuration' (`C-x S' if you define key as
;;; above) when you want to save current editing status and call
;;; `resume' to restore it. Numerical prefix arg to them specifies
;;; the buffer number in which the editing status will be saved.
;;; Here the buffer refers to a revive s-exp in ~/.revive.el of
;;; which there can be n
;;;
;;; [Sample Operations]
;;; C-u 2 C-x S ;save status into the buffer #2
;;; C-u 3 C-x F ;load status from the buffer #3
There are variants of this that others like revive-plus.el and a slightly modified clone on github, but I prefer the original.
Update Monday, January 12, 2015: Now I can restore w3m in revive (see revive.el docs for details and in particular look at examples in revive:major-mode-command-alist-default):
(setq revive:major-mode-command-alist-private
'(("*w3m*" . w3m)))
Notice you are telling revive the name of the w3m buffer. Even if you have multiple tabs, only the first one need be enumerated as above.
Here is the w3m variable I have set to restore all tabs from the previous session:
(setq w3m-session-load-last-sessions t)