emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/ps-print.el,v [EMACS_22_BASE]


From: Vinicius Jose Latorre
Subject: [Emacs-diffs] Changes to emacs/lisp/ps-print.el,v [EMACS_22_BASE]
Date: Fri, 18 May 2007 02:39:30 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Branch:         EMACS_22_BASE
Changes by:     Vinicius Jose Latorre <viniciusjl>      07/05/18 02:39:29

Index: ps-print.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/ps-print.el,v
retrieving revision 1.181
retrieving revision 1.181.2.1
diff -u -b -r1.181 -r1.181.2.1
--- ps-print.el 5 Mar 2007 23:44:56 -0000       1.181
+++ ps-print.el 18 May 2007 02:39:28 -0000      1.181.2.1
@@ -10,11 +10,11 @@
 ;; Maintainer: Kenichi Handa <address@hidden> (multi-byte characters)
 ;;     Vinicius Jose Latorre <address@hidden>
 ;; Keywords: wp, print, PostScript
-;; Version: 6.7.3
+;; Version: 6.7.4
 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre
 
-(defconst ps-print-version "6.7.3"
-  "ps-print.el, v 6.7.3 <2007/02/06 vinicius>
+(defconst ps-print-version "6.7.4"
+  "ps-print.el, v 6.7.4 <2007/05/13 vinicius>
 
 Vinicius's last change version -- this file may have been edited as part of
 Emacs without changes to the version number.  When reporting bugs, please also
@@ -5817,8 +5817,10 @@
   (ps-get-size (symbol-value font-sym) "font size" font-sym))
 
 
-(defun ps-rgb-color (color default)
-  (cond ((and color (listp color) (= (length color) 3)
+(defun ps-rgb-color (color unspecified default)
+  (cond
+   ;; (float float float) ==> (R G B)
+   ((and color (listp color) (= (length color) 3)
              (let ((cl color)
                    (ok t) e)
                (while (and ok cl)
@@ -5827,11 +5829,15 @@
                        ok (and (floatp e) (<= 0.0 e) (<= e 1.0))))
                ok))
         color)
+   ;; float ==> 0.0 = black .. 1.0 = white
        ((and (floatp color) (<= 0.0 color) (<= color 1.0))
         (list color color color))
-       ((stringp color) (ps-color-scale color))
-       (t (list default default default))
-       ))
+   ;; "colorName" but different from "unspecified-[bf]g"
+   ((and (stringp color) (not (string= color unspecified)))
+    (ps-color-scale color))
+   ;; ok, use the default
+   (t
+    (list default default default))))
 
 
 (defun ps-begin-job (genfunc)
@@ -5913,6 +5919,7 @@
                                 (ps-face-background-name 'default))
                                (t
                                 ps-default-bg))
+                              "unspecified-bg"
                               1.0)
        ps-default-foreground (ps-rgb-color
                               (cond
@@ -5924,6 +5931,7 @@
                                 (ps-face-foreground-name 'default))
                                (t
                                 ps-default-fg))
+                              "unspecified-fg"
                               0.0)
        ps-default-color (and (eq ps-print-color-p t) ps-default-foreground)
        ps-current-color ps-default-color




reply via email to

[Prev in Thread] Current Thread [Next in Thread]