Add color scheme for EGA (the "16 color ANSI" palette) #21293

Closed
opened 2026-01-31 07:39:01 +00:00 by claunia · 7 comments
Owner

Originally created by @nahkampf on GitHub (Feb 23, 2024).

Description of the new feature/enhancement

The 16 color standard EGA palette used on PCs back in the day was a very defining look (and still in use today for the correct look of DOS CLI/TUI programs and ANSI art etc), and I think it should definitely be a default colorscheme that comes with Windows Terminal.

Proposed technical implementation details (optional)

Add a default color scheme (call it "EGA" or "ANSI" or "MS-DOS" or whatever):

{
    "background": "#000000",
    "black": "#000000",
    "blue": "#0000AA",
    "brightBlack": "#555555",
    "brightBlue": "#5555FF",
    "brightCyan": "#55FFFF",
    "brightGreen": "#55FF55",
    "brightPurple": "#FF55FF",
    "brightRed": "#FF5555",
    "brightWhite": "#FFFFFF",
    "brightYellow": "#FFFF55",
    "cursorColor": "#00AA00",
    "cyan": "#00AAAA",
    "foreground": "#AAAAAA",
    "green": "#00AA00",
    "name": "16 Color ANSI",
    "purple": "#AA00AA",
    "red": "#AA0000",
    "selectionBackground": "#FFFFFF",
    "white": "#AAAAAA",
    "yellow": "#AA5500"
}
Originally created by @nahkampf on GitHub (Feb 23, 2024). # Description of the new feature/enhancement The 16 color standard EGA palette used on PCs back in the day was a very defining look (and still in use today for the correct look of DOS CLI/TUI programs and ANSI art etc), and I think it should definitely be a default colorscheme that comes with Windows Terminal. # Proposed technical implementation details (optional) Add a default color scheme (call it "EGA" or "ANSI" or "MS-DOS" or whatever): ```json { "background": "#000000", "black": "#000000", "blue": "#0000AA", "brightBlack": "#555555", "brightBlue": "#5555FF", "brightCyan": "#55FFFF", "brightGreen": "#55FF55", "brightPurple": "#FF55FF", "brightRed": "#FF5555", "brightWhite": "#FFFFFF", "brightYellow": "#FFFF55", "cursorColor": "#00AA00", "cyan": "#00AAAA", "foreground": "#AAAAAA", "green": "#00AA00", "name": "16 Color ANSI", "purple": "#AA00AA", "red": "#AA0000", "selectionBackground": "#FFFFFF", "white": "#AAAAAA", "yellow": "#AA5500" } ```
claunia added the Issue-FeatureArea-SettingsNeeds-Tag-FixProduct-Terminal labels 2026-01-31 07:39:01 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Feb 23, 2024):

Vintage left, 16 Color ANSI right.

image

If anything, this falls under the same category as #6176 - blocked till #12800 lands

