[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Two buglets in diary-list-entries
From: |
Stefan Monnier |
Subject: |
Re: Two buglets in diary-list-entries |
Date: |
Mon, 14 Nov 2005 14:54:21 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
> (i) In my init-file default-major-mode is set to text-mode and as a
> result, since diary-list-entries only checks for fundamental-mode, my
> diary file isn't automatically visited in diary-mode.
I've installed your patch for this, thank you.
> (ii) In the diary display (I use fancy-diary-display) there are
> unwanted blank lines between entries from the same day, which arise
> when the last line of the diary file or of any included files is a
> newline. I usually don't add a newline myself when making a diary
> entry, so these seem to be coming from somewhere else.
Your patch modifies the buffer which is very unclean in a function which is
only supposed to extract data from it. Does the patch below work as well?
Stefan
--- orig/lisp/calendar/diary-lib.el
+++ mod/lisp/calendar/diary-lib.el
@@ -472,7 +472,8 @@
(forward-line 1)
(while (looking-at "[ \t]")
(forward-line 1))
- (unless (eobp) (backward-char 1))
+ (unless (and (eobp) (not (bolp)))
+ (backward-char 1))
(unless list-only
(remove-overlays date-start (point)
'invisible 'diary))