Open kovkev opened 3 years ago
Color is encoded in Char_s inside of Screen and are not returned by Screen.display
Nope, Screen.display
returns a plain styleless text. To get the details of each characters, including their colors you have to query each character:
for y in range(screen.lines):
line = screen.buffer[y]
for x in range(screen.columns):
char = line[x]
print(char.fg, char.bg) # foreground/background colors
When I
print(str.encode(screen.display[0]))
, it seems like color is not encoded.