------------------------------------------------------------ revno: 116476 committer: Glenn Morris branch nick: trunk timestamp: Wed 2014-02-19 00:34:45 -0800 message: Some remember doc * doc/misc/remember.texi: Copyedits. (Quick Start): No need for manual autoloads. Mention remember-notes. (Function Reference): Update arguments. Add new commands. * lisp/textmodes/remember.el: Set maintainer to emacs-devel according to remember.texi. Move provide statement to end. (remember-mode-map, remember-notes-mode-map, remember-notes-mode) (remember-notes): Doc fixes. diff: === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2014-02-18 08:09:51 +0000 +++ doc/misc/ChangeLog 2014-02-19 08:34:45 +0000 @@ -1,3 +1,9 @@ +2014-02-19 Glenn Morris + + * remember.texi: Copyedits. + (Quick Start): No need for manual autoloads. Mention remember-notes. + (Function Reference): Update arguments. Add new commands. + 2014-02-18 Glenn Morris * remember.texi (copying): Bump remember mode version. === modified file 'doc/misc/remember.texi' --- doc/misc/remember.texi 2014-02-18 08:09:51 +0000 +++ doc/misc/remember.texi 2014-02-19 08:34:45 +0000 @@ -96,8 +96,8 @@ There are many different databases out there---and good ones---which this mode is not trying to replace. Rather, it's how that data gets there that's the question. Most of the time, we just want to say -"Remember so-and-so's phone number, or that I have to buy dinner for the -cats tonight." That's the FACT@. How it's stored is really the +``Remember so-and-so's phone number, or that I have to buy dinner for the +cats tonight.'' That's the FACT@. How it's stored is really the computer's problem. But at this point in time, it's most definitely also the user's problem, and sometimes so laboriously so that people just let data slip, rather than expend the effort to record it. @@ -175,7 +175,7 @@ @itemize @item -Type @kbd{M-x remember}. The @samp{*Remember*} buffer should be +Type @kbd{M-x remember}. The @file{*Remember*} buffer should be displayed. @item @@ -185,7 +185,7 @@ @item Type @kbd{C-c C-c} (@code{remember-finalize}) to save the note and close -the @samp{*Remember*} buffer. +the @file{*Remember*} buffer. @end itemize By default, @code{remember-finalize} saves the note in @file{~/emacs.d/notes}. @@ -194,7 +194,7 @@ to the end. To remember a region of text, use the universal prefix. @kbd{C-u M-x -remember} displays a @samp{*Remember*} buffer with the region as the +remember} displays a @file{*Remember*} buffer with the region as the initial contents. As a simple beginning, you can start by using the Text File backend, @@ -203,26 +203,23 @@ end of the file. Every so often, you can move the data that gets appended there into other files, or reorganize your document. -You can also store remembered data in other backends. -(@pxref{Backends}) +You can also store remembered data in other backends. @xref{Backends}. -Here is one way to map the remember functions in your @file{.emacs} to +Here is one way to map the remember functions in your init file to very accessible keystrokes facilities using the mode: @lisp -(autoload 'remember ``remember'' nil t) -(autoload 'remember-region ``remember'' nil t) - (define-key global-map (kbd " r") 'remember) (define-key global-map (kbd " R") 'remember-region) @end lisp By default, remember uses the first annotation returned by @code{remember-annotation-functions}. To include all of the annotations, -set @code{remember-run-all-annotation-functions-flag} to non-nil. +set @code{remember-run-all-annotation-functions-flag} to a +non-@code{nil} value. @defopt remember-run-all-annotation-functions-flag -Non-nil means use all annotations returned by +Non-@code{nil} means use all annotations returned by @code{remember-annotation-functions}. @end defopt @@ -237,17 +234,32 @@ (call-interactively 'remember))) @end lisp +@cindex notes +The @code{remember-notes} command creates a @dfn{notes} buffer that +visits the file specified by the option @code{remember-data-file}. +The option @code{remember-notes-buffer-name} specifies the name of the +buffer. The buffer uses @code{remember-notes-initial-major-mode} and +@code{remember-notes-mode} minor mode. Use @kbd{C-c C-c} to save +and bury the buffer. The command @code{save-some-buffers} saves this +buffer without asking. This function is a suitable setting for +@code{initial-buffer-choice}. + + @node Function Reference @chapter Function Reference @file{remember.el} defines the following interactive functions: -@defun remember initial +@defun remember &optional initial Remember an arbitrary piece of data. With a prefix, it will use the region as @var{initial}. @end defun -@defun remember-region beg end +@defun remember-other-frame &optional initial +Like @code{remember}, but uses a new frame. +@end defun + +@defun remember-region &optional beg end If called from within the remember buffer, @var{beg} and @var{end} are ignored, and the entire buffer will be remembered. If called from any other buffer, that region, plus any context information specific to @@ -263,13 +275,37 @@ Remember the contents of the current buffer. @end defun +@defun remember-destroy +Destroy the current remember buffer. +@end defun + @defun remember-mode -This enters the major mode for output from @command{remember}. This +This enters the major mode for output from @code{remember}. This buffer is used to collect data that you want remember. Just hit @kbd{C-c C-c} when you're done entering, and it will go ahead and file the data for latter retrieval, and possible indexing. @end defun +@defun remember-notes &optional switch-to +This returns the notes buffer, creating it if needed, and switches +to it if called interactively (or if @var{switch-to} is non-@code{nil}). +The notes buffer visits @code{remember-data-file}, and +is named @code{remember-notes-buffer-name}. It uses +@code{remember-notes-initial-major-mode} and @code{remember-notes-mode} +minor mode. +@end defun + +@defun remember-notes-mode &optional arg +This is a minor mode for the notes buffer. It sets +@code{buffer-save-without-query} so that @code{save-some-buffers} will +save the notes buffer without asking. Use @kbd{C-c C-c} to +run the command @code{remember-notes-save-and-bury-buffer}. +@end defun + +@defun remember-notes-save-and-bury-buffer +Save (if it is modified) and bury the current buffer. +@end defun + @node Keystrokes @chapter Keystroke Reference @@ -277,14 +313,12 @@ @table @kbd -@item C-c C-c (`remember-finalize') -Remember the contents of the current buffer. - -@item C-c C-k (`remember-destroy') -Destroy the current *Remember* buffer. - -@item C-x C-s (`remember-finalize') -Remember the contents of the current buffer. +@item C-c C-c +@itemx C-x C-s +Remember the contents of the current buffer (`remember-finalize'). + +@item C-c C-k +Destroy the current @file{*Remember*} buffer (`remember-destroy'). @end table @@ -359,7 +393,7 @@ @defopt remember-diary-file File for extracted diary entries. -If this is nil, then @code{diary-file} will be used instead." +If this is @code{nil}, then @code{diary-file} will be used instead. @end defopt @node Mailbox === modified file 'etc/NEWS' --- etc/NEWS 2014-02-18 08:09:51 +0000 +++ etc/NEWS 2014-02-19 08:34:45 +0000 @@ -713,13 +713,9 @@ ** Remember -*** The new command `remember-notes' creates a buffer that is saved on -`kill-emacs'. You can think of it as a *scratch* buffer whose content -is preserved. In fact, it was designed as a replacement for *scratch* -buffer and can be used that way by setting `initial-buffer-choice' to -`remember-notes' and `remember-notes-buffer-name' to "*scratch*". -Without the second change, the *scratch* buffer will still be there -for notes that do not need to be preserved. ++++ +*** The new command `remember-notes' creates a buffer that is saved on exit. +You can use it as a more permanent *scratch* buffer. +++ *** Remember can now store notes in separate files. === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2014-02-18 18:14:36 +0000 +++ lisp/ChangeLog 2014-02-19 08:34:45 +0000 @@ -1,3 +1,9 @@ +2014-02-19 Glenn Morris + + * textmodes/remember.el: Move provide statement to end. + (remember-mode-map, remember-notes-mode-map, remember-notes-mode) + (remember-notes): Doc fixes. + 2014-02-18 Stefan Monnier * delsel.el (delete-char): Restore incorrectly erased property === modified file 'lisp/textmodes/remember.el' --- lisp/textmodes/remember.el 2014-02-18 08:09:51 +0000 +++ lisp/textmodes/remember.el 2014-02-19 08:34:45 +0000 @@ -3,6 +3,7 @@ ;; Copyright (C) 1999-2001, 2003-2014 Free Software Foundation, Inc. ;; Author: John Wiegley +;; Maintainer: emacs-devel@gnu.org ;; Created: 29 Mar 1999 ;; Version: 2.0 ;; Keywords: data memory todo pim @@ -178,8 +179,6 @@ ;;; Code: -(provide 'remember) - (defconst remember-version "2.0" "This version of remember.") @@ -230,6 +229,8 @@ :type 'boolean :group 'remember) +;; See below for more user variables. + ;;; Internal Variables: (defvar remember-buffer "*Remember*" @@ -553,7 +554,7 @@ (define-key map "\C-c\C-c" 'remember-finalize) (define-key map "\C-c\C-k" 'remember-destroy) map) - "Keymap used in Remember mode.") + "Keymap used in `remember-mode'.") (define-derived-mode remember-mode indented-text-mode "Remember" "Major mode for output from \\[remember]. @@ -599,10 +600,14 @@ (let ((map (make-sparse-keymap))) (define-key map "\C-c\C-c" 'remember-notes-save-and-bury-buffer) map) - "Keymap used in remember-notes mode.") + "Keymap used in `remember-notes-mode'.") (define-minor-mode remember-notes-mode - "Minor mode for the `remember-notes' buffer." + "Minor mode for the `remember-notes' buffer. +This sets `buffer-save-without-query' so that `save-some-buffers' will +save the notes buffer without asking. + +\\{remember-notes-mode-map}" nil nil nil (cond (remember-notes-mode @@ -612,29 +617,25 @@ ;;;###autoload (defun remember-notes (&optional switch-to) - "Creates notes buffer and switches to it if called interactively. - -If a notes buffer created by a previous invocation of this -function already exist, it will be returned. Otherwise a new -buffer will be created whose content will be read from file -pointed by `remember-data-file'. If a buffer visiting this file -already exist, that buffer will be used instead of creating a new -one (see `find-file-noselect' function for more details). - -Name of the created buffer is taken from `remember-notes-buffer-name' -variable and if a buffer with that name already exist (but was not -created by this function), it will be first killed. -\\ -`remember-notes-mode' is active in the notes buffer which by default -contains only one \\[save-and-bury-buffer] binding which saves and -buries the buffer. - -Function returns notes buffer. When called interactively, -switches to it as well. - -Notes buffer is meant for keeping random notes which you'd like to -preserve across Emacs restarts. The notes will be stored in the -`remember-data-file'." + "Return the notes buffer, creating it if needed, and maybe switch to it. +This buffer is for notes that you want to preserve across Emacs sessions. +The notes are saved in `remember-data-file'. + +If a buffer is already visiting that file, just return it. + +Otherwise, create the buffer, and rename it to `remember-notes-buffer-name', +unless a buffer of that name already exists. Set the major mode according +to `remember-notes-initial-major-mode', and enable `remember-notes-mode' +minor mode. + +Use \\\\[remember-notes-save-and-bury-buffer] to save and bury the notes buffer. + +Interactively, or if SWITCH-TO is non-nil, switch to the buffer. +Return the buffer. + +Set `initial-buffer-choice' to `remember-notes' to visit your notes buffer +when Emacs starts. Set `remember-notes-buffer-name' to \"*scratch*\" +to turn the *scratch* buffer into your notes buffer." (interactive "p") (let ((buf (or (find-buffer-visiting remember-data-file) (with-current-buffer (find-file-noselect remember-data-file) @@ -662,4 +663,6 @@ nil) t)) +(provide 'remember) + ;;; remember.el ends here ------------------------------------------------------------ revno: 116475 committer: Glenn Morris branch nick: trunk timestamp: Tue 2014-02-18 13:15:29 -0500 message: * doc/emacs/trouble.texi (Contributing) [WWW_GNU_ORG]: Link to gnu.org version of etc/CONTRIBUTE in html output. diff: === modified file 'doc/emacs/ChangeLog' --- doc/emacs/ChangeLog 2014-02-18 01:33:30 +0000 +++ doc/emacs/ChangeLog 2014-02-18 18:15:29 +0000 @@ -1,5 +1,8 @@ 2014-02-18 Glenn Morris + * trouble.texi (Contributing) [WWW_GNU_ORG]: Link to + gnu.org version of etc/CONTRIBUTE in html output. + * misc.texi (Saving Emacs Sessions): Mention desktop-auto-save-timeout. 2014-02-17 Stefan Monnier === modified file 'doc/emacs/trouble.texi' --- doc/emacs/trouble.texi 2014-01-09 19:40:57 +0000 +++ doc/emacs/trouble.texi 2014-02-18 18:15:29 +0000 @@ -1174,7 +1174,18 @@ See the Emacs project page @url{http://savannah.gnu.org/projects/emacs/} for details. -For more information on how to contribute, see the @file{etc/CONTRIBUTE} +For more information on how to contribute, see the +@ifset WWW_GNU_ORG +@ifhtml +@url{http://gnu.org/software/emacs/CONTRIBUTE, etc/CONTRIBUTE} +@end ifhtml +@ifnothtml +@file{etc/CONTRIBUTE} +@end ifnothtml +@end ifset +@ifclear WWW_GNU_ORG +@file{etc/CONTRIBUTE} +@end ifclear file in the Emacs distribution. @node Service ------------------------------------------------------------ revno: 116474 fixes bug: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16795 committer: Stefan Monnier branch nick: trunk timestamp: Tue 2014-02-18 13:14:36 -0500 message: * lisp/delsel.el (delete-char): Restore incorrectly erased property. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2014-02-18 17:33:37 +0000 +++ lisp/ChangeLog 2014-02-18 18:14:36 +0000 @@ -1,3 +1,8 @@ +2014-02-18 Stefan Monnier + + * delsel.el (delete-char): Restore incorrectly erased property + (bug#16795). + 2014-02-18 Juanma Barranquero * frameset.el (frameset--restore-frame): When a frame is being reused @@ -17,19 +22,18 @@ 2014-02-17 Alan Mackenzie Connect electric-indent-mode up with CC Mode. Bug #15478. - * progmodes/cc-mode.el (c-initialize-cc-mode): add CC Mode hooks + * progmodes/cc-mode.el (c-initialize-cc-mode): Add CC Mode hooks to electric-indent-{,local-}-mode. - (c-basic-common-init): Set electric-indent-inhibit. Initialise - c-electric-flag from electric-indent-mode. + (c-basic-common-init): Set electric-indent-inhibit. + Initialise c-electric-flag from electric-indent-mode. (c-electric-indent-mode-hook, c-electric-indent-local-mode-hook): - New hook functions which propagate electric-indent-mode to CC - Mode. + New hook functions which propagate electric-indent-mode to CC mode. * progmodes/cc-cmds.el (c-toggle-electric-state): When C-c C-l is - hit, toggle electric-indent-local-moode. + hit, toggle electric-indent-local-mode. - * electric.el (electric-indent-mode-has-been-called): New - variable. + * electric.el (electric-indent-mode-has-been-called): + New variable. 2014-02-17 Juanma Barranquero === modified file 'lisp/delsel.el' --- lisp/delsel.el 2014-02-10 01:34:22 +0000 +++ lisp/delsel.el 2014-02-18 18:14:36 +0000 @@ -181,6 +181,9 @@ (put 'yank 'delete-selection 'yank) (put 'clipboard-yank 'delete-selection 'yank) (put 'insert-register 'delete-selection t) +;; delete-backward-char and delete-forward-char already delete the selection by +;; default, but not delete-char. +(put 'delete-char 'delete-selection 'supersede) (put 'reindent-then-newline-and-indent 'delete-selection t) (put 'newline-and-indent 'delete-selection t) ------------------------------------------------------------ revno: 116473 committer: Juanma Barranquero branch nick: trunk timestamp: Tue 2014-02-18 18:33:37 +0100 message: lisp/frameset.el: Workaround bug#16793. lisp/frameset.el (frameset--restore-frame): When a frame is being reused and its root window is not alive, delete all the frame's windows before restoring the window state. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2014-02-18 08:09:51 +0000 +++ lisp/ChangeLog 2014-02-18 17:33:37 +0000 @@ -1,3 +1,9 @@ +2014-02-18 Juanma Barranquero + + * frameset.el (frameset--restore-frame): When a frame is being reused + and its root window is not alive, delete all the frame's windows before + restoring the window state. This works around the issue in bug#16793. + 2014-02-18 Glenn Morris * textmodes/remember.el (remember-data-directory) === modified file 'lisp/frameset.el' --- lisp/frameset.el 2014-02-17 16:01:43 +0000 +++ lisp/frameset.el 2014-02-18 17:33:37 +0000 @@ -932,7 +932,11 @@ (setq frame (frameset--find-frame-if nil display)))) ;; If found, remove from the list. (when frame - (setq frameset--reuse-list (delq frame frameset--reuse-list))) + (setq frameset--reuse-list (delq frame frameset--reuse-list)) + ;; Workaround for feature/bug#16793 + (let ((root (frame-root-window frame))) + (unless (window-live-p root) + (delete-other-windows-internal (frame-first-window root) root)))) frame)) (defun frameset--initial-params (parameters) ------------------------------------------------------------ revno: 116472 committer: martin rudalics branch nick: trunk timestamp: Tue 2014-02-18 11:52:00 +0100 message: Don't set FRAME_PIXEL_HEIGHT and FRAME_PIXEL_WIDTH in update_various_frame_slots (Bug#16736). * widget.c (update_various_frame_slots): Don't set FRAME_PIXEL_HEIGHT and FRAME_PIXEL_WIDTH here (Bug#16736). diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2014-02-18 07:46:38 +0000 +++ src/ChangeLog 2014-02-18 10:52:00 +0000 @@ -1,3 +1,8 @@ +2014-02-18 Martin Rudalics + + * widget.c (update_various_frame_slots): Don't set + FRAME_PIXEL_HEIGHT and FRAME_PIXEL_WIDTH here (Bug#16736). + 2014-02-18 Michael Albinus * dbusbind.c (xd_close_bus): Apply proper check on busobj. === modified file 'src/widget.c' --- src/widget.c 2014-01-01 07:43:34 +0000 +++ src/widget.c 2014-02-18 10:52:00 +0000 @@ -599,8 +599,13 @@ { struct frame *f = ew->emacs_frame.frame; struct x_output *x = f->output_data.x; + /* Don't do that: It confuses the check in change_frame_size_1 whether + the pixel size of the frame changed due to a change of the internal + border width. Bug#16736. */ +#if 0 FRAME_PIXEL_HEIGHT (f) = ew->core.height + x->menubar_height; FRAME_PIXEL_WIDTH (f) = ew->core.width; +#endif f->internal_border_width = ew->emacs_frame.internal_border_width; } ------------------------------------------------------------ revno: 116471 committer: Glenn Morris branch nick: trunk timestamp: Tue 2014-02-18 00:09:51 -0800 message: Some remember doc * doc/misc/remember.texi (copying): Bump remember mode version. (Installation): Remove unnecessary chapter. (Quick Start): No need to explicitly load remember.el. (Separate Text Files): New section. * lisp/textmodes/remember.el (remember-data-directory) (remember-directory-file-name-format, remember-store-in-files) (remember-notes-initial-major-mode, remember-notes-bury-on-kill) (remember-notes-save-and-bury-buffer) (remember-notes--kill-buffer-query): Doc fixes. * etc/NEWS: Related edit. diff: === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2014-02-17 18:40:09 +0000 +++ doc/misc/ChangeLog 2014-02-18 08:09:51 +0000 @@ -1,3 +1,10 @@ +2014-02-18 Glenn Morris + + * remember.texi (copying): Bump remember mode version. + (Installation): Remove unnecessary chapter. + (Quick Start): No need to explicitly load remember.el. + (Separate Text Files): New section. + 2014-02-17 Glenn Morris * eieio.texi (Class Values, CLOS compatibility): === modified file 'doc/misc/remember.texi' --- doc/misc/remember.texi 2014-01-27 02:02:28 +0000 +++ doc/misc/remember.texi 2014-02-18 08:09:51 +0000 @@ -7,7 +7,7 @@ @c %**end of header @copying -This manual is for Remember Mode, version 1.9 +This manual is for Remember Mode, version 2.0 Copyright @copyright{} 2001, 2004--2005, 2007--2014 Free Software Foundation, Inc. @@ -54,7 +54,6 @@ @menu * Preface:: About the documentation. * Introduction:: What is Remember Mode? -* Installation:: How to install Remember. * Implementation:: How Remember came into existence. * Quick Start:: Get started using Remember. * Function Reference:: Interactive functions in remember.el. @@ -69,6 +68,7 @@ Backends * Text File:: Saving to a text file. +* Separate Text Files:: Saving to separate text files. * Diary:: Saving to a Diary file. * Mailbox:: Saving to a mailbox. * Org:: Saving to an Org Mode file. @@ -128,18 +128,6 @@ manual-ness which computers from the very beginning have been championed as being able to reduce. -@node Installation -@chapter Installation - -Installing Remember Mode is as simple as adding the following lines to -your Emacs configuration file (usually @file{~/.emacs.d/init.el} or -@file{~/.emacs}). - -@lisp -(add-to-list 'load-path "/path/to/remember") -(require 'remember) -@end lisp - @node Implementation @chapter Implementation @@ -187,14 +175,11 @@ @itemize @item -Load @file{remember.el}. - -@item -Type @kbd{M-x remember}. The @samp{*Remember*} buffer should be +Type @kbd{M-x remember}. The @samp{*Remember*} buffer should be displayed. @item -Type in what you want to remember. The first line will be treated as +Type in what you want to remember. The first line will be treated as the headline, and the rest of the buffer will contain the body of the note. @@ -204,18 +189,18 @@ @end itemize By default, @code{remember-finalize} saves the note in @file{~/emacs.d/notes}. -You can edit it now to see the remembered and timestamped note. You -can edit this file however you want. New entries will always be added +You can edit it now to see the remembered and timestamped note. You +can edit this file however you want. New entries will always be added to the end. -To remember a region of text, use the universal prefix. @kbd{C-u M-x +To remember a region of text, use the universal prefix. @kbd{C-u M-x remember} displays a @samp{*Remember*} buffer with the region as the initial contents. As a simple beginning, you can start by using the Text File backend, keeping your @file{~/.emacs.d/notes} file in outline-mode format, with a final -entry called @samp{* Raw data}. Remembered data will be added to the -end of the file. Every so often, you can move the data that gets +entry called @samp{* Raw data}. Remembered data will be added to the +end of the file. Every so often, you can move the data that gets appended there into other files, or reorganize your document. You can also store remembered data in other backends. @@ -233,7 +218,7 @@ @end lisp By default, remember uses the first annotation returned by -@code{remember-annotation-functions}. To include all of the annotations, +@code{remember-annotation-functions}. To include all of the annotations, set @code{remember-run-all-annotation-functions-flag} to non-nil. @defopt remember-run-all-annotation-functions-flag @@ -242,7 +227,7 @@ @end defopt You can write custom functions that use a different set of -remember-annotation-functions. For example: +remember-annotation-functions. For example: @lisp (defun my/remember-with-filename () @@ -258,7 +243,7 @@ @file{remember.el} defines the following interactive functions: @defun remember initial -Remember an arbitrary piece of data. With a prefix, it will use the +Remember an arbitrary piece of data. With a prefix, it will use the region as @var{initial}. @end defun @@ -310,6 +295,7 @@ @menu * Text File:: Saving to a text file. +* Separate Text Files:: Saving to separate text files. * Diary:: Saving to a Diary file. * Mailbox:: Saving to a mailbox. * Org:: Saving to an Org Mode file. @@ -335,6 +321,30 @@ The text used to begin each remember item. @end defopt + +@node Separate Text Files +@section Saving to Separate Text Files +@cindex text files, saving to separate + +@subheading Insinuation + +@lisp +(setq remember-handler-functions '(remember-store-in-files)) +@end lisp + +@subheading Options + +@defopt remember-data-directory +The directory in which to store remember data as files. +@end defopt + +@defopt remember-directory-file-name-format +A format string to use for naming files in the remember directory. +File names are formed by calling @code{format-time-string} at the time +of saving, using this format string. +@end defopt + + @node Diary @section Saving to a Diary file @cindex diary, integration === modified file 'etc/NEWS' --- etc/NEWS 2014-02-18 01:33:30 +0000 +++ etc/NEWS 2014-02-18 08:09:51 +0000 @@ -28,6 +28,7 @@ This happens by default if a suitable support library is found at build time, like libacl on GNU/Linux. To prevent this, use the configure option `--disable-acl'. +FIXME? Should be --without-acl? ** Emacs can now be compiled with file notification support. This happens by default if a suitable system library is found at @@ -720,11 +721,11 @@ Without the second change, the *scratch* buffer will still be there for notes that do not need to be preserved. -*** The Remember package can now store notes in separates files. -You can use the new function `remember-store-in-files' within the -`remember-handler-functions' option. See `remember-data-directory' -and `remember-directory-file-name-format' for new options related to -this function. ++++ +*** Remember can now store notes in separate files. +To use this, add `remember-store-in-files' to the `remember-handler-functions' +option. The files are saved in `remember-data-directory' using +names specified by `remember-directory-file-name-format'. ** Rmail === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2014-02-18 01:33:30 +0000 +++ lisp/ChangeLog 2014-02-18 08:09:51 +0000 @@ -1,5 +1,11 @@ 2014-02-18 Glenn Morris + * textmodes/remember.el (remember-data-directory) + (remember-directory-file-name-format, remember-store-in-files) + (remember-notes-initial-major-mode, remember-notes-bury-on-kill) + (remember-notes-save-and-bury-buffer) + (remember-notes--kill-buffer-query): Doc fixes. + * desktop.el (desktop-save-mode, desktop-auto-save-timeout): Doc fixes. 2014-02-17 Alan Mackenzie === modified file 'lisp/textmodes/remember.el' --- lisp/textmodes/remember.el 2014-02-14 06:55:59 +0000 +++ lisp/textmodes/remember.el 2014-02-18 08:09:51 +0000 @@ -442,21 +442,24 @@ (remember-destroy)))) (defcustom remember-data-directory "~/remember" - "The directory in which to store remember data as files." + "The directory in which to store remember data as files. +Used by `remember-store-in-files'." :type 'directory :version "24.4" :group 'remember) (defcustom remember-directory-file-name-format "%Y-%m-%d_%T-%z" - "Format string for the file name in which to store unprocessed data." + "Format string for the file name in which to store unprocessed data. +This is passed to `format-time-string'. +Used by `remember-store-in-files'." :type 'string :version "24.4" :group 'remember) (defun remember-store-in-files () "Store remember data in a file in `remember-data-directory'. -The file is named after `remember-directory-file-name-format' fed through -`format-time-string'." +The file is named by calling `format-time-string' using +`remember-directory-file-name-format' as the format string." (let ((name (format-time-string remember-directory-file-name-format (current-time))) (text (buffer-string))) @@ -572,20 +575,19 @@ :version "24.4") (defcustom remember-notes-initial-major-mode nil - "Major mode to set to notes buffer when it's created. -If set to nil will use the same mode as `initial-major-mode'." - :type '(choice (const :tag "Same as `initial-major-mode'" nil) + "Major mode to use in the notes buffer when it's created. +If this is nil, use `initial-major-mode'." + :type '(choice (const :tag "Use `initial-major-mode'" nil) (function :tag "Major mode" text-mode)) :version "24.4") (defcustom remember-notes-bury-on-kill t - "Whether to bury notes buffer instead of killing." + "Non-nil means `kill-buffer' will bury the notes buffer instead of killing." :type 'boolean :version "24.4") (defun remember-notes-save-and-bury-buffer () - "Saves and buries current buffer. -Buffer is saved only if `buffer-modified-p' returns non-nil." + "Save (if it is modified) and bury the current buffer." (interactive) (when (buffer-modified-p) (save-buffer)) @@ -648,10 +650,16 @@ buf)) (defun remember-notes--kill-buffer-query () + "Function that `remember-notes-mode' adds to `kill-buffer-query-functions'. +Save the current buffer if modified. If `remember-notes-bury-on-kill' +is non-nil, bury it and return nil; otherwise return t." (when (buffer-modified-p) (save-buffer)) (if remember-notes-bury-on-kill - (bury-buffer) + (progn + ;; bury-buffer always returns nil, but let's be explicit. + (bury-buffer) + nil) t)) ;;; remember.el ends here