Better colour codes
This commit is contained in:
parent
dcff08340e
commit
4d6743b886
6 changed files with 51 additions and 30 deletions
|
|
@ -83,12 +83,12 @@ class ColorProfile:
|
|||
for i, t in enumerate(txt):
|
||||
if space_only and t != ' ':
|
||||
if i > 0 and txt[i - 1] == ' ':
|
||||
result += '\033[0m'
|
||||
result += '\033[39;49m'
|
||||
result += t
|
||||
else:
|
||||
result += colors[i].to_ansi(foreground=foreground) + t
|
||||
|
||||
result += '\033[0m'
|
||||
result += '\033[39;49m'
|
||||
return result
|
||||
|
||||
def lighten(self, multiplier: float) -> ColorProfile:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue