1
.\" $Id: cdk_draw.3,v 1.3 2005/12/30 22:45:48 tom Exp $
16
cdk_draw \- Cdk Drawing Functions
20
.RI "[ " "flag" " \|.\|.\|. ] " "file" " \|.\|.\|."
22
.RI "[ " "library" " \|.\|.\|. ]"
28
.BI "WINDOW *" "window",
29
.BI "chtype " "attr");
39
.BI "chtype " "attr");
41
.B "void drawObjBox ("
43
.BI "CDKOBJS *" "object");
46
.BI "WINDOW *" "window",
51
.BI "chtype " "line");
53
.B "void drawShadow ("
54
.BI "WINDOW *" "shadowWin");
56
.B "void writeBlanks ("
57
.BI "WINDOW *" "window",
65
.BI "WINDOW *" "window",
68
.BI "char *" "string",
73
.B "void writeCharAttrib ("
74
.BI "WINDOW *" "window",
77
.BI "char *" "string",
83
.B "void writeChtype ("
84
.BI "WINDOW *" "window",
87
.BI "chtype *" "string",
92
.B "void writeChtypeAttrib ("
93
.BI "WINDOW *" "window",
96
.BI "chtype *" "string",
103
These functions perform useful drawing and attribute operations.
104
.SH AVAILABLE FUNCTIONS
107
draw a box with on the window \fIwin\fP.
109
this function ORs \fIattr\fP with each character as it draws the box.
112
draw a box with on the window \fIwin\fP
113
letting the caller define each element of the box.
115
The parameters \fItlc\fP, \fItrc\fP, \fIblc\fP, \fIbrc\fP
120
bottom-right corners respectively.
124
are used for the horizontal and vertical sides of the box.
125
Any of these parameters may be zero.
126
In that case, the function skips the corresponding element of the box.
128
The function ORs \fIattr\fP with each character as it draws the box.
131
Draw a box around the given window \fIwin\fP
132
using the \fIobject\fP's defined line-drawing characters.
135
draw a line on the given window.
137
The parameters \fIstarty\fP, \fIstartx\fP are the starting coordinates.
138
The parameters \fIendy\fP, \fIendx\fP are the ending coordinates.
139
The function writes the data in \fIline\fP to each coordinate in that
140
range including the start/end coordinates.
142
The function handles lines other than vertical or horizontal,
143
but normally it is used for that, e.g., with \fIline\fP set to
144
\fBACS_HLINE\fP or \fBACS_VLINE\fP.
147
draw a shadow on the right and bottom edges of a window.
150
write a string of blanks, using \fBwriteChar\fP.
151
The parameters are passed to \fBwriteChar\fP as is.
152
There is no corresponding \fBwriteBlanksAttrib\fP function.
155
writes out a \fBchar\ *\fP string without adding attributes.
156
The parameters are passed to \fBwriteCharAttrib\fP as is.
159
writes out a \fBchar\ *\fP string with the given attributes added.
160
The string is written to the given \fIwindow\fP,
161
using its relative screen coordinates \fIypos\fP and \fIxpos\fP.
162
Compare with \fBwriteChtypeAttrib\fP, which writes a \fBchtype\ *\fP string.
164
The function ORs the attribute \fIattr\fP with each item from the string.
165
For instance, it may be \fBA_BOLD\fP.
166
The \fIalign\fP parameter controls whether it is written horizontally
167
(\fBHORIZONTAL\fP) or vertically (\fBVERTICAL\fP).
169
Finally, only a subset of the string is written,
170
i.e., from indices \fIstart\fP to \fIend\fP.
173
writes out a \fBchtype\ *\fP string without adding attributes.
174
The parameters are passed to \fBwriteChtypeAttrib\fP as is.
177
writes out a \fIchtype\ *\fP string with the given attributes added.
178
The string is written to the given \fIwindow\fP,
179
using its relative screen coordinates \fIypos\fP and \fIxpos\fP.
180
You would normally construct the string from a \fIchar\ *\fP string
181
using \fBchar2Chtype\fP (3).
183
The function ORs the attribute \fIattr\fP with each item from the string.
184
For instance, it may be \fBA_BOLD\fP.
185
The \fIalign\fP parameter controls whether it is written horizontally
186
(\fBHORIZONTAL\fP) or vertically (\fBVERTICAL\fP).
188
Finally, only a subset of the string is written,
189
i.e., from indices \fIstart\fP to \fIend\fP.