Ignore:
Timestamp:
Oct 29, 2006, 9:35:46 AM (14 years ago)
Author:
Sam Hocevar
Message:
  • Remove cucul_set_color() from the exported API and replaced all calls with cucul_set_attr_ansi(). Old application will still compile (but issue a warning) and run, though.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/test/unicode.c

    r1216 r1256  
    3333    dp = caca_create_display(cv);
    3434
    35     cucul_set_color(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE);
     35    cucul_set_attr_ansi(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE, 0);
    3636    cucul_putstr(cv, 1, 1, "Basic Unicode support");
    3737
    38     cucul_set_color(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK);
     38    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK, 0);
    3939    cucul_putstr(cv, 1, 2, "This is ASCII:    | abc DEF 123 !@# |");
    4040    cucul_putstr(cv, 1, 3, "This is Unicode:  | äßç δεφ ☺♥♀ ╞╬╗ |");
     
    4343    cucul_putstr(cv, 1, 5, "If the three lines do not have the same length, there is a bug somewhere.");
    4444
    45     cucul_set_color(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE);
     45    cucul_set_attr_ansi(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE, 0);
    4646    cucul_putstr(cv, 1, 7, "Gradient glyphs");
    4747
    48     cucul_set_color(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK);
     48    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK, 0);
    4949    cucul_putstr(cv, 31,  8, "  0%");
    5050    cucul_putstr(cv, 31,  9, " 25%");
     
    5353    cucul_putstr(cv, 31, 12, "100%");
    5454
    55     cucul_set_color(cv, CUCUL_COLOR_LIGHTRED, CUCUL_COLOR_LIGHTGREEN);
     55    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTRED, CUCUL_COLOR_LIGHTGREEN, 0);
    5656    cucul_putstr(cv, 1,  8, "                             ");
    5757    cucul_putstr(cv, 1,  9, "░░░░░░░░░░░░░░░░░░░░░░░░░░░░░");
     
    6060    cucul_putstr(cv, 1, 12, "█████████████████████████████");
    6161
    62     cucul_set_color(cv, CUCUL_COLOR_LIGHTGREEN, CUCUL_COLOR_LIGHTRED);
     62    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTGREEN, CUCUL_COLOR_LIGHTRED, 0);
    6363    cucul_putstr(cv, 36,  8, "█████████████████████████████");
    6464    cucul_putstr(cv, 36,  9, "▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓");
     
    6767    cucul_putstr(cv, 36, 12, "                             ");
    6868
    69     cucul_set_color(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE);
     69    cucul_set_attr_ansi(cv, CUCUL_COLOR_WHITE, CUCUL_COLOR_BLUE, 0);
    7070    cucul_putstr(cv, 1, 14, "Double width characters");
    7171
    72     cucul_set_color(cv, CUCUL_COLOR_LIGHTRED, CUCUL_COLOR_BLACK);
     72    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTRED, CUCUL_COLOR_BLACK, 0);
    7373    cucul_putstr(cv, 1, 15, "| ドラゴン ボーレ |");
    74     cucul_set_color(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK);
     74    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK, 0);
    7575    cucul_putstr(cv, 1, 16, "| ()()()() ()()() |");
    76     cucul_set_color(cv, CUCUL_COLOR_YELLOW, CUCUL_COLOR_BLACK);
     76    cucul_set_attr_ansi(cv, CUCUL_COLOR_YELLOW, CUCUL_COLOR_BLACK, 0);
    7777    cucul_putstr(cv, 1, 17, "| ドラゴン");
    7878    cucul_putstr(cv, 12, 17, "ボーレ |");
    7979
    80     cucul_set_color(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK);
     80    cucul_set_attr_ansi(cv, CUCUL_COLOR_LIGHTGRAY, CUCUL_COLOR_BLACK, 0);
    8181    cucul_putstr(cv, 1, 18, "If the three lines do not have the same length, there is a bug somewhere.");
    8282
Note: See TracChangeset for help on using the changeset viewer.