Curses: Drawing Boxes -- sending control chars

Tony L. Hansen hansen at pegasus.UUCP
Thu Sep 29 02:31:14 AEST 1988


< There is only one problem with this new alternate character stuff: the
< semi-graphics '|' and '-' will be used only if you draw your box with '|'
< and '-' (or NULLS) but the corners will always be done using the
< semi-graphics, even if you try to erase the box using spaces (box(win,
< ' ', ' ')).

It was for this reason that the border() and wborder() functions were added
to the curses library in System V release 3.1. These functions allow you to
specify the characters to be used for all four sides and all four corners.

Here is the function prototype for wborder(). (border() just calls wborder()
with stdscr.)

wborder(WINDOW *win,
	chtype leftside, chtype rightside, chtype topside, chtype bottomside,
	chtype topleft, chtype topright, chtype bottomleft, chtype bottomright)

					Tony Hansen
				att!pegasus!hansen, attmail!tony



More information about the Comp.unix.questions mailing list