mirror of
https://github.com/wez/wezterm.git
synced 2024-11-22 22:42:48 +03:00
Detect true color set by max_colors
Terminals like `xterm-direct` has max_colors set to 16M. They should be treated as supporting true colors.
This commit is contained in:
parent
7590968257
commit
3f1a120074
@ -219,7 +219,9 @@ impl Capabilities {
|
||||
if has_true_color {
|
||||
ColorLevel::TrueColor
|
||||
} else if let Some(cap::MaxColors(n)) = db.get::<cap::MaxColors>() {
|
||||
if n >= 256 {
|
||||
if n >= 16777216 {
|
||||
ColorLevel::TrueColor
|
||||
} else if n >= 256 {
|
||||
ColorLevel::TwoFiftySix
|
||||
} else {
|
||||
ColorLevel::Sixteen
|
||||
|
Loading…
Reference in New Issue
Block a user