]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - tack/charset.c
ncurses 5.3
[ncurses.git] / tack / charset.c
index c31b78b5686303ce12884a468ae7904c7ec1b06f..991401f37437479336fa9b93d1a230ddce979516 100644 (file)
@@ -1,5 +1,5 @@
 /*
-** Copyright (C) 1991, 1997 Free Software Foundation, Inc.
+** Copyright (C) 1991, 1997-2000 Free Software Foundation, Inc.
 ** 
 ** This file is part of TACK.
 ** 
@@ -21,7 +21,7 @@
 
 #include <tack.h>
 
-MODULE_ID("$Id: charset.c,v 1.2 1999/05/09 18:30:49 tom Exp $")
+MODULE_ID("$Id: charset.c,v 1.8 2001/06/18 18:44:26 tom Exp $")
 
 /*
        Menu definitions for alternate character set and SGR tests.
@@ -40,7 +40,7 @@ static void charset_smacs(struct test_list *t, int *state, int *ch);
 static void charset_attributes(struct test_list *t, int *state, int *ch);
 static void charset_sgr(struct test_list *t, int *state, int *ch);
 
-const struct test_list acs_test_list[] = {
+struct test_list acs_test_list[] = {
        {0, 0, 0, 0, "e) edit terminfo", 0, &edit_menu},
        {MENU_NEXT, 3, "bel", 0, 0, charset_bel, 0},
        {MENU_NEXT, 3, "flash", 0, 0, charset_flash, 0},
@@ -285,10 +285,12 @@ charset_sgr(
        }
        put_crlf();
 
+#ifdef max_attributes 
        if (max_attributes >= 0) {
                sprintf(temp, "(ma) Maximum attributes %d  ", max_attributes);
                ptext(temp);
        }
+#endif
        generic_done_message(t, state, ch);
 }
 
@@ -369,7 +371,7 @@ charset_attributes(
 /*
 **     charset_smacs(test_list, status, ch)
 **
-**     display all posible acs characters
+**     display all possible acs characters
 **     (smacs) (rmacs)
 */
 static void
@@ -433,12 +435,12 @@ test_acs(
                                        break;
                                }
                                if (glyph[j].name[0] == '\0') {
-                                       if (isgraph(acs_chars[i])) {
+                                       if (isgraph(UChar(acs_chars[i]))) {
                                                sprintf(temp, "    %c",
                                                        acs_chars[i]);
                                        } else {
                                                sprintf(temp, " 0x%02x",
-                                                       (acs_chars[i] & 0xff));
+                                                       UChar(acs_chars[i]));
                                        }
                                        strcpy(&temp[5], " *** has no mapping ***");
                                        putln(temp);