Closed ddorn closed 6 years ago
type "%ConEmuBaseDir%\Addons\AnsiColors256.ans"
Just curious, since I ran into this as well. How did you figure out how to run this to fix the 24 bit issue?
Sorry, I can't remember and I switched to linux in the mean time so I've lost any configuration :/ I hope you will find your luck with this !
This needs to be reopened. The behaviour is indeed random as stated in the original post
I know this is an old post, but:
If you open %ConEmuBaseDir%\Addons\AnsiColors256.ans
in vim, it shows that the file starts with this: [32766S[32766H
. That is, ^[[32766S^[[32766H
. I don't know what either does (I think maybe it's clear screen, then move cursor down 32766 lines, but that's just a guess).
Weirdly, adding echo [32766H
(echo ^[[32766H
) to user_profile.cmd fixes it until cls
is run. Of course, this moves the prompt to the bottom of the screen though. Edit: using echo [32766H[2J
(echo ^[[32766H^[[2J
) works.
I have no idea why printing a specific ANSI escape code (p.s., smaller numbers don't seem to work, but I only tried 1, 2, 3, 30 and 32. 32766 is also two less than 32768, i.e. two less than 2¹⁵) does this, and I have no idea why this is the case. The number is also so weird, and the connection to being two less than a power of 2 seems weird, since 30 didn't work. I also don't understand why the number is that large.
Some last minute things: Doesn't work in WSL. Tried Fish + Zellij, Zsh and Bash, so probably not a shell issue. Works in PowerShell and Nushell though, so this is probably not something Command Prompt specific.
It does seem strange that scrolling is required before 8-bit or 24-bit color can work in ConEmu, but that's a ConEmu thing, not a Cmder thing.
Does the same thing happen in ConEmu by itself, without the Cmder initialization script? This is very likely a ConEmu issue, not a Cmder issue.
Cmder is not a terminal emulator. Cmder delegates all terminal emulator to whatever terminal emulator you're using. By default, that's ConEmu for Cmder, although you can configure Cmder to work in any terminal emulator.
The Cmder package includes the ConEmu terminal emulator. Issues in the ConEmu terminal emulator need to be filed in the ConEmu repo so they're visible to the owners/maintainers of ConEmu.
The escape codes you mentioned are CSI n S
(Scroll Up) and CSI n H
(Cursor Position). A good introductory article about escape codes is here: ANSI escape code (wikipedia). I agree that it's mysterious why those codes would make a difference for ConEmu's support of 8-bit or 24-bit color -- it's most likely a bug in ConEmu, so filing an issue in the ConEmu repo is the way to try to get attention/resolution.
I was trying to use 24 bits ansi colors escape sequences in a simple python script
Which doesn't seems to work after a first try because the colors are replaced by the closest one in the 16 palette.
However, if I run
before, it kinda works : And it will work untill I run
cls
.I don't know if this is intended, a bug or something that cmder / ConEmu just doesn't support.
I am on Windows Pro Fall Update (version 1709 build 16299.19) I have
TrueMod (24 bit color) support
checkedThanks for having done such a great console ! It rocks ! ;)