@zadjii-msft commented on GitHub (Feb 23, 2024): Vintage left, 16 Color ANSI right. ![image](https://github.com/microsoft/terminal/assets/18356694/e138753e-be37-4e64-a5a8-c72d8d4e03ce) If anything, this falls under the same category as #6176 - blocked till #12800 lands
Author
Owner

@carlos-zamora commented on GitHub (Mar 6, 2024):

For tracking, here's a comment that's pretty relevant: https://github.com/microsoft/terminal/issues/7388#issuecomment-683329150

@carlos-zamora commented on GitHub (Mar 6, 2024): For tracking, here's a comment that's pretty relevant: https://github.com/microsoft/terminal/issues/7388#issuecomment-683329150
Author
Owner

@PhMajerus commented on GitHub (Mar 8, 2024):

@zadjii-msft Note the dark yellow / brown colors.
You actually need both, because the original CGA adapter used a 4-bit digital (TTL) RGBI interface to the monitor.
IBM 5153 and other high-end monitors would handle dark yellow with a special circuit to reduce its green component and turn the nasty yellow into the pleasing brown.
Most old-style ANSI-art expect the brown, but the Windows console probably needed to be compatible with 16-colors graphics mode and use the dark yellow instead, so both variants have decades of real-world use.

@PhMajerus commented on GitHub (Mar 8, 2024): @zadjii-msft Note the dark yellow / brown colors. You actually need both, because the original CGA adapter used a 4-bit digital (TTL) RGBI interface to the monitor. IBM 5153 and other high-end monitors would handle dark yellow with a special circuit to reduce its green component and turn the `nasty yellow` into the `pleasing brown`. Most old-style ANSI-art expect the brown, but the Windows console probably needed to be compatible with 16-colors graphics mode and use the dark yellow instead, so both variants have decades of real-world use.
Author
Owner

@zadjii-msft commented on GitHub (Mar 27, 2024):

@PhMajerus would you have a specific proposal for different names for these schemes?

I think this page: https://int10h.org/blog/2022/06/ibm-5153-color-true-cga-palette/ is talking about the same effect you're describing. Based on the yellows, I'm thinking:

  • #AA5500 is "CGA"
  • #C47E00 is "IBM 5153"
@zadjii-msft commented on GitHub (Mar 27, 2024): @PhMajerus would you have a specific proposal for different names for these schemes? I think this page: https://int10h.org/blog/2022/06/ibm-5153-color-true-cga-palette/ is talking about the same effect you're describing. Based on the yellows, I'm thinking: * `#AA5500` is "CGA" * `#C47E00` is "IBM 5153"
Author
Owner

@PhMajerus commented on GitHub (Mar 27, 2024):

@zadjii-msft
I believe EGA and VGA used the brown instead of olive (dirty yellow) in their default palette to be CGA-compatible. Since those connect with analog connectors and did the color adjustment in the card itself, I consider that 16-colors palette to be the official one.
Remember CGA is originally an IBM product, designed for the 5153 monitor, only 3rd party cheaper monitors didn't change olive to brown, so I usually call the brown variant "CGA".
The olive variant only exists because of RGBI monitors that used the 4 digital lines of their connection literally without the brown trick, so I usually call that variant "RGBI".
Finally, Windows 3.x and 9x that had 16 colors mode, as well as the default palette for the console until recently used very saturated RGBI, so I usually differentiate that as "Windows legacy 16-colors".

image

@PhMajerus commented on GitHub (Mar 27, 2024): @zadjii-msft I believe EGA and VGA used the brown instead of olive (dirty yellow) in their default palette to be CGA-compatible. Since those connect with analog connectors and did the color adjustment in the card itself, I consider that 16-colors palette to be the official one. Remember CGA is originally an IBM product, designed for the 5153 monitor, only 3rd party cheaper monitors didn't change olive to brown, so I usually call the brown variant "CGA". The olive variant only exists because of RGBI monitors that used the 4 digital lines of their connection literally without the brown trick, so I usually call that variant "RGBI". Finally, Windows 3.x and 9x that had 16 colors mode, as well as the default palette for the console until recently used very saturated RGBI, so I usually differentiate that as "Windows legacy 16-colors". ![image](https://github.com/microsoft/terminal/assets/25664275/5aa269d7-aab5-45f9-93a0-bd44b371c4bf)
Author
Owner

@PhMajerus commented on GitHub (Mar 27, 2024):

Oh, and here are the RGB values for each:

CGA

image

RGBI

image

Windows 16-colors

image

Note however that back in the pre-LCD days, we had a contrast dial on the monitor, so many people would set their monitor to have less contrast to make them easier on the eyes for hours of work.
It could be nice to add a contrast slider below the color scheme in profiles' appearance, to allow a similar experience without having to create several contrast variations of the same color scheme.

@PhMajerus commented on GitHub (Mar 27, 2024): Oh, and here are the RGB values for each: ### CGA ![image](https://github.com/microsoft/terminal/assets/25664275/b64b996c-38f6-470d-bd34-e342a1d11472) ### RGBI ![image](https://github.com/microsoft/terminal/assets/25664275/68ac7677-c207-46d3-97f8-ef3071cfe88f) ### Windows 16-colors ![image](https://github.com/microsoft/terminal/assets/25664275/7c647ec5-d9e8-4b3c-af8b-74e50deade3a) Note however that back in the pre-LCD days, we had a contrast dial on the monitor, so many people would set their monitor to have less contrast to make them easier on the eyes for hours of work. It could be nice to add a contrast slider below the color scheme in profiles' appearance, to allow a similar experience without having to create several contrast variations of the same color scheme.
Author
Owner

@PhMajerus commented on GitHub (Mar 27, 2024):

The article you linked to is very interesting as well, and to me means using the "IBM 5153" name should be reserved for a the revised CGA palette that emulates IBM monitors specific circuitry. So your naming seems right to me.

I believe most ANSI-art will expect CGA to be the canonical CGA-compatible palette found in VGA, merely because real CGA was only used since 1981, and consumers got VGA starting in 1987, and used it with MS-DOS until Windows 95 took over and made everyone use conhost with the Windows legacy 16-colors. Windows 3.x 386-enhanced supported running DOS in a window as well, but most users would have experienced it in full-screen text mode until Windows 95.

@PhMajerus commented on GitHub (Mar 27, 2024): The article you linked to is very interesting as well, and to me means using the "IBM 5153" name should be reserved for a the revised CGA palette that emulates IBM monitors specific circuitry. So your naming seems right to me. I believe most ANSI-art will expect CGA to be the canonical CGA-compatible palette found in VGA, merely because real CGA was only used since 1981, and consumers got VGA starting in 1987, and used it with MS-DOS until Windows 95 took over and made everyone use conhost with the Windows legacy 16-colors. Windows 3.x 386-enhanced supported running DOS in a window as well, but most users would have experienced it in full-screen text mode until Windows 95.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#21293