Message343336
A new function called curses.has_extended_color_support() will indicate whether the linked ncurses library provides extended color support. It returns true if curses.h defines NCURSES_EXT_COLORS and NCURSES_EXT_FUNCS, indicating that the extended color functions are available. This seems more useful to developers than using an indirect method like trying to set a color-pair greater than 0x7fff and checking for an exception to indicate lack of support.
At first glance, has_extended_color() seems like a better name because it is similar to has_colors(), but the two functions have very different semantics that could confuse developers. has_extended_color_support() indicates available functionality in the underlying ncurses library that is set when the interpreter is compiled and linked, while has_curses() indicates available functionality of the current terminal at run-time. |
|
Date |
User |
Action |
Args |
2019-05-24 02:17:55 | Jeffrey.Kintscher | set | recipients:
+ Jeffrey.Kintscher |
2019-05-24 02:17:55 | Jeffrey.Kintscher | set | messageid: <1558664275.97.0.0277464788177.issue36982@roundup.psfhosted.org> |
2019-05-24 02:17:55 | Jeffrey.Kintscher | link | issue36982 messages |
2019-05-24 02:17:55 | Jeffrey.Kintscher | create | |
|