X-Git-Url: http://cgit.sxemacs.org/?a=blobdiff_plain;ds=sidebyside;f=lisp%2Fgnus-spec.el;h=31e440e22ddbe30ac579ab23583955a51d035d4c;hb=8aa9955727d97ee14fb138a3d2f0f214899f4096;hp=40a63f8567fb084a184f6d7b6c0412b78437dd03;hpb=ba1ea92b7514357cc76b475d2ae42eadc91bc7b1;p=gnus diff --git a/lisp/gnus-spec.el b/lisp/gnus-spec.el index 40a63f856..31e440e22 100644 --- a/lisp/gnus-spec.el +++ b/lisp/gnus-spec.el @@ -1,7 +1,7 @@ ;;; gnus-spec.el --- format spec functions for Gnus ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -25,7 +25,7 @@ ;;; Code: -;; For Emacs < 22.2. +;; For Emacs <22.2 and XEmacs. (eval-and-compile (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) (eval-when-compile (require 'cl)) @@ -41,7 +41,7 @@ (defcustom gnus-make-format-preserve-properties (featurep 'xemacs) "*If non-nil, use a replacement `format' function which preserves -text properties. This is only needed on XEmacs, as FSF Emacs does this anyway." +text properties. This is only needed on XEmacs, as Emacs does this anyway." :version "22.1" :group 'gnus-format :type 'boolean) @@ -680,7 +680,7 @@ are supported for %s." ((string= fstring "%d") (setq dontinsert t) (if insert - (list `(princ ,(car flist))) + `(insert (int-to-string ,(car flist))) (list `(int-to-string ,(car flist))))) ;; Just lots of chars and strings. ((string-match "\\`\\(%[cs]\\)+\\'" fstring) @@ -709,15 +709,7 @@ are supported for %s." (when result (if dontinsert result - `(progn - (insert ,@result) - (if (bolp) - ;; remove trailing whitespaces from the line - (progn - (end-of-line 0) - (skip-chars-backward " ") - (delete-region (point) (point-at-eol)) - (forward-line 1)))))) + (cons 'insert result))) (cond ((stringp result) result) ((consp result) @@ -775,5 +767,4 @@ If PROPS, insert the result." ;; coding: iso-8859-1 ;; End: -;; arch-tag: a4328fa1-1f84-4b09-97ad-4b5767cfd50f ;;; gnus-spec.el ends here