bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

reverse video


From: Peter Jay Salzman
Subject: reverse video
Date: Fri, 7 Mar 2003 11:52:57 -0800
User-agent: Mutt/1.4i

hi all,

i'd like to use reverse video -- black text on a white background.  i've
tried to paint the screen white this way:


   void Paint_Screen(void)
   {
      init_pair(COLOR_WHITE, COLOR_WHITE, COLOR_BLACK);
      attron(COLOR_PAIR(COLOR_WHITE));
   
      for (int i=0; i<COLS; ++i)
         for (int j=0; j<LINES; ++j)
            mvprintw(i, j, " ");
      attron(0);
   }


and then printing text with this:


   init_pair(COLOR_BLACK,   COLOR_BLACK,   COLOR_WHITE);
   attron(COLOR_PAIR(COLOR_BLACK));
   mvprintw(0, 0, "testing one two three");


but i still get white text on black screen.  i also tried playing around
with attron(A_REVERSE) but nothing seems to work.

how can i get black text on a white screen?

thanks!
pete

-- 
First they ignore you, then they laugh at you, then they fight you,
then you win. -- Gandhi, being prophetic about Linux.

Fingerprint: B9F1 6CF3 47C4 7CD8 D33E 70A9 A3B9 1945 67EA 951D




reply via email to

[Prev in Thread] Current Thread [Next in Thread]