[PATCH 1/2] emacs: notmuch-hello: Avoid going to end-of-line in search box
Pieter Praet
pieter at praet.org
Sat Apr 16 06:07:00 PDT 2011
On Tue, 27 Jul 2010 09:48:44 +0800, Kan-Ru Chen <kanru at kanru.info> wrote:
> widget-end-of-line checks eolp to decide whether C-e in a fixed size
> field should go to the end of the text in the field or the end of
> the field itself. So put a trailing white space to pad the search
> field.
>
> Previous behavior:
>
> Search: [text _]
>
> Now:
>
> Search: [text_ ]
> ---
> emacs/notmuch-hello.el | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/emacs/notmuch-hello.el b/emacs/notmuch-hello.el
> index f8ae332..6ef03bb 100644
> --- a/emacs/notmuch-hello.el
> +++ b/emacs/notmuch-hello.el
> @@ -416,10 +416,10 @@ Complete list of currently available key bindings:
> ;; Leave some space at the start and end of the
> ;; search boxes.
> :size (max 8 (- (window-width) notmuch-hello-indent
> - (length "Search: ")))
> + (length "Search: ") 1 ))
> :action (lambda (widget &rest ignore)
> (notmuch-hello-search (widget-value widget))))
> - (widget-insert "\n")
> + (widget-insert " \n")
>
> (when notmuch-hello-recent-searches
> (widget-insert "\nRecent searches: ")
> --
> 1.7.1
>
>
+1
Can't imagine how this has been collecting dust for so long.
Very useful, very concise, and still applies cleanly to HEAD.
Peace
-Pieter
More information about the notmuch
mailing list