0

I'm trying to check a character's attributes(color)(at a given position) using curses.h . Is this possible? I found this but I don't know if it is what I need and how to use that parameters(A_ATTRIBUTES, A_COLOR etc): https://docs.oracle.com/cd/E19455-01/806-0629/6j9vjcnte/index.html Thanks

  • The reference you link to mentions *bit-masks*. Do you know anything about *masking* and the bitwise operators? If not then start by [finding a good beginners book](http://stackoverflow.com/questions/388242/the-definitive-c-book-guide-and-list) and read about it. Then you should hopefully know what to do. – Some programmer dude Jun 01 '17 at 11:41
  • Do you know if it is another way without using bitwise operators? – Andrei Mihai Jun 01 '17 at 11:44
  • 1
    No it's not possible to do bitwise masking without using any bitwise operators. – Some programmer dude Jun 01 '17 at 11:46
  • Ok. Thanks a lot – Andrei Mihai Jun 01 '17 at 11:50
  • Regarding the *call* used, that's pointing to Solaris, which has two (or one-and-a-half) implementations of curses. With X/Open curses, there's also `in_wch` to consider. But see the Oracle documentation, which places some restrictions on how the color can be stored/retrieved. – Thomas Dickey Jun 02 '17 at 21:26

0 Answers0