Fix RGB parsing in colors.py

Thanks nand for noticing
This commit is contained in:
mathieui 2018-07-27 02:04:51 +02:00
parent 2fc660db78
commit 6be1a233e4
No known key found for this signature in database
GPG key ID: C59F84CEEFD616E3

View file

@ -19,11 +19,11 @@ def ncurses_color_to_rgb(color):
b = b / 1000 * 5
elif color <= 231:
color = color - 16
r = color % 6
b = color % 6
color = color // 6
g = color % 6
color = color // 6
b = color % 6
r = color % 6
else:
color -= 232
r = g = b = color / 24 * 5