mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
Remove some compat code from ps files
* lisp/ps-def.el (ps-color-device): Ditto. * lisp/ps-print.el (ps-color-scale): Make into an obsolete alias. (ps-begin-job): Adjust caller. * lisp/progmodes/ebnf2ps.el (ebnf-generate-eps, ebnf-generate): Ditto.
This commit is contained in:
parent
5a6ed46c74
commit
66d8322e03
3 changed files with 7 additions and 17 deletions
|
|
@ -4527,7 +4527,7 @@ end
|
|||
(let* ((ebnf-tree tree)
|
||||
(ps-color-p (and ebnf-color-p (ps-color-device)))
|
||||
(ps-print-color-scale (if ps-color-p
|
||||
(float (car (ps-color-values "white")))
|
||||
(float (car (color-values "white")))
|
||||
1.0))
|
||||
(ebnf-total (length ebnf-tree))
|
||||
(ebnf-nprod 0)
|
||||
|
|
@ -4629,7 +4629,7 @@ end
|
|||
(let* ((ebnf-tree tree)
|
||||
(ps-color-p (and ebnf-color-p (ps-color-device)))
|
||||
(ps-print-color-scale (if ps-color-p
|
||||
(float (car (ps-color-values "white")))
|
||||
(float (car (color-values "white")))
|
||||
1.0))
|
||||
ps-zebra-stripes ps-line-number ps-razzle-dazzle
|
||||
ps-print-hook
|
||||
|
|
|
|||
|
|
@ -58,21 +58,11 @@
|
|||
(define-obsolete-function-alias 'ps-frame-parameter #'frame-parameter "28.1")
|
||||
|
||||
;; Return t if the device (which can be changed during an emacs session) can
|
||||
;; handle colors. This function is not yet implemented for GNU emacs.
|
||||
;; handle colors.
|
||||
(defun ps-color-device ()
|
||||
(if (fboundp 'color-values)
|
||||
(funcall 'color-values "Green")
|
||||
t))
|
||||
(color-values "Green"))
|
||||
|
||||
|
||||
(defun ps-color-values (x-color)
|
||||
(cond
|
||||
((fboundp 'color-values)
|
||||
(funcall 'color-values x-color))
|
||||
((fboundp 'x-color-values)
|
||||
(funcall 'x-color-values x-color))
|
||||
(t
|
||||
(error "No available function to determine X color values"))))
|
||||
(define-obsolete-function-alias 'ps-color-values #'color-values "28.1")
|
||||
|
||||
|
||||
(defun ps-face-bold-p (face)
|
||||
|
|
|
|||
|
|
@ -3856,7 +3856,7 @@ It can be retrieved with `(ps-get ALIST-SYM KEY)'."
|
|||
(defun ps-color-scale (color)
|
||||
;; Scale 16-bit X-COLOR-VALUE to PostScript color value in [0, 1] interval.
|
||||
(mapcar #'(lambda (value) (/ value ps-print-color-scale))
|
||||
(ps-color-values color)))
|
||||
(color-values color)))
|
||||
|
||||
|
||||
(defun ps-face-underlined-p (face)
|
||||
|
|
@ -5752,7 +5752,7 @@ XSTART YSTART are the relative position for the first page in a sheet.")
|
|||
;; evaluated at dump-time because X isn't initialized.
|
||||
ps-color-p (and ps-print-color-p (ps-color-device))
|
||||
ps-print-color-scale (if ps-color-p
|
||||
(float (car (ps-color-values "white")))
|
||||
(float (car (color-values "white")))
|
||||
1.0)
|
||||
ps-default-background (ps-rgb-color
|
||||
(cond
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue