From fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Wed, 8 Jul 2015 20:46:52 -0400 Subject: Initial commit --- sys/gio/gki/zzdebug.x | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 sys/gio/gki/zzdebug.x (limited to 'sys/gio/gki/zzdebug.x') diff --git a/sys/gio/gki/zzdebug.x b/sys/gio/gki/zzdebug.x new file mode 100644 index 00000000..e56c5cc0 --- /dev/null +++ b/sys/gio/gki/zzdebug.x @@ -0,0 +1,44 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +include +include +include + +task ggcur = t_ggcur + + +# GGCUR -- Debug cursor read in inline graphics kernel. + +procedure t_ggcur() + +pointer gp +char device[SZ_FNAME] + +real cx, cy +int key, xres, yres, hardchar +int dd[LEN_GKIDD] +pointer gopen() + +begin + call clgstr ("device", device, SZ_FNAME) + hardchar = YES + xres = 0 + yres = 0 + + call fseti (STDGRAPH, F_TYPE, SPOOL_FILE) + call fseti (STDGRAPH, F_CANCEL, OK) + + call stg_open (device, dd, STDIN, STDOUT, xres, yres, hardchar) + call gki_inline_kernel (STDGRAPH, dd) + + gp = gopen (device, NEW_FILE, STDGRAPH) + call ggcur (gp, cx, cy, key) + + call gclose (gp) + call stg_close() + + call printf ("cx=%f, cy=%f, key=%d\n") + call pargr (cx) + call pargr (cy) + call pargi (key) +end -- cgit