I am unable to get PDCurses to draw any extended ASCII character in color.
Here is code that compiles fine:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
#include <curses.h>
int main(void){
initscr();
start_color();
init_pair(1, COLOR_RED, COLOR_BLACK);
attrset(COLOR_PAIR(1));
char letter;
letter = 219;
mvaddch(3,3,letter);
mvaddch(3,4,'0');
refresh();
getch();
endwin();}
Basically, I want both the zero and the extended character to show up red.
For some reason, it only works for the zero.
This is a test program.
My full program works great in curses, but I would really like the added
benefit of color.
EDIT:
Thanks for the help everybody.
It turns out the "char letter" needs to be "int letter".
You guys were a big help.