diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2015-07-08 20:46:52 -0400 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2015-07-08 20:46:52 -0400 |
commit | fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 (patch) | |
tree | bdda434976bc09c864f2e4fa6f16ba1952b1e555 /sys/gio/gks/gqchh.x | |
download | iraf-linux-fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4.tar.gz |
Initial commit
Diffstat (limited to 'sys/gio/gks/gqchh.x')
-rw-r--r-- | sys/gio/gks/gqchh.x | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/sys/gio/gks/gqchh.x b/sys/gio/gks/gqchh.x new file mode 100644 index 00000000..733d0a2a --- /dev/null +++ b/sys/gio/gks/gqchh.x @@ -0,0 +1,39 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +include <gset.h> +include "gks.h" + +# GQCHH - Inquire character height. + +procedure gqchh (ierror, chh) + +int ierror # Error indicator +real chh # Character height, in world coordinates + +real dx, dy +real gstatr() +include "gks.com" +errchk gstatr, ggscale + +begin + if (gk_std == NULL) { + # GKS not in proper state; no active workstations + ierror = 7 + chh = -1.0 + return + } else + ierror = 0 + + iferr { + chh = gstatr (gp[gk_std], G_CHARSIZE) + + # The character height is expressed in NDC units. It must be + # converted to world coordinates before returning. + + call ggscale (gp[gk_std], 0., 0., dx, dy) + chh = chh * dy + } then { + ierror = 1 + chh = -1.0 + } +end |