Maybe I'm being thick, but can_change_color is returning false, which is telling you your terminal can't change colors. Basically it sounds like you want to send color sequences to a terminal that doesn't support it. The terminal (which may be a console driver ... same basic thing from a curses point of view) may be using colors as part of its monchrome display which may be confusing you.

Way back when I worked on a curses-like thing the first step was to manually apply the escape sequences to see if the terminals did what we wanted. It could be that you have color capablites but you either have your TERM environment variable set to a monochrome version; or you have a termcap/terminfo entry that isn't specifying the color sequences even though the terminal supports them.

I did get a smile from the "curses looks like a wonderful tool ..." bit. I suppose there are still uses and I loved this kind of work when I did it, but the advent of windows and web browsers pretty much ended my foray into the world of ASCII terminals.


In reply to Re: Color on TrueWhite in Curses - Redux by steves
in thread Color on TrueWhite in Curses - Redux by dvergin

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.