aboutsummaryrefslogtreecommitdiff
path: root/sys/gio/imdkern/imdfont.x
diff options
context:
space:
mode:
authorJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
committerJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
commit40e5a5811c6ffce9b0974e93cdd927cbcf60c157 (patch)
tree4464880c571602d54f6ae114729bf62a89518057 /sys/gio/imdkern/imdfont.x
downloadiraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'sys/gio/imdkern/imdfont.x')
-rw-r--r--sys/gio/imdkern/imdfont.x32
1 files changed, 32 insertions, 0 deletions
diff --git a/sys/gio/imdkern/imdfont.x b/sys/gio/imdkern/imdfont.x
new file mode 100644
index 00000000..3117258b
--- /dev/null
+++ b/sys/gio/imdkern/imdfont.x
@@ -0,0 +1,32 @@
+# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.
+
+include <gki.h>
+include <gset.h>
+include "imd.h"
+
+# IMD_FONT -- Set the character font. The roman font is normal. Bold is
+# implemented by increasing the vector line width; care must be taken to
+# set IMD_WIDTH so that the other vector drawing procedures remember to
+# change the width back. The italic font is implemented in the character
+# generator by a geometric transformation.
+
+procedure imd_font (font)
+
+int font # code for font to be set
+int pk2, width
+include "imd.com"
+
+begin
+ width = IMD_WIDTH(g_kt)
+ pk2 = GKI_PACKREAL(2.0)
+
+ if (font == GT_BOLD) {
+ if (width != pk2) {
+ call idk_linewidth (g_out, 2)
+ width = pk2
+ }
+ } else
+ call idk_linewidth (g_out, nint (GKI_UNPACKREAL(width)))
+
+ IMD_WIDTH(g_kt) = width
+end