New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The fix for ConEmu#1288 regresses high-intensity color #1304

Closed
DHowett opened this Issue Oct 30, 2017 · 3 comments

Comments

Projects
None yet
3 participants
@DHowett

DHowett commented Oct 30, 2017

Versions

ConEmu build: 171025
Used shell version (Far Manager, git-bash, cmd, powershell, cygwin, whatever): any

Problem description

The fix for #1288 intentionally disables 1 as the SGR code for "bright" colors in favor of 90-97. I know that a strict reading of the standard specifies that 1 should be reserved for bold or "intense" (implementation-defined) color, but for better or for worse all modern terminals have standardized on either having it be 1) configurable or 2) bright, as specified in color slots 8-16.

90-97, while more expressive (and arguably better!), is not standard as of ITU T.416 (1993). It looks like it's only supported on AIXTerm and a few other terminal emulators. As such, ConEmu users will need to either find (or build) tools that emit nonstandard sequences, and change their shell and utility configurations to support both ConEmu and other terminal emulators.

Steps to reproduce

$e=[char]0x1b;
echo "$e[1;31mHELLO$e[0;31mGOODBYE$e[0m"

Actual results

image

Expected results

image

@fpqc

This comment has been minimized.

Show comment
Hide comment
@fpqc

fpqc Nov 7, 2017

Yep, noticed this too! It completely disabled colors 8-16 and replaced them with bold.

Mintty for example has options to display bold as bold text, bold as intense colors (8-16) or both.

image

Arguably, the correct way to do things would be for @Maximus5 to submit a conemu terminfo file to Thomas Dickey, have it added to the official terminfo database, and have it match the internals of Conemu, then have the wslbridge set TERM=conemu.

fpqc commented Nov 7, 2017

Yep, noticed this too! It completely disabled colors 8-16 and replaced them with bold.

Mintty for example has options to display bold as bold text, bold as intense colors (8-16) or both.

image

Arguably, the correct way to do things would be for @Maximus5 to submit a conemu terminfo file to Thomas Dickey, have it added to the official terminfo database, and have it match the internals of Conemu, then have the wslbridge set TERM=conemu.

@fpqc

This comment has been minimized.

Show comment
Hide comment
@fpqc

fpqc Nov 11, 2017

@Maximus5
image

All fixed now, super excited!

It would make life a whole lot easier if you added the termcol/ANSI translation to each of the colors in the color setting dialogue, right now I had to do it by trial and error:

image

Also, one missing feature is setting ConEMU's cursor color/type. This can be controlled by ANSI codes usually, but it doesn't seem like there's a way to set the default color or shape.

Also, it would be nice to see an explanation for why blue, yellow, and cyan have two numbers next to them, and also what popup and popup background do in ANSI mode. Thanks again!

fpqc commented Nov 11, 2017

@Maximus5
image

All fixed now, super excited!

It would make life a whole lot easier if you added the termcol/ANSI translation to each of the colors in the color setting dialogue, right now I had to do it by trial and error:

image

Also, one missing feature is setting ConEMU's cursor color/type. This can be controlled by ANSI codes usually, but it doesn't seem like there's a way to set the default color or shape.

Also, it would be nice to see an explanation for why blue, yellow, and cyan have two numbers next to them, and also what popup and popup background do in ANSI mode. Thanks again!

@Maximus5

This comment has been minimized.

Show comment
Hide comment
@Maximus5

Maximus5 Nov 13, 2017

Owner

Also, one missing feature is setting ConEMU's cursor color/type. This can be controlled by ANSI codes usually, but it doesn't seem like there's a way to set the default color or shape.

You may change the cursor shape with ANSI. Color of the cursor is not configurable.
If option Color (inverse screen part under cursor shape) is turnen on - ConEmu uses pattern to inverse area under the cursor. If option is off - either 0 or 15 color is used (depends on dark or light background).

Also, it would be nice to see an explanation for why blue, yellow, and cyan have two numbers next to them, and also what popup and popup background do in ANSI mode.

ANSI color indexes are not compliant with standard Windows console color palette. So the first index is RealConsole (WinApi) palette index and second index - is ANSI index.
So the "blue" would be either "34" for text, or "44" for background color.
Same for "intense" part, but I didn't add second index there.
Of course, for intense you may use "94" and "104" or BrightOrBold ANSI flag.

As usual, PR to documentation are appreciated.

Owner

Maximus5 commented Nov 13, 2017

Also, one missing feature is setting ConEMU's cursor color/type. This can be controlled by ANSI codes usually, but it doesn't seem like there's a way to set the default color or shape.

You may change the cursor shape with ANSI. Color of the cursor is not configurable.
If option Color (inverse screen part under cursor shape) is turnen on - ConEmu uses pattern to inverse area under the cursor. If option is off - either 0 or 15 color is used (depends on dark or light background).

Also, it would be nice to see an explanation for why blue, yellow, and cyan have two numbers next to them, and also what popup and popup background do in ANSI mode.

ANSI color indexes are not compliant with standard Windows console color palette. So the first index is RealConsole (WinApi) palette index and second index - is ANSI index.
So the "blue" would be either "34" for text, or "44" for background color.
Same for "intense" part, but I didn't add second index there.
Of course, for intense you may use "94" and "104" or BrightOrBold ANSI flag.

As usual, PR to documentation are appreciated.

@Maximus5 Maximus5 closed this Nov 13, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment