aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2018-02-11 19:59:00 +0200
committerEli Zaretskii2018-02-11 19:59:00 +0200
commitf8a493c800252621403ef281d8a26e4d6d6acd9a (patch)
treea11d783edcb0131187e8c493fc86279ee4cb512f
parent10637af91ac1bf777d880473cc8c804fd6dff4e2 (diff)
downloademacs-f8a493c800252621403ef281d8a26e4d6d6acd9a.tar.gz
emacs-f8a493c800252621403ef281d8a26e4d6d6acd9a.zip
Improve documentation of desktop restoring
* doc/emacs/misc.texi (Saving Emacs Sessions): Document 'desktop-auto-save-timeout', 'desktop-load-locked-desktop', and how to restore desktop in daemon mode. (Bug#30421)
-rw-r--r--doc/emacs/misc.texi31
1 files changed, 30 insertions, 1 deletions
diff --git a/doc/emacs/misc.texi b/doc/emacs/misc.texi
index 5babd5081a9..ae6f9446f28 100644
--- a/doc/emacs/misc.texi
+++ b/doc/emacs/misc.texi
@@ -2485,7 +2485,7 @@ since it bypasses the init file, where @code{desktop-save-mode} is
2485usually turned on. 2485usually turned on.
2486 2486
2487@vindex desktop-restore-eager 2487@vindex desktop-restore-eager
2488 By default, all the buffers in the desktop are restored at one go. 2488 By default, all the buffers in the desktop are restored in one go.
2489However, this may be slow if there are a lot of buffers in the 2489However, this may be slow if there are a lot of buffers in the
2490desktop. You can specify the maximum number of buffers to restore 2490desktop. You can specify the maximum number of buffers to restore
2491immediately with the variable @code{desktop-restore-eager}; the 2491immediately with the variable @code{desktop-restore-eager}; the
@@ -2504,6 +2504,35 @@ expression matching the names of buffers not to kill.
2504 If you want to save minibuffer history from one session to 2504 If you want to save minibuffer history from one session to
2505another, use the @code{savehist} library. 2505another, use the @code{savehist} library.
2506 2506
2507@vindex desktop-auto-save-timeout
2508 While Emacs runs with @code{desktop-save-mode} turned on, it by
2509default auto-saves the desktop whenever any of it changes. The
2510variable @code{desktop-auto-save-timeout} determines how frequently
2511Emacs checks for modifications to your desktop.
2512
2513@vindex desktop-load-locked-desktop
2514 The file in which Emacs saves the desktop is locked while the
2515session runs, to avoid inadvertently overwriting it from another Emacs
2516session. That lock is normally removed when Emacs exits, but if Emacs
2517or your system crashes, the lock stays, and when you restart Emacs, it
2518will by default ask you whether to use the locked desktop file. You
2519can avoid the question by customizing the variable
2520@code{desktop-load-locked-desktop} to either @code{nil}, which means
2521never load the desktop in this case, or @code{t}, which means load the
2522desktop without asking.
2523
2524@cindex desktop restore in daemon mode
2525 When Emacs starts in daemon mode, it cannot ask you any questions,
2526so if it finds the desktop file locked, it will not load it, unless
2527@code{desktop-load-locked-desktop} is @code{t}. Note that restoring
2528the desktop in daemon mode is somewhat problematic for other reasons:
2529e.g., the daemon cannot use GUI features, so parameters such as frame
2530position, size, and decorations cannot be restored. For that reason,
2531you may wish to delay restoring the desktop in daemon mode until the
2532first client connects, by calling @code{desktop-read} in a hook
2533function that you add to @code{after-make-frame-functions}
2534(@pxref{Creating Frames,,, elisp, The Emacs Lisp Reference Manual}).
2535
2507@node Recursive Edit 2536@node Recursive Edit
2508@section Recursive Editing Levels 2537@section Recursive Editing Levels
2509@cindex recursive editing level 2538@cindex recursive editing level