scx/scheme/xlib/xlib-interfaces.scm

357 lines
6.8 KiB
Scheme
Raw Normal View History

2001-06-11 11:28:32 -04:00
;;; A "header" package with all new datatypes
(define-interface xlib-types-interface
(export make-display
display?
display-Xdisplay
display-after-function
display-set-after-function!
close-display
make-window
destroy-window
window?
drawable?
window-tag
window-set-tag!
window-Xwindow
window-display
2001-06-25 07:46:06 -04:00
drawable-abstraction
drawable-display
drawable-Xobject
2001-06-11 11:28:32 -04:00
make-color
color?
color-Xcolor
color-tag
color-set-tag!
make-colormap
colormap?
free-colormap
colormap-display
colormap-Xcolormap
colormap-tag
make-pixel
pixel?
pixel-Xpixel
pixel-tag
2001-06-25 07:46:06 -04:00
make-gcontext
gcontext?
gcontext-display
free-gcontext
gcontext-Xgcontext
gcontext-tag
2001-06-11 11:28:32 -04:00
))
(define-structure xlib-types xlib-types-interface
(open scsh
scheme
weak
general-tables
primitives
define-record-types
external-calls)
(files type/display-type
type/window-type
type/color-type
type/colormap-type
2001-06-25 07:46:06 -04:00
type/pixel-type
type/gcontext-type))
2001-06-11 11:28:32 -04:00
;;; Basic package
(define-interface xlib-basic-interface
(export named-args->alist))
(define-structure xlib-basic xlib-basic-interface
(open scsh
scheme
external-calls)
(files stuff))
;;; The display structure
(define-interface xlib-display-interface
(export display?
open-display
close-display
display-after-function
after-function ;; compatibility with Elk, same as above
display-set-after-function!
set-after-function! ;; compatibility with Elk, same as above
display-default-root-window
display-root-window ;; same as above
display-default-colormap
display-colormap ;; same as above
display-default-gcontext
display-default-depth
display-default-screen-number
display-cells
display-planes
display-string
display-vendor
display-protocol-version
display-screen-count
display-image-byte-order
display-bitmap-unit
display-bitmap-bit-order
display-bitmap-pad
display-width
display-height
display-width-mm
display-height-mm
display-motion-buffer-size
display-flush-output
display-wait-output
display-no-op
no-op ;; compatibility with Elk, same as above
display-list-depths
list-depths ;; compatibility with Elk, same as above
display-list-pixmap-formats
list-pixmap-formats ;; compatibility with Elk, same as above
synchronize
))
(define-structure xlib-display xlib-display-interface
(open scsh
scheme
2001-06-11 11:28:32 -04:00
external-calls
xlib-types
xlib-basic)
(files display))
(define-interface xlib-window-interface
(export window?
drawable?
window-display
create-window
destroy-window
change-window-attributes
get-window-attributes
map-window
unmap-window
2001-06-11 11:28:32 -04:00
set-window-background-pixmap!
set-window-background-pixel!
set-window-border-pixmap!
set-window-border-pixel!
set-window-bit-gravity!
set-window-gravity!
set-window-backing-store!
set-window-backing-planes!
set-window-backing-pixel!
set-window-save-under!
set-window-event-mask!
set-window-do-not-propagate-mask!
set-window-override-redirect!
set-window-colormap!
set-window-cursor!
set-window-x!
set-window-y!
set-window-width!
set-window-height!
set-window-border-width!
set-window-sibling!
set-window-stack-mode!
window-x
window-y
window-width
window-height
window-border-width
window-depth
window-visual
window-root
window-class
window-bit-gravity
window-backing-store
window-backing-planes
window-backing-pixel
window-save-under
window-colormap
window-map-installed
window-map-state
window-all-event-masks
window-your-event-mask
window-do-not-propagate-mask
window-override-redirect
destroy-subwindows
map-subwindows
unmap-subwindows
circulate-subwindows
clear-window
raise-window
lower-window
restack-windows
query-tree
translate-coordinates
query-pointer
))
(define-structure xlib-window xlib-window-interface
(open scsh
scheme
external-calls
2001-06-25 07:46:06 -04:00
receiving
2001-06-11 11:28:32 -04:00
xlib-types
xlib-basic
2001-06-25 07:46:06 -04:00
xlib-graphics ;; for clear-window
2001-06-11 11:28:32 -04:00
)
(files window))
2001-06-25 07:46:06 -04:00
;;; the display-interface
(define-interface xlib-drawable-interface
(export drawable?
drawable-root
drawable-x
drawable-y
drawable-width
drawable-height
drawable-border-width
drawable-depth))
(define-structure xlib-drawable xlib-drawable-interface
(open scsh
scheme
xlib-types)
(files drawable))
2001-06-11 11:28:32 -04:00
;;; the color-interface
(define-interface xlib-color-interface
(export make-color
color?
color-rgb-values
color-tag ;;??
color-set-tag!;;??
query-color
query-colors
lookup-color))
(define-structure xlib-color xlib-color-interface
(open scsh
scheme
external-calls
xlib-types
xlib-basic)
(files color))
;;; the colormap-interface
(define-interface xlib-colormap-interface
(export make-colormap
colormap?
free-colormap
colormap-display
alloc-color
alloc-named-color
))
(define-structure xlib-colormap xlib-colormap-interface
(open scsh
scheme
external-calls
xlib-types
xlib-basic)
(files colormap))
;;; the pixel-interface
(define-interface xlib-pixel-interface
(open scsh
scheme
external-calls
xlib-types
xlib-basic)
(files pixel))
(define-structure xlib-pixel xlib-pixel-interface
(export pixel?
pixel-value
black-pixel
white-pixel
))
2001-06-25 07:46:06 -04:00
;;; the gcontext-interface
(define-interface xlib-gcontext-interface
(open scsh
scheme
external-calls
receiving
xlib-types
xlib-basic)
(files gcontext))
(define-structure xlib-gcontext xlib-gcontext-interface
(export gcontext?
gcontext-display
create-gcontext
copy-gcontext
free-gcontext
query-best-size
query-best-cursor
query-best-title
query-best-stipple
gcontext-function
gcontext-plane-mask
gcontext-foreground
gcontext-background
gcontext-line-width
gcontext-line-style
gcontext-cap-style
gcontext-join-style
gcontext-fill-style
gcontext-fill-rule
gcontext-arc-mode
gcontext-tile
gcontext-stipple
gcontext-ts-x
gcontext-ts-y
gcontext-font
gcontext-subwindow-mode
gcontext-exposures
gcontext-clip-x
gcontext-clip-y
gcontext-clip-mask
gcontext-dash-offset
gcontext-dashes
set-gcontext-function!
set-gcontext-plane-mask!
set-gcontext-foreground!
set-gcontext-background!
set-gcontext-line-width!
set-gcontext-line-style!
set-gcontext-cap-style!
set-gcontext-join-style!
set-gcontext-fill-style!
set-gcontext-fill-rule!
set-gcontext-arc-mode!
set-gcontext-tile!
set-gcontext-stipple!
set-gcontext-ts-x!
set-gcontext-ts-y!
set-gcontext-font!
set-gcontext-subwindow-mode!
set-gcontext-exposures!
set-gcontext-clip-x!
set-gcontext-clip-y!
set-gcontext-clip-mask!
set-gcontext-dash-offset!
set-gcontext-clip-rectangles!
set-gcontext-dashlist!
))