19 #include <sys/select.h>
22 #include <sys/types.h>
26 #include "window_api.h"
28 #define WIDTH_TO_META(_w) (((_w) & 3) << CHAR_BIT)
30 #define WIDTH_MASK (3 << CHAR_BIT)
31 #define META_MASK (~((1 << CHAR_BIT) - 1))
33 #define BASIC_ATTRS (T3_ATTR_UNDERLINE | T3_ATTR_BOLD | T3_ATTR_REVERSE | T3_ATTR_BLINK | T3_ATTR_DIM | T3_ATTR_ACS)
35 #define INITIAL_ALLOC 80
37 #define _T3_BLOCK_SIZE_TO_WIDTH(x) ((int)((x & 1) + 1))
72 T3_WINDOW_LOCAL
t3_bool _t3_win_refresh_term_line(
int line);
73 T3_WINDOW_LOCAL
int _t3_term_get_default_acs(
int idx);
74 T3_WINDOW_LOCAL
void _t3_remove_window(
t3_window_t *win);
76 T3_WINDOW_LOCAL
extern t3_window_t *_t3_terminal_window;
84 _T3_TERM_CJK_SHIFT_JIS,
99 T3_WINDOW_LOCAL
extern int _t3_term_encoding, _t3_term_combining, _t3_term_double_width;
100 T3_WINDOW_LOCAL
extern char _t3_current_charset[80];
101 T3_WINDOW_LOCAL
extern long _t3_detection_needs_finishing;
102 T3_WINDOW_LOCAL
extern int _t3_terminal_in_fd;
103 T3_WINDOW_LOCAL
extern int _t3_terminal_out_fd;
106 T3_WINDOW_LOCAL
extern char *_t3_cup,
136 T3_WINDOW_LOCAL
extern int _t3_lines, _t3_columns;
137 T3_WINDOW_LOCAL
extern const char *_t3_default_alternate_chars[256];
138 T3_WINDOW_LOCAL
extern t3_attr_t _t3_attrs, _t3_ansi_attrs, _t3_reset_required_mask;
139 T3_WINDOW_LOCAL
extern t3_attr_t _t3_ncv;
140 T3_WINDOW_LOCAL
extern t3_bool _t3_bce;
141 T3_WINDOW_LOCAL
extern int _t3_colors, _t3_pairs;
142 T3_WINDOW_LOCAL
extern char _t3_alternate_chars[256];
143 T3_WINDOW_LOCAL
extern line_data_t _t3_old_data;
144 T3_WINDOW_LOCAL
extern t3_bool _t3_show_cursor;
145 T3_WINDOW_LOCAL
extern int _t3_cursor_y, _t3_cursor_x;
146 T3_WINDOW_LOCAL
extern t3_acs_override_t _t3_acs_override;
148 T3_WINDOW_LOCAL
void _t3_do_cup(
int line,
int col);
149 T3_WINDOW_LOCAL
void _t3_set_alternate_chars_defaults(
void);
150 T3_WINDOW_LOCAL
void _t3_set_attrs(
t3_attr_t new_attrs);
152 T3_WINDOW_LOCAL
extern t3_window_t *_t3_head, *_t3_tail;
156 T3_WINDOW_LOCAL
int _t3_map_attr(
t3_attr_t attr);
157 T3_WINDOW_LOCAL
t3_attr_t _t3_get_attr(
int idx);
158 T3_WINDOW_LOCAL
void _t3_init_attr_map(
void);
159 T3_WINDOW_LOCAL
void _t3_free_attr_map(
void);
161 #define _t3_get_value(s, size) (((s)[0] & 0x80) ? _t3_get_value_int(s, size) : (uint32_t) (*(size) = 1, (s)[0]))
164 T3_WINDOW_LOCAL
int _t3_modifier_hack;
size_t _t3_put_value(uint32_t c, char *dst)
Write a UTF-8 encoded value.
Definition: window_paint.c:243
uint32_t _t3_get_value_int(const char *s, size_t *size)
Get the first UTF-8 value encoded in a string.
Definition: window_paint.c:173
t3_bool _t3_win_is_shown(t3_window_t *win)
Check whether a window is show, both by the direct setting of the shown flag, as well as the parents...
Definition: window.c:263
char t3_bool
A boolean type that does not clash with C++ or C99 bool.
Definition: window_api.h:47
An opaque struct representing a window which can be shown on the terminal.
Definition: internal.h:47
void _t3_do_cup(int line, int col)
Move cursor to screen position.
Definition: terminal.c:207
fd_set _t3_inset
File-descriptor set used for select in t3_term_get_keychar.
Definition: input.c:47
long t3_attr_t
Type to hold attributes used for terminal display.
Definition: terminal.h:63