From 88b0bddfcee56550452ea005b32d60733eacb66d Mon Sep 17 00:00:00 2001 From: hmurata Date: Sun, 4 Jun 2006 02:33:07 +0000 Subject: [PATCH] (wl-message-decrypt-pgp-nonmime): Keep text properties at the decrypting region. --- wl/ChangeLog | 5 +++++ wl/wl-mime.el | 14 ++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/wl/ChangeLog b/wl/ChangeLog index 66c19eb..84207a8 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,8 @@ +2006-06-04 Hiroya Murata + + * wl-mime.el (wl-message-decrypt-pgp-nonmime): Keep text + properties at the decrypting region. + 2006-06-03 Hiroya Murata * wl-util.el (wl-find-region): New function. diff --git a/wl/wl-mime.el b/wl/wl-mime.el index c708559..999dfec 100644 --- a/wl/wl-mime.el +++ b/wl/wl-mime.el @@ -559,12 +559,14 @@ It calls following-method selected from variable (unless region (error "Cannot find pgp encrypted region")) (save-restriction - (narrow-to-region (car region) (cdr region)) - (when (setq coding-system - (wl-mime-pgp-decrypt-region (point-min) (point-max))) - (put-text-property (point-min) (point-max) - 'wl-mime-decoded-coding-system - coding-system)))))) + (let ((props (text-properties-at (car region)))) + (narrow-to-region (car region) (cdr region)) + (when (setq coding-system + (wl-mime-pgp-decrypt-region (point-min) (point-max))) + (setq props (plist-put props + 'wl-mime-decoded-coding-system + coding-system))) + (set-text-properties (point-min) (point-max) props)))))) (defun wl-message-verify-pgp-nonmime (&optional arg) "Verify PGP signed region. -- 1.7.10.4