From 43e87b8a95aa36ab5a7f78de3034e081bac2e8ad Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Mon, 16 Sep 2002 02:48:56 +0000 Subject: hurd/ 2002-09-16 Marcus Brinkmann * console.h (conchar_attr_t): Add bits for italic and bold text attributes. console/ 2002-09-16 Marcus Brinkmann * hurd.ti: Add capabilities , , , . * display.c (handle_esc_bracket_m): Add support for italic. (display_output_one): Add new capabilities PU1 and PU2 to toggle bold mode. Reset PARSE->state on most escape sequences. * console.c (parse_attributes): Rename old bold attribute to bright. Add support for italic and bold. --- console/console.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'console/console.c') diff --git a/console/console.c b/console/console.c index 3896f361..48567e1f 100644 --- a/console/console.c +++ b/console/console.c @@ -1360,9 +1360,9 @@ parse_attributes (const char *name, conchar_attr_t *attr) return EINVAL; attr->intensity = CONS_ATTR_INTENSITY_NORMAL; } - else if (!strncmp (name, "bold", 4)) + else if (!strncmp (name, "bright", 6)) { - name += 4; + name += 6; if (value != 1) return EINVAL; attr->intensity = CONS_ATTR_INTENSITY_BOLD; @@ -1389,6 +1389,16 @@ parse_attributes (const char *name, conchar_attr_t *attr) name += 9; attr->concealed = value; } + else if (!strncmp (name, "italic", 6)) + { + name += 6; + attr->italic = value; + } + else if (!strncmp (name, "bold", 4)) + { + name += 4; + attr->bold = value; + } else return EINVAL; -- cgit v1.2.3