10 unsigned int y,
unsigned int x)
__nonnull;
22 printf (
"\033[0;%dm", ( bold ? 1 : 22 ) );
54 unsigned int y,
unsigned int x ) {
57 printf (
"\033[%d;%dH", ( y + 1 ), ( x + 1 ) );
90 printf (
"\033[?25%c", ( visibility ?
'h' :
'l' ) );
static __always_inline void off_t int c
int printf(const char *fmt,...)
Write a formatted string to the console.
static void ansiscr_exit(struct _curses_screen *scr)
#define CONSOLE_USAGE_TUI
Text-based user interface.
static int ansiscr_getc(struct _curses_screen *scr __unused)
static void ansiscr_cursor(struct _curses_screen *scr __unused, int visibility)
static bool ansiscr_peek(struct _curses_screen *scr __unused)
void ansicol_set_pair(unsigned int cpair)
Set ANSI foreground and background colour.
static void ansiscr_erase(struct _curses_screen *scr, attr_t attrs)
#define __nonnull
Declare a function's pointer parameters as non-null - i.e.
static void ansiscr_movetoyx(struct _curses_screen *scr, unsigned int y, unsigned int x) __nonnull
#define __unused
Declare a variable or data structure as unused.
void(* init)(struct _curses_screen *scr)
uint32_t attrs
Extended attributes (optional)
int getchar(void)
Read a single character from any console.
static void ansiscr_reset(struct _curses_screen *scr) __nonnull
unsigned int curs_x
Current cursor position.
static void ansiscr_init(struct _curses_screen *scr)
FILE_LICENCE(GPL2_OR_LATER_OR_UBDL)
#define CPAIR_DEFAULT
Default colour pair.
attr_t attrs
Current attribute.
static void ansiscr_putc(struct _curses_screen *scr, chtype c) __nonnull
static int console_set_usage(int usage)
Set console usage.
static unsigned int saved_usage
static void ansiscr_attrs(struct _curses_screen *scr, attr_t attrs)
int putchar(int character)
Write a single character to each console device.
#define PAIR_NUMBER(attrs)
int iskey(void)
Check for available input on any console.