Skip to content

Commit

Permalink
fix: Align ColorTable colors to the base16 spec
Browse files Browse the repository at this point in the history
Below is the default mapping in Windows Console showing how colors are used
by ConsoleHost to display different elements.

| ANSI         | ColorTable | concfg key (PowerShell) | Properties Option  |
|--------------|------------|-------------------------|--------------------|
| White        | 07         | gray                    | Screen Text        |
| Black        | 00         | black                   | Screen Background  |
| Magenta      | 05         | dark_magenta            | Popup Text         |
| Bright White | 15         | white                   | Popup Background   |

* ColorTable[07] (concfg's `gray`, ANSI White) is used as the Screen Text
(ANSI foreground) color in ConsoleHost.
* ColorTable[15] (concfg's `white`, ANSI Bright White) is used as the Popup
Background color in COnsoleHost.

Before this change, `base07` (Light Background in base16 spec) was used for
`gray` and `base06` (Light Foreground in base16 spec) was used for `white`.
This resulted in a background base16 color set to a concfg key (`gray`) which
is used as a foreground color, and a foreground base16 color set to a concfg
key (`white`) which is used as a background color. Further, the colors used
in `screen_colors` and `popup_colors` were inverted in order to align to the
default mapping of ConsoleHost.

In this commit, `gray` is changed to use `base05` (Default Foreground in base16
spec), `white` is changed to use `base07` (Light Background in base16 spec).
With these changes, ColorTable colors now semantically aligns to base16 colors.
The inverted usage of colors in `screen_colors` and `popup_colors` is removed,
leaving a better alignment between ConsoleHost's ColorTable and base16.

Signed-off-by: Chawye Hsu <[email protected]>
  • Loading branch information
chawyehsu committed Dec 24, 2024
1 parent 44e9f3c commit 69c67e4
Show file tree
Hide file tree
Showing 271 changed files with 1,045 additions and 1,045 deletions.
8 changes: 4 additions & 4 deletions presets/base16-3024.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#db2d20",
"dark_magenta": "#a16a94",
"dark_yellow": "#fded02",
"gray": "#f7f7f7",
"gray": "#a5a2a2",
"dark_gray": "#3a3432",
"blue": "#807d7c",
"green": "#4a4543",
"cyan": "#a5a2a2",
"red": "#e8bbd0",
"magenta": "#cdab53",
"yellow": "#5c5855",
"white": "#d6d5d4",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f7f7f7",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-apathy.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#3e9688",
"dark_magenta": "#4c963e",
"dark_yellow": "#3e4c96",
"gray": "#d2e7e4",
"gray": "#81b5ac",
"dark_gray": "#0b342d",
"blue": "#5f9c92",
"green": "#184e45",
"cyan": "#81b5ac",
"red": "#3e7996",
"magenta": "#3e965b",
"yellow": "#2b685e",
"white": "#a7cec8",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#d2e7e4",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-apprentice.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#444444",
"dark_magenta": "#5fafaf",
"dark_yellow": "#87af87",
"gray": "#6c6c6c",
"gray": "#5f5f87",
"dark_gray": "#af5f5f",
"blue": "#5f87af",
"green": "#5f875f",
"cyan": "#5f5f87",
"red": "#ff8700",
"magenta": "#bcbcbc",
"yellow": "#87875f",
"white": "#5f8787",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#6c6c6c",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-ashes.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#c7ae95",
"dark_magenta": "#c795ae",
"dark_yellow": "#aec795",
"gray": "#f3f4f5",
"gray": "#c7ccd1",
"dark_gray": "#393f45",
"blue": "#adb3ba",
"green": "#565e65",
"cyan": "#c7ccd1",
"red": "#c7c795",
"magenta": "#c79595",
"yellow": "#747c84",
"white": "#dfe2e5",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f3f4f5",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-cave-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#be4678",
"dark_magenta": "#955ae7",
"dark_yellow": "#a06e3b",
"gray": "#19171c",
"gray": "#585260",
"dark_gray": "#e2dfe7",
"blue": "#655f6d",
"green": "#8b8792",
"cyan": "#585260",
"red": "#aa573c",
"magenta": "#bf40bf",
"yellow": "#7e7887",
"white": "#26232a",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#19171c",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-cave.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#be4678",
"dark_magenta": "#955ae7",
"dark_yellow": "#a06e3b",
"gray": "#efecf4",
"gray": "#8b8792",
"dark_gray": "#26232a",
"blue": "#7e7887",
"green": "#585260",
"cyan": "#8b8792",
"red": "#aa573c",
"magenta": "#bf40bf",
"yellow": "#655f6d",
"white": "#e2dfe7",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#efecf4",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-dune-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#d73737",
"dark_magenta": "#b854d4",
"dark_yellow": "#ae9513",
"gray": "#20201d",
"gray": "#6e6b5e",
"dark_gray": "#e8e4cf",
"blue": "#7d7a68",
"green": "#a6a28c",
"cyan": "#6e6b5e",
"red": "#b65611",
"magenta": "#d43552",
"yellow": "#999580",
"white": "#292824",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#20201d",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-dune.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#d73737",
"dark_magenta": "#b854d4",
"dark_yellow": "#ae9513",
"gray": "#fefbec",
"gray": "#a6a28c",
"dark_gray": "#292824",
"blue": "#999580",
"green": "#6e6b5e",
"cyan": "#a6a28c",
"red": "#b65611",
"magenta": "#d43552",
"yellow": "#7d7a68",
"white": "#e8e4cf",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#fefbec",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-estuary-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ba6236",
"dark_magenta": "#5f9182",
"dark_yellow": "#a5980d",
"gray": "#22221b",
"gray": "#5f5e4e",
"dark_gray": "#e7e6df",
"blue": "#6c6b5a",
"green": "#929181",
"cyan": "#5f5e4e",
"red": "#ae7313",
"magenta": "#9d6c7c",
"yellow": "#878573",
"white": "#302f27",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#22221b",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-estuary.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ba6236",
"dark_magenta": "#5f9182",
"dark_yellow": "#a5980d",
"gray": "#f4f3ec",
"gray": "#929181",
"dark_gray": "#302f27",
"blue": "#878573",
"green": "#5f5e4e",
"cyan": "#929181",
"red": "#ae7313",
"magenta": "#9d6c7c",
"yellow": "#6c6b5a",
"white": "#e7e6df",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f4f3ec",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-forest-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#f22c40",
"dark_magenta": "#6666ea",
"dark_yellow": "#c38418",
"gray": "#1b1918",
"gray": "#68615e",
"dark_gray": "#e6e2e0",
"blue": "#766e6b",
"green": "#a8a19f",
"cyan": "#68615e",
"red": "#df5320",
"magenta": "#c33ff3",
"yellow": "#9c9491",
"white": "#2c2421",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#1b1918",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-forest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#f22c40",
"dark_magenta": "#6666ea",
"dark_yellow": "#c38418",
"gray": "#f1efee",
"gray": "#a8a19f",
"dark_gray": "#2c2421",
"blue": "#9c9491",
"green": "#68615e",
"cyan": "#a8a19f",
"red": "#df5320",
"magenta": "#c33ff3",
"yellow": "#766e6b",
"white": "#e6e2e0",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f1efee",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-heath-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ca402b",
"dark_magenta": "#7b59c0",
"dark_yellow": "#bb8a35",
"gray": "#1b181b",
"gray": "#695d69",
"dark_gray": "#d8cad8",
"blue": "#776977",
"green": "#ab9bab",
"cyan": "#695d69",
"red": "#a65926",
"magenta": "#cc33cc",
"yellow": "#9e8f9e",
"white": "#292329",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#1b181b",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-heath.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ca402b",
"dark_magenta": "#7b59c0",
"dark_yellow": "#bb8a35",
"gray": "#f7f3f7",
"gray": "#ab9bab",
"dark_gray": "#292329",
"blue": "#9e8f9e",
"green": "#695d69",
"cyan": "#ab9bab",
"red": "#a65926",
"magenta": "#cc33cc",
"yellow": "#776977",
"white": "#d8cad8",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f7f3f7",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-lakeside-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#d22d72",
"dark_magenta": "#6b6bb8",
"dark_yellow": "#8a8a0f",
"gray": "#161b1d",
"gray": "#516d7b",
"dark_gray": "#c1e4f6",
"blue": "#5a7b8c",
"green": "#7ea2b4",
"cyan": "#516d7b",
"red": "#935c25",
"magenta": "#b72dd2",
"yellow": "#7195a8",
"white": "#1f292e",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#161b1d",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-lakeside.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#d22d72",
"dark_magenta": "#6b6bb8",
"dark_yellow": "#8a8a0f",
"gray": "#ebf8ff",
"gray": "#7ea2b4",
"dark_gray": "#1f292e",
"blue": "#7195a8",
"green": "#516d7b",
"cyan": "#7ea2b4",
"red": "#935c25",
"magenta": "#b72dd2",
"yellow": "#5a7b8c",
"white": "#c1e4f6",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#ebf8ff",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-plateau-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ca4949",
"dark_magenta": "#8464c4",
"dark_yellow": "#a06e3b",
"gray": "#1b1818",
"gray": "#585050",
"dark_gray": "#e7dfdf",
"blue": "#655d5d",
"green": "#8a8585",
"cyan": "#585050",
"red": "#b45a3c",
"magenta": "#bd5187",
"yellow": "#7e7777",
"white": "#292424",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#1b1818",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-plateau.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#ca4949",
"dark_magenta": "#8464c4",
"dark_yellow": "#a06e3b",
"gray": "#f4ecec",
"gray": "#8a8585",
"dark_gray": "#292424",
"blue": "#7e7777",
"green": "#585050",
"cyan": "#8a8585",
"red": "#b45a3c",
"magenta": "#bd5187",
"yellow": "#655d5d",
"white": "#e7dfdf",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#f4ecec",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-savanna-light.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#b16139",
"dark_magenta": "#55859b",
"dark_yellow": "#a07e3b",
"gray": "#171c19",
"gray": "#526057",
"dark_gray": "#dfe7e2",
"blue": "#5f6d64",
"green": "#87928a",
"cyan": "#526057",
"red": "#9f713c",
"magenta": "#867469",
"yellow": "#78877d",
"white": "#232a25",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#171c19",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
8 changes: 4 additions & 4 deletions presets/base16-atelier-savanna.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
"dark_red": "#b16139",
"dark_magenta": "#55859b",
"dark_yellow": "#a07e3b",
"gray": "#ecf4ee",
"gray": "#87928a",
"dark_gray": "#232a25",
"blue": "#78877d",
"green": "#526057",
"cyan": "#87928a",
"red": "#9f713c",
"magenta": "#867469",
"yellow": "#5f6d64",
"white": "#dfe7e2",
"screen_colors": "white,black",
"popup_colors": "dark_magenta,gray"
"white": "#ecf4ee",
"screen_colors": "gray,black",
"popup_colors": "dark_magenta,white"
}
Loading

0 comments on commit 69c67e4

Please sign in to comment.