%PDF- %PDF-
Direktori : /usr/local/share/emacs/27.2/lisp/obsolete/ |
Current File : //usr/local/share/emacs/27.2/lisp/obsolete/gs.elc |
;ELC ;;; Compiled ;;; in Emacs version 27.2 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. ;;; This file does not contain utf-8 non-ASCII characters, ;;; and so can be loaded in Emacs versions earlier than 23. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; #@42 The name of the Ghostscript interpreter. (defvar gs-program "gs" (#$ . 408)) #@50 The Ghostscript device to use to produce images. (defvar gs-device "x11" (#$ . 491)) #@171 List of command line arguments to pass to Ghostscript. Arguments may contain place-holders `<file>' for the name of the input file, and `<device>' for the device to use. (defvar gs-options '("-q" "-dSAFER" "-dBATCH" "-sDEVICE=<device>" "<file>") (#$ . 583)) (put 'gs-options 'risky-local-variable t) #@198 Return a list of command line options with place-holders replaced. DEVICE is the value to substitute for the place-holder `<device>', FILE is the value to substitute for the place-holder `<file>'. (defalias 'gs-options #[(device file) "\301\302\"\207" [gs-options mapcar #[(option) "\303\304 #\303\305\n #\211\207" [device option file replace-regexp-in-string "<device>" "<file>"] 4]] 3 (#$ . 890)]) #@61 Return, on FRAME, pixel width PIXEL-WIDTH translated to pt. (defalias 'gs-width-in-pt #[(frame pixel-width) "\303!\303\304 !!\303\305 !!\245_\306\n_\307\245)\207" [pixel-width frame mm float x-display-mm-width x-display-pixel-width 25.4 72.0] 5 (#$ . 1300)]) #@63 Return, on FRAME, pixel height PIXEL-HEIGHT translated to pt. (defalias 'gs-height-in-pt #[(frame pixel-height) "\303!\303\304 !!\303\305 !!\245_\306\n_\307\245)\207" [pixel-height frame mm float x-display-mm-height x-display-pixel-height 25.4 72.0] 5 (#$ . 1567)]) #@192 Set the `GHOSTVIEW' window property of FRAME. SPEC is a GS image specification. IMG-WIDTH is the width of the requested image, and IMG-HEIGHT is the height of the requested image in pixels. (defalias 'gs-set-ghostview-window-prop #[(frame spec img-width img-height) "\306A\307\"\211\310\234 \311\234 \312\234 \313\234\306A\314\"\206 \310\f\nZ\315\245 Z\316\245\245\245\317\320\321\322\n\f &#.\n\207" [spec box llx lly urx ury plist-get :bounding-box 0 1 2 3 :rotate 72.0 72.0 x-change-window-property "GHOSTVIEW" format "0 %d %d %d %d %d %g %g" rotation in-width in-height img-width xdpi img-height ydpi frame] 12 (#$ . 1842)]) #@69 Set the `GHOSTVIEW_COLORS' environment variable depending on FRAME. (defalias 'gs-set-ghostview-colors-window-prop #[(frame pixel-colors) "\303!\203\n \304\202 \305!\203 \306\202 \307\310\311\312\313 \n##)\207" [frame mode pixel-colors x-display-color-p "Color" x-display-grayscale-p "Grayscale" "Monochrome" x-change-window-property "GHOSTVIEW_COLORS" format "%s %s"] 6 (#$ . 2514)]) #@243 Load a PS image for display on FRAME. SPEC is an image specification, IMG-HEIGHT and IMG-WIDTH are width and height of the image in pixels. WINDOW-AND-PIXMAP-ID is a string of the form "WINDOW-ID PIXMAP-ID". Value is non-nil if successful. (defalias 'gs-load-image #[(frame spec img-width img-height window-and-pixmap-id pixel-colors) "\306\216\307A\310\"\311\312\313\314\f\"G\315U\204- \315U\204- \316\317\320\"\204' \321\322!\210 S\202\f \323\f $\210\324\f\"\210\325\314\"\210\326\327\330\331\332 \"%\333\n\311\"\210\n,\207" [spec timeout gs file frame img-width #[nil "\300\207" [nil] 1] plist-get :file nil 40 x-window-property "GHOSTVIEW" 0 sit-for 0.1 t sleep-for 0.05 gs-set-ghostview-window-prop gs-set-ghostview-colors-window-prop setenv apply start-process "gs" "*GS*" gs-options set-process-query-on-exit-flag img-height pixel-colors window-and-pixmap-id gs-program gs-device] 8 (#$ . 2913)]) (provide 'gs)