X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/mLib/blobdiff_plain/43f490c377cb05d1ac6e7d2c27a06ae940e2c047..a077a9a931a4b81abf0f549d7f463ae75075149a:/ui/tty.c diff --git a/ui/tty.c b/ui/tty.c index ff24256..b65f6b7 100644 --- a/ui/tty.c +++ b/ui/tty.c @@ -2565,13 +2565,13 @@ static struct tty *ansi_init(FILE *fp) static const struct kw { const char *name; uint32 val; } kw_colours[] = { - { "no", COLS_NO }, - { "8", COLS_8 }, - { "16", COLS_16 }, - { "88", COLS_88 }, - { "256", COLS_256 }, - { "16m", COLS_16M }, - { 0, 0 } + { "no", COLS_NO }, + { "8", COLS_8 }, + { "16", COLS_16 }, + { "88", COLS_88 }, + { "256", COLS_256 }, + { "16m", COLS_16M }, + { 0, 0 } }; static const struct enummap { @@ -2579,8 +2579,9 @@ static struct tty *ansi_init(FILE *fp) uint32 mask; const struct kw *kw; } enummap[] = { - { "colours", TTACF_CSPCMASK, kw_colours }, - { 0, 0, 0 } + { "colours", TTACF_CSPCMASK | TTACF_FG | TTACF_BG, + kw_colours }, + { 0, 0, 0 } }; @@ -2807,9 +2808,15 @@ struct tty *tty_open(FILE *fp, unsigned f, const unsigned *backends) const char *name; unsigned code; struct tty *(*init)(FILE */*fp*/); } betab[] = { +#ifdef HAVE_UNIBILIUM { "unibilium", TTBK_UNIBI, termunibi_init }, +#endif +#ifdef HAVE_TERMINFO { "terminfo", TTBK_TERMINFO, terminfo_init }, +#endif +#ifdef HAVE_TERMCAP { "termcap", TTBK_TERMCAP, termcap_init }, +#endif { "ansi", TTBK_ANSI, ansi_init }, { 0, 0, 0 } };