Added make-...-alist for enumerated types.
This commit is contained in:
parent
0c538aea77
commit
4ae0c363d4
|
@ -173,6 +173,15 @@
|
||||||
(input? initial-state icon-pixmap icon-window icon-position icon-mask
|
(input? initial-state icon-pixmap icon-window icon-position icon-mask
|
||||||
window-group urgency))
|
window-group urgency))
|
||||||
|
|
||||||
|
(define-syntax make-wm-hint-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-wm-hint-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (wm-hint attr) arg)
|
||||||
|
(make-wm-hint-alist rest ...)))
|
||||||
|
((make-wm-hint-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define wm-hint-alist->vector
|
(define wm-hint-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
wm-hints wm-hint-index
|
wm-hints wm-hint-index
|
||||||
|
@ -290,6 +299,15 @@
|
||||||
(us-position us-size position size min-size max-size resize-inc aspect
|
(us-position us-size position size min-size max-size resize-inc aspect
|
||||||
base-size win-gravity))
|
base-size win-gravity))
|
||||||
|
|
||||||
|
(define-syntax make-size-hint-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-size-hint-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (size-hint attr) arg)
|
||||||
|
(make-size-hint-alist rest ...)))
|
||||||
|
((make-size-hint-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define size-hint-alist->vector
|
(define size-hint-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
size-hints size-hint-index
|
size-hints size-hint-index
|
||||||
|
|
|
@ -10,6 +10,15 @@
|
||||||
font subwindow-mode graphics-exposures clip-x-origin clip-y-origin
|
font subwindow-mode graphics-exposures clip-x-origin clip-y-origin
|
||||||
clip-mask dash-offset dash-list arc-mode))
|
clip-mask dash-offset dash-list arc-mode))
|
||||||
|
|
||||||
|
(define-syntax make-gc-value-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-gc-value-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (gc-value attr) arg)
|
||||||
|
(make-gc-value-alist rest ...)))
|
||||||
|
((make-gc-value-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define gc-value-alist->vector
|
(define gc-value-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
gc-values gc-value-index
|
gc-values gc-value-index
|
||||||
|
|
|
@ -23,6 +23,15 @@
|
||||||
(visual visual-id screen depth class red-mask green-mask blue-mask
|
(visual visual-id screen depth class red-mask green-mask blue-mask
|
||||||
colormap-size bits-per-rgp))
|
colormap-size bits-per-rgp))
|
||||||
|
|
||||||
|
(define-syntax make-visual-info-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-visual-info-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (visual-info attr) arg)
|
||||||
|
(make-visual-info-alist rest ...)))
|
||||||
|
((make-visual-info-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define visual-info-alist->vector
|
(define visual-info-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
visual-infos visual-info-index
|
visual-infos visual-info-index
|
||||||
|
|
|
@ -68,6 +68,15 @@
|
||||||
override-redirect save-under event-mask do-not-propagate-mask colormap
|
override-redirect save-under event-mask do-not-propagate-mask colormap
|
||||||
cursor))
|
cursor))
|
||||||
|
|
||||||
|
(define-syntax make-set-window-attribute-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-set-window-attribute-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (set-window-attribute attr) arg)
|
||||||
|
(make-set-window-attribute-alist rest ...)))
|
||||||
|
((make-set-window-attribute-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define set-window-attribute-alist->vector
|
(define set-window-attribute-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
set-window-attributes set-window-attribute-index
|
set-window-attributes set-window-attribute-index
|
||||||
|
@ -185,6 +194,15 @@
|
||||||
; 'top-if, 'buttom-if and 'opposite.
|
; 'top-if, 'buttom-if and 'opposite.
|
||||||
(x y width height border-width sibling stack-mode))
|
(x y width height border-width sibling stack-mode))
|
||||||
|
|
||||||
|
(define-syntax make-window-change-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-window-change-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (window-change attr) arg)
|
||||||
|
(make-window-change-alist rest ...)))
|
||||||
|
((make-window-change-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define window-change-alist->vector
|
(define window-change-alist->vector
|
||||||
(make-enum-alist->vector
|
(make-enum-alist->vector
|
||||||
window-changes window-change-index
|
window-changes window-change-index
|
||||||
|
@ -235,6 +253,15 @@
|
||||||
colormap map-installed map-state all-event-masks your-event-mask
|
colormap map-installed map-state all-event-masks your-event-mask
|
||||||
do-not-propagate-mask override-redirect screen))
|
do-not-propagate-mask override-redirect screen))
|
||||||
|
|
||||||
|
(define-syntax make-window-attribute-alist
|
||||||
|
(syntax-rules
|
||||||
|
()
|
||||||
|
((make-window-attribute-alist (attr arg) rest ...)
|
||||||
|
(cons (cons (window-attribute attr) arg)
|
||||||
|
(make-window-attribute-alist rest ...)))
|
||||||
|
((make-window-attribute-alist)
|
||||||
|
'())))
|
||||||
|
|
||||||
(define vector->window-attribute-alist
|
(define vector->window-attribute-alist
|
||||||
(make-vector->enum-alist
|
(make-vector->enum-alist
|
||||||
window-attributes
|
window-attributes
|
||||||
|
|
|
@ -56,7 +56,12 @@
|
||||||
map-window
|
map-window
|
||||||
unmap-window
|
unmap-window
|
||||||
|
|
||||||
((set-window-attribute window-attribute window-change) :syntax)
|
((set-window-attribute
|
||||||
|
window-attribute
|
||||||
|
window-change
|
||||||
|
make-set-window-attribute-alist
|
||||||
|
make-window-attribute-alist
|
||||||
|
make-window-change-alist) :syntax)
|
||||||
window-change-alist->vector ; has to be exported for client.scm
|
window-change-alist->vector ; has to be exported for client.scm
|
||||||
|
|
||||||
set-window-background-pixmap!
|
set-window-background-pixmap!
|
||||||
|
@ -169,7 +174,7 @@
|
||||||
copy-gcontext!
|
copy-gcontext!
|
||||||
free-gcontext
|
free-gcontext
|
||||||
|
|
||||||
((gc-value) :syntax)
|
((gc-value make-gc-value-alist) :syntax)
|
||||||
|
|
||||||
query-best-size
|
query-best-size
|
||||||
query-best-cursor
|
query-best-cursor
|
||||||
|
@ -394,7 +399,10 @@
|
||||||
set-transient-for!
|
set-transient-for!
|
||||||
get-wm-normal-hints
|
get-wm-normal-hints
|
||||||
set-wm-normal-hints!
|
set-wm-normal-hints!
|
||||||
((wm-hint size-hint) :syntax) ;; should be replaced by make-*-hint-alist
|
((wm-hint
|
||||||
|
size-hint
|
||||||
|
make-wm-hint-alist
|
||||||
|
make-size-hint-alist) :syntax)
|
||||||
get-wm-hints
|
get-wm-hints
|
||||||
set-wm-hints!
|
set-wm-hints!
|
||||||
get-icon-sizes
|
get-icon-sizes
|
||||||
|
@ -462,6 +470,7 @@
|
||||||
get-visual-info
|
get-visual-info
|
||||||
visual-id
|
visual-id
|
||||||
match-visual-info
|
match-visual-info
|
||||||
|
(make-visual-info-alist :syntax)
|
||||||
))
|
))
|
||||||
|
|
||||||
(define-interface xlib-region-interface
|
(define-interface xlib-region-interface
|
||||||
|
|
Loading…
Reference in New Issue