aboutsummaryrefslogtreecommitdiff
path: root/sys/gio/gki/gkiplset.x
blob: 1a7b092fbc2ebf673b36dc56622ce5459ea4167b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.

include	<config.h>
include	<gki.h>
include	<gio.h>

# GKI_PLSET -- Set the polyline attributes.
#
# BOI GKI_PLSET L LT LW CI
#
#        L(i)            6
#        LT(i)           linetype number
#        LW(r)           linewidth scale factor
#        CI(i)           polyline color index

procedure gki_plset (fd, ap)

int	fd			# output file
pointer	ap			# pointer to polyline attribute structure

int	epa
short	gki[GKI_PLSET_LEN]
data	gki[1] /BOI/, gki[2] /GKI_PLSET/, gki[3] /GKI_PLSET_LEN/
include	"gki.com"

begin
	gki[GKI_PLSET_LT] = PL_LTYPE(ap)
	gki[GKI_PLSET_LW] = GKI_PACKREAL (PL_WIDTH(ap))
	gki[GKI_PLSET_CI] = PL_COLOR(ap)

	if (IS_INLINE(fd)) {
	    epa = gk_dd[GKI_PLSET]
	    if (epa != 0)
		call zcall1 (epa, gki)
	} else
	    call write (gk_fd[fd], gki, GKI_PLSET_LEN * SZ_SHORT)
end