aboutsummaryrefslogtreecommitdiff
path: root/termbox2/attrw.ha
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--termbox2/attrw.ha39
1 files changed, 39 insertions, 0 deletions
diff --git a/termbox2/attrw.ha b/termbox2/attrw.ha
new file mode 100644
index 0000000..d337b8f
--- /dev/null
+++ b/termbox2/attrw.ha
@@ -0,0 +1,39 @@
1// Integer width of fg and bg attributes. Valid values (assuming system
2// support) are 16, 32, and 64; see [[termbox2::uattr]]. 32 or 64 enables
3// OUTPUT.TRUECOLOR, see [[termbox2::OUTPUT]] and
4// [[termbox2::set_output_mode]]. 64 enables additional style attributes.
5// Larger values consume more memory in exchange for more features.
6// Defaults to 64.
7export def OPT_ATTR_W: size = 64;
8
9// Unsigned integer type for cell attributes, see [[termbox2::ATTRIBUTE]].
10export type uattr = u64;
11
12// Colors (bitwise), see [[termbox2::cell]].
13export def COLOR = struct {
14 DEFAULT: uattr = 0x0000,
15 BLACK: uattr = 0x0001,
16 RED: uattr = 0x0002,
17 GREEN: uattr = 0x0003,
18 YELLOW: uattr = 0x0004,
19 BLUE: uattr = 0x0005,
20 MAGENTA: uattr = 0x0006,
21 CYAN: uattr = 0x0007,
22 WHITE: uattr = 0x0008,
23};
24
25// Style attributes (bitwise), see [[termbox2::cell]].
26export def ATTRIBUTE = struct {
27 BOLD: uattr = 0x01000000,
28 UNDERLINE: uattr = 0x02000000,
29 REVERSE: uattr = 0x04000000,
30 ITALIC: uattr = 0x08000000,
31 BLINK: uattr = 0x10000000,
32 HI_BLACK: uattr = 0x20000000,
33 BRIGHT: uattr = 0x40000000,
34 DIM: uattr = 0x80000000,
35 STRIKEOUT: uattr = 0x0000000100000000,
36 UNDERLINE_2: uattr = 0x0000000200000000,
37 OVERLINE: uattr = 0x0000000400000000,
38 INVISIBLE: uattr = 0x0000000800000000,
39};

Generated with cgit - Back to sebastiano.tronto.net