[issue37738] curses.addch('a', curses.color_pair(1)) ignores the color information
STINNER Victor
report at bugs.python.org
Thu Aug 1 11:13:21 EDT 2019
STINNER Victor <vstinner at redhat.com> added the comment:
stdscr.addch(str, color_pair) is implemented with:
setcchar(&wcval, wstr, attr, 0, NULL);
rtn = wadd_wch(self->win, &wcval);
whereas stdscr.addch(bytes, color_pair) is implemented with:
rtn = waddch(self->win, cch | (attr_t) attr);
The 4th argument of setcchar() is "short color_pair": Python always pass 0. It seems to be your bug.
Attached PR 15071 fix this bug.
Note: Python 3.5 and 3.6 don't accept bugfixes anymore, only security fixes.
----------
nosy: +vstinner
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue37738>
_______________________________________
More information about the Python-bugs-list
mailing list