* Refresh Summary buffer after modifying summary-line-format
@ 2014-09-21 1:53 Brady Trainor
0 siblings, 0 replies; only message in thread
From: Brady Trainor @ 2014-09-21 1:53 UTC (permalink / raw)
To: info-gnus-english
Hi, I'm trying to make Gnus a little more reactive to my impulses.
I like the defaults, and I try to add on a little customization as I go.
So far, I've managed to start making keybindings that will modify the
window configurations, like
(define-key gnus-summary-mode-map (kbd "v 2") 'my-gnus-layout-2-pane)
The function includes a gnus-add-configuration, and a refresh via
(gnus-summary-expand-window) (like `=' binding).
But now, when I try to do the same for the summary-line-format, I cannot
see a good way to refresh the buffer. If I change the variable, then by
hand I can type `q' and then select the group again, and the summary
line will have the new formatting. But when I type `q', the cursor jumps
to a group with unread mail, though I was looking at my INBOX which
shows read mail, and ticked mail.
Here are my functions:
(defun my-gnus-summary-line-time ()
(interactive)
(setq-default gnus-summary-line-format
"%&user-date; %U%R%z%I%(%[%4L: %-23,23f%]%) %s\n"
gnus-user-date-format-alist '((t . "%d-%b-%y %H:%M"))
)
(gnus-summary-expand-window)
)
(defun my-gnus-summary-line-date ()
(interactive)
(setq-default gnus-summary-line-format
"%d %U%R%z%I%(%[%4L: %-23,23f%]%) %s\n"
)
(gnus-summary-expand-window)
)
(defun my-gnus-summary-line-default ()
(interactive)
(setq-default gnus-summary-line-format
"%U%R%z%I%(%[%4L: %-23,23f%]%) %s\n"
)
(gnus-summary-expand-window)
)
And here are the shortcuts
(define-key gnus-summary-mode-map (kbd "v d") 'my-gnus-summary-line-default)
(define-key gnus-summary-mode-map (kbd "v D") 'my-gnus-summary-line-date)
(define-key gnus-summary-mode-map (kbd "v t") 'my-gnus-summary-line-time)
Thank you,
Brady
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-09-21 1:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-21 1:53 Refresh Summary buffer after modifying summary-line-format Brady Trainor
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).