213 lines
6.1 KiB
Scheme
213 lines
6.1 KiB
Scheme
;; author -> Norbert Freudemann
|
|
;; creation date : 18/06/2001
|
|
;; last change : 04/07/2001
|
|
|
|
|
|
(define (clear-area window x y width height exposures?)
|
|
(%clear-area (window-Xwindow window)
|
|
(display-Xdisplay (window-display window))
|
|
x y width height exposures?))
|
|
|
|
|
|
(import-lambda-definition %clear-area (Xwindow Xdisplay x y width height
|
|
exposures?)
|
|
"Clear_Area")
|
|
|
|
|
|
;; _____
|
|
|
|
(define (copy-area src-drawable gcontext src-x src-y width height dst-drawable
|
|
dst-x dst-y)
|
|
(%copy-area (display-Xdisplay (drawable-display src-drawable))
|
|
(drawable-Xobject src-drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
src-x src-y width height
|
|
(drawable-Xobject dst-drawable)
|
|
dst-x dst-y))
|
|
|
|
(import-lambda-definition %copy-area (Xdisplay srcXdrawable Xgcontext srcx srcy
|
|
width height destXdrawable destx desty)
|
|
"Copy_Area")
|
|
|
|
|
|
;; _____
|
|
|
|
(define (copy-plane src-drawable gcontext plane src-x src-y width height
|
|
dst-drawable dst-x dst-y)
|
|
(%copy-plane (display-Xdisplay (drawable-display src-drawable))
|
|
(drawable-Xobject src-drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
plane
|
|
src-x srx-y width height
|
|
(drawable-Xobject dst-drawable)
|
|
dst-x dst-y))
|
|
|
|
|
|
(import-lambda-definition %copy-plane (Xdisplay srcXdrawable Xgcontext plane
|
|
srcx srcy width height destXdrawable
|
|
destx desty)
|
|
"Copy_Plane")
|
|
|
|
;; _____
|
|
|
|
|
|
(define (draw-point drawable gcontext x y)
|
|
(%draw-point (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x y))
|
|
|
|
(import-lambda-definition %draw-point (Xdisplay Xdrawable Xgcontext x y)
|
|
"Draw-Point")
|
|
|
|
|
|
;; _____
|
|
|
|
(define (draw-points drawable gcontext vector-of-points relative?)
|
|
(%draw-point (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-points
|
|
relative?))
|
|
|
|
(import-lambda-definition %draw-points (Xdisplay Xdrawable Xgcontext vec
|
|
relative)
|
|
"Draw_Points")
|
|
|
|
|
|
;; _____
|
|
|
|
(define (draw-line drawable gcontext x1 y1 x2 y2)
|
|
(%draw-line (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x1 y1 x2 y2))
|
|
|
|
(import-lambda-definition %draw-line (Xdisplay Xdrawable Xgcontext x1 y1 x2 y2)
|
|
"Draw_Line")
|
|
|
|
|
|
;; _____
|
|
|
|
|
|
(define (draw-lines drawable gcontext vector-of-points relative?)
|
|
(%draw-lines (display-Xdisplay (drawable-display drawable))
|
|
(drawalbe-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-points
|
|
relative?))
|
|
|
|
(import-lambda-definition %draw-lines (Xdisplay Xdrawable Xgcontext vec rel)
|
|
"Draw_Lines")
|
|
|
|
;; _____
|
|
|
|
;; Note: vector-of-points is a vector which contains a list with 4
|
|
;; integers in Form: (x1, y1, x2, y2)
|
|
|
|
(define (draw-segments drawalbe gcontext vector-of-points)
|
|
(%draw-segments (display-Xdisplay (drawable-display drawalbe))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-points))
|
|
|
|
(import-lambda-definition %draw-segments (Xdisplay Xdrawable Xgcontext vec)
|
|
"Draw_Segments")
|
|
|
|
|
|
(define (draw-rectangle drawable gcontext x y width height)
|
|
(%draw-rectangle (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x y width height))
|
|
|
|
(import-lambda-definition %draw-rectangle (Xdisplay Xdrawable Xgcontext x y
|
|
w h)
|
|
"Draw_Rectangle")
|
|
|
|
(define (fill-rectangle drawable gcontext x y width height)
|
|
(%fill-rectangle (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x y width height))
|
|
|
|
(import-lambda-definition %fill-rectangle (Xdisplay Xdrawable Xgcontext x y
|
|
w h)
|
|
"Fill_Rectangle")
|
|
|
|
|
|
(define (draw-rectangles drawable gcontext vector-of-rectangles)
|
|
(%draw-rectangles (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-rectangles))
|
|
|
|
(import-lambda-definition %draw-rectangles (Xdisplay Xdrawable Xgcontext
|
|
vec)
|
|
"Draw_Rectangles")
|
|
|
|
|
|
(define (fill-rectangles drawable gcontext vector-of-rectangles)
|
|
(%fill-rectangles (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-rectangles))
|
|
|
|
(import-lambda-definition %fill-rectangles (Xdisplay Xdrawable Xgcontext
|
|
vec)
|
|
"Fill_Rectangles")
|
|
|
|
|
|
(define (draw-arc drawable gcontext x y width height angle1 angle2)
|
|
(%draw-arc (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x y width height angle1 angle2))
|
|
|
|
(import-lambda-definition %draw-arc (Xdisplay Xdrawable Xgcontext x y
|
|
w h a1 a2)
|
|
"Draw_Arc")
|
|
|
|
|
|
(define (fill-arc drawable gcontext x y width height angle1 angle2)
|
|
(%fill-arc (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
x y width height angle1 angle2))
|
|
|
|
(import-lambda-definition %fill-arc (Xdisplay Xdrawable Xgcontext x y
|
|
w h a1 a2)
|
|
"Fill_Arc")
|
|
|
|
(define (draw-arcs drawable gcontext vector-of-data)
|
|
(%draw-arcs (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-data))
|
|
|
|
(import-lambda-definition %draw-arcs (Xdisplay Xdrawable Xgcontext vec)
|
|
"Draw_Arcs")
|
|
|
|
(define (fill-arcs drawable gcontext vector-of-data)
|
|
(%fill-arcs (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-data))
|
|
|
|
(import-lambda-definition %fill-arcs (Xdisplay Xdrawable Xgcontext vec)
|
|
"Fill_Arcs")
|
|
|
|
(define (fill-polygon drawable gcontext vector-of-points relative? shape)
|
|
(%fill-polygon (display-Xdisplay (drawable-display drawable))
|
|
(drawable-Xobject drawable)
|
|
(gcontext-Xgcontext gcontext)
|
|
vector-of-points relative? shape))
|
|
|
|
(import-lambda-definition %fill-polygon (Xdisplay Xdrawable Xgcontext
|
|
vec relative shape)
|
|
"Fill-Polygon")
|
|
|
|
|
|
|
|
|