Ignore:
Timestamp:
May 20, 2006, 7:45:57 AM (14 years ago)
Author:
Sam Hocevar
Message:
  • Make the ncurses driver UTF-8 and UTF-32 aware.
  • Add the backspace key to the ncurses driver.
File:
1 edited

Legend:

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

    r969 r971  
    239239    }
    240240
    241     if(intkey < 0x100)
     241    if(intkey < 0x80)
    242242    {
    243243        ev->type = CACA_EVENT_KEY_PRESS;
    244244        ev->data.key.ch = intkey;
     245        ev->data.key.utf32 = intkey;
     246        ev->data.key.utf8[0] = intkey;
     247        ev->data.key.utf8[1] = '\0';
    245248        return 1;
    246249    }
     
    407410        case KEY_IC: ev->data.key.ch = CACA_KEY_INSERT; break;
    408411        case KEY_DC: ev->data.key.ch = CACA_KEY_DELETE; break;
     412        case KEY_BACKSPACE: ev->data.key.ch = CACA_KEY_BACKSPACE; break;
    409413        case KEY_HOME: ev->data.key.ch = CACA_KEY_HOME; break;
    410414        case KEY_END: ev->data.key.ch = CACA_KEY_END; break;
Note: See TracChangeset for help on using the changeset viewer.