1TICKIT_RENDERBUFFER_HLINE_ATL(i3b)rary Functions ManTuIaClKIT_RENDERBUFFER_HLINE_AT(3)
2
3
4

NAME

6       tickit_renderbuffer_hline_at,   tickit_renderbuffer_vline_at  -  create
7       line regions
8

SYNOPSIS

10       #include <tickit.h>
11
12       void tickit_renderbuffer_hline_at(TickitRenderBuffer *rb,
13               int line, int startcol, int endcol,
14               TickitLineStyle style, TickitLineCaps caps);
15       void tickit_renderbuffer_vline_at(TickitRenderBuffer *rb,
16               int startline, int endline, int col,
17               TickitLineStyle style, TickitLineCaps caps);
18
19       Link with -ltickit.
20

DESCRIPTION

22       tickit_renderbuffer_hline_at() creates a horizontal line segment on the
23       given  line  between  the given columns; both inclusive. tickit_render‐
24       buffer_vline_at() creates a vertical line segment on the  given  column
25       between the given lines; both inclusive.
26
27       The  style argument should be one of the following TickitLineStyle con‐
28       stants:
29
30       TICKIT_LINE_SINGLE
31              A single thin line
32
33       TICKIT_LINE_DOUBLE
34              A pair of double thin lines
35
36       TICKIT_LINE_THICK
37              A single thick line
38
39       Note that as line drawing is performed using the  Unicode  line-drawing
40       characters,  not every possible combination of line segments of differ‐
41       ing styles meeting in a cell is supported  by  Unicode.  The  following
42       sets of styles may be relied upon:
43
44       *      Any  possible  combination  of  only SINGLE segments, THICK seg‐
45              ments, or both.
46
47       *      Any combination of only DOUBLE segments, except cells that  only
48              have one of the four borders occupied.
49
50       *      Any  combination  of SINGLE and DOUBLE segments except where the
51              style changes between SINGLE to DOUBLE on a vertical or horizon‐
52              tal run.
53
54       Other  combinations are not directly supported (i.e. any combination of
55       DOUBLE and THICK in the same cell, or any attempt to change from SINGLE
56       to  DOUBLE  in  either the vertical or horizontal direction). To handle
57       these cases, a cell may be rendered with a substitution character which
58       replaces  a DOUBLE or THICK segment with a SINGLE one within that cell.
59       The effect will be the overall shape of the line is retained, but close
60       to the edge or corner it will have the wrong segment type.
61
62       Conceptually,  every cell involved in line drawing has a potential line
63       segment type at each of its four borders to its neighbours.  Horizontal
64       lines  are  drawn though the vertical centre of each cell, and vertical
65       lines are drawn through the horizontal centre.
66
67       There is a choice of how to handle the ends of  line  segments,  as  to
68       whether  the  segment  should  go to the centre of each cell, or should
69       continue through the entire body of the cell and stop at the  boundary.
70       By default line segments will start and end at the centre of the cells,
71       so that horizontal and vertical lines meeting in a  cell  will  form  a
72       neat corner. When drawing isolated lines such as horizontal or vertical
73       rules, it is preferable that the line go right through the cells at the
74       start  and  end.  To  control this behaviour, the caps bitmask argument
75       should be one of the following TickitLineCaps constants:
76
77       CAP_START
78              indicates that the line should consume the entire start cell
79
80       CAP_END
81              indicates that the line should consume the entire end cell
82
83       CAP_BOTH
84              is a convenient shortcut specifying both behaviours
85

RETURN VALUE

87       This function returns no value.
88

SEE ALSO

90       tickit_renderbuffer_new(3), tickit_renderbuffer_blit(3), tickit_render‐
91       buffer_flush_to_term(3), tickit_renderbuffer(7), tickit(7)
92
93
94
95                                               TICKIT_RENDERBUFFER_HLINE_AT(3)
Impressum