From ac23d5f3fb6fb3d96d8af8ddbc4982cd9649ce5e Mon Sep 17 00:00:00 2001 From: kaoru Date: Sat, 2 Jan 2010 02:11:50 +0000 Subject: [PATCH] * wl-addrmgr.el(wl-addrmgr-mark-write): Use `string-to-char' instead of `? '. Use `point-at-bol' and `point-at-eol'. Remove verbose point move. --- wl/ChangeLog | 4 ++++ wl/wl-addrmgr.el | 15 +++++---------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/wl/ChangeLog b/wl/ChangeLog index 3f56ea2..5c5a161 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,5 +1,9 @@ 2010-01-02 TAKAHASHI Kaoru + * wl-addrmgr.el(wl-addrmgr-mark-write): Use `string-to-char' + instead of `? '. Use `point-at-bol' and `point-at-eol'. Remove + verbose point move. + * wl-address.el (wl-address-add-or-change): Use `point-at-bol' and `point-at-eol'. * wl-addrmgr.el (wl-addrmgr-unmark, wl-addrmgr-address-entry): diff --git a/wl/wl-addrmgr.el b/wl/wl-addrmgr.el index d31bab9..a25f695 100644 --- a/wl/wl-addrmgr.el +++ b/wl/wl-addrmgr.el @@ -559,8 +559,7 @@ Return nil if no ADDRESS exists." (defun wl-addrmgr-mark-write (&optional mark) "Set MARK to the current address entry." (save-excursion - (end-of-line) - (unless (< (count-lines (point-min) (point)) 3) + (unless (< (count-lines (point-min) (point-at-eol)) 3) (let ((buffer-read-only nil) beg end) (beginning-of-line) (delete-char 4) @@ -569,16 +568,12 @@ Return nil if no ADDRESS exists." (cc "Cc: ") (bcc "Bcc:") (t " "))) - (insert (make-string (- 4 (current-column)) ? )) - (beginning-of-line) - (setq beg (point)) - (setq end (progn (end-of-line) - (point))) + (insert (make-string (- 4 (current-column)) (string-to-char " "))) + (setq beg (point-at-bol)) + (setq end (point-at-eol)) (put-text-property beg end 'face nil) (wl-highlight-message beg end nil)) - (set-buffer-modified-p nil) - (beginning-of-line) - (forward-char 4)))) + (set-buffer-modified-p nil)))) (defun wl-addrmgr-apply () (interactive) -- 1.7.10.4