[Openmcl-devel] is (pref *display* ...) supposed to work?
Timothy MOORE
Timothy.Moore at labri.fr
Wed Dec 17 10:35:04 PST 2003
On Dec 17, 2003, at 1:10 PM, Gary Byers wrote:
> (ccl::%get-signed-long *display* (/ N 8))
>
>
Actually, it expanded to:
(%GET-SIGNED-LONG (%GET-PTR *DISPLAY* (/ 0 8)) (/ 1056 8))
which is an important clue.
> where N is the bit offset of the "default_screen" field in an
> _XPrivDisplay structure. There are a few dozen fields that
> precede "default_screen" in an _XPrivDisplay, so N could/should
> be in the high hundreds/low thousands and N/8 should be in the
> high dozens/low hundreds somewhere.
>
It turns out that _XPrivDisplay is a "pointer-to-struct" type, which is
obviously confusing things. I ran the X header files through ffigen
again with -DXLIB_ILLEGAL_ACCESS, so "Display" is now a valid structure
type. Things are working better now.
A quick question: the offset to %get-signed-long and friends is in
bytes; how about the array length in (make-record (:array int 42))?
Thanks,
Tim
More information about the Openmcl-devel
mailing list