From c49834bb2a4d1f1a206cd54cc4e6ae862fa9195d Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Thu, 8 May 2008 15:02:25 +0200 Subject: [PATCH] 2 Bug fixes, following report and patch from Thomas Morgan. --- lisp/ChangeLog | 7 +++++++ lisp/org-agenda.el | 5 ++++- lisp/org.el | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4eeedecf4..7c353be20 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -9,6 +9,13 @@ without the path into the format, to allow the location format to contain a subdirectory. + * org-agenda.el (org-agenda-post-command-hook): If point is at end + of buffer, and the `org-agenda-type' property undefined, use the + value from the character before. + + * org.el (org-add-planning-info): Don't let indentation for + would-be timestamp become extra whitespace at the end of headline. + 2008-05-07 Carsten Dominik * org.el (org-remove-double-quotes, org-file-contents): New diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index 40cd9a49e..1f5e738d2 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -4334,7 +4334,10 @@ so that the date SD will be in that range." (defun org-agenda-post-command-hook () (and (eolp) (not (bolp)) (backward-char 1)) - (setq org-agenda-type (get-text-property (point) 'org-agenda-type)) + (setq org-agenda-type + (or (get-text-property (point) 'org-agenda-type) + (get-text-property (max (point-min) (1- (point))) + 'org-agenda-type))) (if (and org-agenda-follow-mode (get-text-property (point) 'org-marker)) (org-agenda-show))) diff --git a/lisp/org.el b/lisp/org.el index 5dd545a10..f8ca18780 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -8448,7 +8448,7 @@ be removed." (widen) (if (and (looking-at "[ \t]+\n") (equal (char-before) ?\n)) - (backward-delete-char 1)) + (delete-region (1- (point)) (point-at-eol))) ts))))) (defvar org-log-note-marker (make-marker)) -- 2.11.4.GIT