#!/bin/sh ../../scx <property '("scx Hello World Program"))) (spawn (lambda () (let loop ((se (most-recent-sync-x-event))) (display "event: ") (display (sync-x-event-event se)) (display "\n") (loop (next-sync-x-event se (lambda (e) #t)))))) ;;(synchronize dpy #f) (init-sync-x-events dpy) (let ((handler (lambda (channel) (map-window dpy win) (let loop () (if (let ((e (receive channel))) (cond ((expose-event? e) (scx-xft-draw-string-8bit xft-draw xft-black font 10 65 text) (scx-xft-draw-string-8bit xft-draw xft-blue font 10 140 text)) ((motion-event? e) #t) (else #f))) (loop)))))) (call-with-event-channel dpy win (event-mask exposure button-press pointer-motion) handler) (close-display dpy)))) (hello "Hello World!") ,exit EOF