comparison lisp/x-mouse.el @ 446:1ccc32a20af4 r21-2-38

Import from CVS: tag r21-2-38
author cvs
date Mon, 13 Aug 2007 11:37:21 +0200
parents 576fb035e263
children 7039e6323819
comparison
equal deleted inserted replaced
445:34f3776fcf0e 446:1ccc32a20af4
99 "Initialize the mouse-pointers of DEVICE from the X resource database." 99 "Initialize the mouse-pointers of DEVICE from the X resource database."
100 (if x-pointers-initialized ; only do it when the first device is created 100 (if x-pointers-initialized ; only do it when the first device is created
101 nil 101 nil
102 (set-glyph-image text-pointer-glyph 102 (set-glyph-image text-pointer-glyph
103 (or (x-get-resource "textPointer" "Cursor" 'string device nil 'warn) 103 (or (x-get-resource "textPointer" "Cursor" 'string device nil 'warn)
104 "xterm")) 104 [cursor-font :data "xterm"]))
105 (set-glyph-image selection-pointer-glyph 105 (set-glyph-image selection-pointer-glyph
106 (or (x-get-resource "selectionPointer" "Cursor" 'string device 106 (or (x-get-resource "selectionPointer" "Cursor" 'string device
107 nil 'warn) 107 nil 'warn)
108 "top_left_arrow")) 108 [cursor-font :data "top_left_arrow"]))
109 (set-glyph-image nontext-pointer-glyph 109 (set-glyph-image nontext-pointer-glyph
110 (or (x-get-resource "spacePointer" "Cursor" 'string device nil 'warn) 110 (or (x-get-resource "spacePointer" "Cursor" 'string device nil 'warn)
111 "xterm")) ; was "crosshair" 111 [cursor-font :data "xterm"])) ; was "crosshair"
112 (set-glyph-image modeline-pointer-glyph 112 (set-glyph-image modeline-pointer-glyph
113 (or (x-get-resource "modeLinePointer" "Cursor" 'string device 113 (or (x-get-resource "modeLinePointer" "Cursor" 'string device
114 nil 'warn) 114 nil 'warn)
115 ;; "fleur")) 115 ;; "fleur"))
116 "sb_v_double_arrow")) 116 [cursor-font :data "sb_v_double_arrow"]))
117 (set-glyph-image gc-pointer-glyph 117 (set-glyph-image gc-pointer-glyph
118 (or (x-get-resource "gcPointer" "Cursor" 'string device nil 'warn) 118 (or (x-get-resource "gcPointer" "Cursor" 'string device nil 'warn)
119 "watch")) 119 [cursor-font :data "watch"]))
120 (when (featurep 'scrollbar) 120 (when (featurep 'scrollbar)
121 (set-glyph-image 121 (set-glyph-image
122 scrollbar-pointer-glyph 122 scrollbar-pointer-glyph
123 (or (x-get-resource "scrollbarPointer" "Cursor" 'string device 123 (or (x-get-resource "scrollbarPointer" "Cursor" 'string device
124 nil 'warn) 124 nil 'warn)
125 "top_left_arrow"))) 125 ;; bizarrely if we don't specify the specific locale (x) this
126 ;; gets instantiated on the stream device. Bad puppy.
127 [cursor-font :data "top_left_arrow"]) 'global '(default x)))
126 (set-glyph-image busy-pointer-glyph 128 (set-glyph-image busy-pointer-glyph
127 (or (x-get-resource "busyPointer" "Cursor" 'string device nil 'warn) 129 (or (x-get-resource "busyPointer" "Cursor" 'string device nil 'warn)
128 "watch")) 130 [cursor-font :data "watch"]))
129 (set-glyph-image toolbar-pointer-glyph 131 (set-glyph-image toolbar-pointer-glyph
130 (or (x-get-resource "toolBarPointer" "Cursor" 'string device 132 (or (x-get-resource "toolBarPointer" "Cursor" 'string device
131 nil 'warn) 133 nil 'warn)
132 "left_ptr")) 134 [cursor-font :data "left_ptr"]))
133 (set-glyph-image divider-pointer-glyph 135 (set-glyph-image divider-pointer-glyph
134 (or (x-get-resource "dividerPointer" "Cursor" 'string device 136 (or (x-get-resource "dividerPointer" "Cursor" 'string device
135 nil 'warn) 137 nil 'warn)
136 "sb_h_double_arrow")) 138 [cursor-font :data "sb_h_double_arrow"]))
137 (let ((fg 139 (let ((fg
138 (x-get-resource "pointerColor" "Foreground" 'string device 140 (x-get-resource "pointerColor" "Foreground" 'string device
139 nil 'warn))) 141 nil 'warn)))
140 (and fg 142 (and fg
141 (set-face-foreground 'pointer fg))) 143 (set-face-foreground 'pointer fg)))