Changeset 1317 for toilet


Ignore:
Timestamp:
Nov 9, 2006, 10:58:43 PM (13 years ago)
Author:
Sam Hocevar
Message:
  • Updated code to the beta9 API.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • toilet/trunk/src/filter.c

    r1272 r1317  
    144144    static unsigned char const palette[] =
    145145    {
    146         CUCUL_COLOR_LIGHTBLUE,
    147         CUCUL_COLOR_BLUE,
    148         CUCUL_COLOR_LIGHTGRAY,
    149         CUCUL_COLOR_DARKGRAY,
     146        CUCUL_LIGHTBLUE, CUCUL_BLUE, CUCUL_LIGHTGRAY, CUCUL_DARKGRAY,
    150147    };
    151148
     
    165162
    166163        i = ((cx->lines + y + x / 8) / 2) % 4;
    167         cucul_set_color(cx->torender, palette[i], CUCUL_COLOR_TRANSPARENT);
     164        cucul_set_color_ansi(cx->torender, palette[i], CUCUL_TRANSPARENT);
    168165        cucul_putchar(cx->torender, x, y, ch);
    169166    }
     
    174171    static unsigned char const rainbow[] =
    175172    {
    176         CUCUL_COLOR_LIGHTMAGENTA,
    177         CUCUL_COLOR_LIGHTRED,
    178         CUCUL_COLOR_YELLOW,
    179         CUCUL_COLOR_LIGHTGREEN,
    180         CUCUL_COLOR_LIGHTCYAN,
    181         CUCUL_COLOR_LIGHTBLUE,
     173        CUCUL_LIGHTMAGENTA, CUCUL_LIGHTRED, CUCUL_YELLOW,
     174        CUCUL_LIGHTGREEN, CUCUL_LIGHTCYAN, CUCUL_LIGHTBLUE,
    182175    };
    183176    unsigned int x, y, w, h;
     
    192185        if(ch != (unsigned char)' ')
    193186        {
    194             cucul_set_color(cx->torender, rainbow[(x / 2 + y + cx->lines) % 6],
    195                                 CUCUL_COLOR_TRANSPARENT);
     187            cucul_set_color_ansi(cx->torender,
     188                                 rainbow[(x / 2 + y + cx->lines) % 6],
     189                                 CUCUL_TRANSPARENT);
    196190            cucul_putchar(cx->torender, x, y, ch);
    197191        }
Note: See TracChangeset for help on using the changeset viewer.