DOKK / manpages / debian 11 / libcdk5-dev / cdk_draw.3.en
cdk_draw(3) Library Functions Manual cdk_draw(3)

cdk_draw - Cdk Drawing Functions

cc [ flag ... ] file ... -lcdk [ library ... ]

#include <cdk.h>

WINDOW *window,
chtype attr);
WINDOW *win,
chtype tlc,
chtype trc,
chtype blc,
chtype brc,
chtype horz,
chtype vert,
chtype attr);
WINDOW *win,
CDKOBJS *object);
WINDOW *window,
int startx,
int starty,
int endx,
int endy,
chtype line);
WINDOW *shadowWin);
WINDOW *window,
int xpos,
int ypos,
int align,
int start,
int end);
WINDOW *window,
int xpos,
int ypos,
char *string,
int align,
int start,
int end);
WINDOW *window,
int xpos,
int ypos,
char *string,
chtype attr,
int align,
int start,
int end);
WINDOW *window,
int xpos,
int ypos,
chtype *string,
int align,
int start,
int end);
WINDOW *window,
int xpos,
int ypos,
chtype *string,
chtype attr,
int align,
int start,
int end);

These functions perform useful drawing and attribute operations.

draw a box with on the window win. Like attrbox, this function ORs attr with each character as it draws the box.
draw a box with on the window win letting the caller define each element of the box.
The parameters tlc, trc, blc, brc are used for the top-left, top-right, bottom-left and bottom-right corners respectively. The parameters horz and vert are used for the horizontal and vertical sides of the box. Any of these parameters may be zero. In that case, the function skips the corresponding element of the box.
The function ORs attr with each character as it draws the box.
Draw a box around the given window win using the object's defined line-drawing characters.
draw a line on the given window.
The parameters starty, startx are the starting coordinates. The parameters endy, endx are the ending coordinates. The function writes the data in line to each coordinate in that range including the start/end coordinates.
The function handles lines other than vertical or horizontal, but normally it is used for that, e.g., with line set to ACS_HLINE or ACS_VLINE.
draw a shadow on the right and bottom edges of a window.
write a string of blanks, using writeChar. The parameters are passed to writeChar as is. There is no corresponding writeBlanksAttrib function.
writes out a char * string without adding attributes. The parameters are passed to writeCharAttrib as is.
writes out a char * string with the given attributes added. The string is written to the given window, using its relative screen coordinates ypos and xpos.
Compare with writeChtypeAttrib, which writes a chtype * string.
The function ORs the attribute attr with each item from the string. For instance, it may be A_BOLD. The align parameter controls whether it is written horizontally (HORIZONTAL) or vertically (VERTICAL).
Finally, only a subset of the string is written. The function starts with the data from the start item of string, and ends before the end item. If start is greater than, or equal to end, no data is written.
writes out a chtype * string without adding attributes. The parameters are passed to writeChtypeAttrib as is.
writes out a chtype * string with the given attributes added. The string is written to the given window, using its relative screen coordinates ypos and xpos. You would normally construct the string from a char * string using char2Chtype (3).
The function ORs the attribute attr with each item from the string. For instance, it may be A_BOLD. The align parameter controls whether it is written horizontally (HORIZONTAL) or vertically (VERTICAL).
Finally, only a subset of the string is written. The function starts with the data from the start item of string, and ends before the end item. If start is greater than, or equal to end, no data is written.

cdk(3), cdk_util(3)