-
-
Notifications
You must be signed in to change notification settings - Fork 410
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
Document how to enable truecolor on Windows #135
Comments
I am sorry this terminal on Windows doesn't set the COLORTERM variable. Maybe there is a standard ways in the terminal specification: The cost would be some communication with the terminal via stdin/stdout, before starting. This is a bit annoying, because user's might want to send/receive some data via this channel. I guess we need something user's can call when they need it. Maybe ftxui::QueryColorSupport()
ftxui::OverrideSupportedColor(color_mode) that would query the terminal its supported colors and wait for a reply. It can store the results to:
https://github.com/ArthurSonzogni/FTXUI/blob/master/src/ftxui/screen/terminal.cpp#L50 It's quite hard for me test on Windows. Feel free to submit PR if you can, otherwise, I will try it, but this might take me some time. |
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals if needed. 2. Microsoft's terminal do not provide a way to know if they support colors. As a fallback, assume true colors is supported. See issue: microsoft/terminal#1040 This mitigates: #135 3. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 4. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals if needed. 2. Microsoft's terminal do not provide a way to know if they support colors. As a fallback, assume true colors is supported. See issue: microsoft/terminal#1040 This mitigates: #135 3. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 4. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals if needed. 2. Microsoft's terminals do not provide a way to query if they support colors. As a fallback, assume true colors is supported. See issue: - microsoft/terminal#1040 This mitigates: - #135 3. Microsoft terminal do not handle properly hidding the cursor. Instead the character under the cursor is hidden, which is a big problem. As a result, we don't enable setting the cursor to the best position for [input method editors](https://en.wikipedia.org/wiki/Input_method), It will be displayed at the bottom right corner. See: - microsoft/terminal#1203 - microsoft/terminal#3093 4. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 5. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals on Windows if needed. 2. Microsoft's terminal suffer from a race condition bug when reporting the cursor position: #136 The mitigation is not to ask for the cursor position in fullscreen mode where it isn't really needed and request it less often. This fixes: #136 3. Microsoft's terminal do not handle properly hidding the cursor. Instead the character under the cursor is hidden, which is a big problem. As a result, we don't enable setting the cursor to the best position for [input method editors](https://en.wikipedia.org/wiki/Input_method), It will be displayed at the bottom right corner. See: - microsoft/terminal#1203 - microsoft/terminal#3093 4. Microsoft's terminals do not provide a way to query if they support colors. As a fallback, assume true colors is supported. See issue: - microsoft/terminal#1040 This mitigates: - #135 5. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 6. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals on Windows if needed. 2. Microsoft's terminal suffer from a race condition bug when reporting the cursor position: microsoft/terminal#7583. The mitigation is not to ask for the cursor position in fullscreen mode where it isn't really needed and request it less often. This fixes: #136 3. Microsoft's terminal do not handle properly hidding the cursor. Instead the character under the cursor is hidden, which is a big problem. As a result, we don't enable setting the cursor to the best position for [input method editors](https://en.wikipedia.org/wiki/Input_method), It will be displayed at the bottom right corner. See: - microsoft/terminal#1203 - microsoft/terminal#3093 4. Microsoft's terminals do not provide a way to query if they support colors. As a fallback, assume true colors is supported. See issue: - microsoft/terminal#1040 This mitigates: - #135 5. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 6. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
I finally got access to a computer using the Microsoft's Windows OS. That's the opportunity to find and mitigate all the problems encountered. This patch: 1. Introduce an option and a C++ definition to enable fallback for Microsoft's terminal emulators. This allows me to see/test the Microsoft output from Linux. This also allows Windows users to remove the fallback and target non Microsoft terminals on Windows if needed. 2. Microsoft's terminal suffer from a race condition bug when reporting the cursor position: microsoft/terminal#7583. The mitigation is not to ask for the cursor position in fullscreen mode where it isn't really needed and request it less often. This fixes: #136 3. Microsoft's terminal do not handle properly hidding the cursor. Instead the character under the cursor is hidden, which is a big problem. As a result, we don't enable setting the cursor to the best position for [input method editors](https://en.wikipedia.org/wiki/Input_method), It will be displayed at the bottom right corner. See: - microsoft/terminal#1203 - microsoft/terminal#3093 4. Microsoft's terminals do not provide a way to query if they support colors. As a fallback, assume true colors is supported. See issue: - microsoft/terminal#1040 This mitigates: - #135 5. The "cmd" on Windows do not properly report its dimension. Powershell works correctly. As a fallback, use a 80x80 size instead of 0x0. 6. There are several dom elements and component displayed incorrectly, because the font used is missing several unicode glyph. Use alternatives or less detailled one as a fallback.
Hey @MichaelGoulding, Do you think we should close this issue, given the latest patch? |
FTXUI supports a hack [1] for true color support on Windows that is set via a CMake flag. This patch adds the same flag to the Meson build file. [1] ArthurSonzogni/FTXUI#135
FTXUI supports a hack [1] for true color support on Windows that is set via a CMake flag. This patch adds the same flag to the Meson build file. [1] ArthurSonzogni/FTXUI#135
FTXUI supports a hack [1] for true color support on Windows that is set via a CMake flag. This patch adds the same flag to the Meson build file. [1] ArthurSonzogni/FTXUI#135
FTXUI supports a hack [1] for true color support on Windows that is set via a CMake flag. This patch adds the same flag to the Meson build file. [1] ArthurSonzogni/FTXUI#135
The code looks for the environment variable
to enable true color.
Windows 10 has supported true color in the console for a while now, but FTXUI doesn't do the right thing without the environment variable set:
The text was updated successfully, but these errors were encountered: