From: ueno Date: Mon, 1 May 2006 03:49:17 +0000 (+0000) Subject: * epg.el (epg-new-signature-to-string): New function. X-Git-Tag: epg-0_0_2~54 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=581abceda181f9e6cb845edbc1005b19eb45715c;p=elisp%2Fepg.git * epg.el (epg-new-signature-to-string): New function. --- diff --git a/ChangeLog b/ChangeLog index 6b618e2..57a8402 100644 --- a/ChangeLog +++ b/ChangeLog @@ -11,6 +11,7 @@ (epg-new-signature-type-alist): New variable. (epg-make-new-signature): New object epg-new-signature. (epg-status-SIG_CREATED): Set epg-new-signature object. + (epg-new-signature-to-string): New function. 2006-04-30 Daiki Ueno diff --git a/epg.el b/epg.el index d2ba8ec..6249909 100644 --- a/epg.el +++ b/epg.el @@ -658,6 +658,24 @@ This function is for internal use only." "Convert VERIFY-RESULT to a human readable string." (mapconcat #'epg-signature-to-string verify-result "\n")) +(defun epg-new-signature-to-string (new-signature) + "Convert NEW-SIGNATURE to a human readable string." + (concat + (cond ((eq (epg-new-signature-type new-signature) 'detached) + "Detached signature ") + ((eq (epg-new-signature-type new-signature) 'clear) + "Clear text signature ") + (t + "Signature ")) + (cdr (assq (epg-new-signature-pubkey-algorithm new-signature) + epg-pubkey-algorithm-alist)) + "/" + (cdr (assq (epg-new-signature-digest-algorithm new-signature) + epg-digest-algorithm-alist)) + " " + (format "%02X " (epg-new-signature-class new-signature)) + (epg-new-signature-fingerprint new-signature))) + (defun epg-start (context args) "Start `epg-gpg-program' in a subprocess with given ARGS." (if (and (epg-context-process context)