a less-mangled version of the simple_attr demo

cat-town
Dan Buch 15 years ago
parent 92c130fcd5
commit e396c88fd1

@ -39,13 +39,15 @@ int main(int argc, char *argv[])
getyx(stdscr, y, x); /* get the current curser position */ getyx(stdscr, y, x); /* get the current curser position */
move(y, x - 1); /* back up one space */ move(y, x - 1); /* back up one space */
printw("%c%c", '/', ch); /* The actual printing is done here */ printw("%c%c", '/', ch); /* The actual printing is done here */
} } else {
else
printw("%c", ch); printw("%c", ch);
}
refresh(); refresh();
if(prev == '*' && ch == '/')
attroff(A_BOLD); /* Switch it off once we got * if(prev == '*' && ch == '/') {
* and then / */ attroff(A_BOLD); /* Switch it off once we got */
}
/* and then / */
prev = ch; prev = ch;
} }
endwin(); /* End curses mode */ endwin(); /* End curses mode */

Loading…
Cancel
Save