Ignore:
Timestamp:
Oct 29, 2006, 1:53:46 AM (13 years ago)
Author:
Sam Hocevar
Message:
  • Use the LSB of alpha and blue components to encode additional flags such as bold or underline. No higher level support for these yet, but at least everything is consistent.
  • Created cucul_set_attr_ansi() and cucul_set_attr_argb() which are bound to replace cucul_set_color() and cucul_set_truecolor().
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/caca/driver_x11.c

    r1233 r1254  
    247247        for(x = 0; x < dp->cv->width; x += len)
    248248        {
    249             uint32_t *attr = dp->cv->attr + x + y * dp->cv->width;
    250             uint16_t bg = _cucul_argb32_to_rgb12bg(*attr);
     249            uint32_t *attrs = dp->cv->attrs + x + y * dp->cv->width;
     250            uint16_t bg = _cucul_attr_to_rgb12bg(*attrs);
    251251
    252252            len = 1;
    253253            while(x + len < dp->cv->width
    254                    && _cucul_argb32_to_rgb12bg(attr[len]) == bg)
     254                   && _cucul_attr_to_rgb12bg(attrs[len]) == bg)
    255255                len++;
    256256
     
    272272        for(x = 0; x < dp->cv->width; x++, chars++)
    273273        {
    274             uint32_t *attr = dp->cv->attr + x + y * dp->cv->width;
     274            uint32_t *attrs = dp->cv->attrs + x + y * dp->cv->width;
    275275
    276276            /* Skip spaces */
     
    282282
    283283            XSetForeground(dp->drv.p->dpy, dp->drv.p->gc,
    284                            dp->drv.p->colors[_cucul_argb32_to_rgb12fg(*attr)]);
     284                           dp->drv.p->colors[_cucul_attr_to_rgb12fg(*attrs)]);
    285285
    286286            /* Plain ASCII, no problem. */
Note: See TracChangeset for help on using the changeset viewer.