Comments (9)
However, the
output_vt100
crate only seems to enable truecolor support for STDOUT, not for STDERR:
https://github.com/Phundrak/output-vt100-rs/blob/795d3ecf77e8a6bfbd259dfb52c72231452b1b00/src/lib.rs#L30-L33
As long as STDOUT isn't redirected, the referenced code for output_vt100
should correctly invoke the enhanced display semantics for the console display. The CreateFile(...)
method in my PR for ansi-term
just fixes the problem for a redirected STDOUT. And I've since created a better version of the same fix, using CreateFileW()
.
But I don't think that this would be the problem for this issue, unless STDOUT is redirected in some way for the spectrum display. It may be a Windows console bug instead. Or maybe a "pixel" size/density issue?
from pastel.
Due to the fix by @lzybkr, we now have working truecolor support on Windows.
However, the output_vt100
crate only seems to enable truecolor support for STDOUT, not for STDERR:
https://github.com/Phundrak/output-vt100-rs/blob/795d3ecf77e8a6bfbd259dfb52c72231452b1b00/src/lib.rs#L30-L33
I guess this is the reason that the color spectrum in pastel pick
does not show up in truecolor:
Apart from that, everything seems to work fine:
from pastel.
ansi_term
does the following:
https://github.com/ogham/rust-ansi-term/blob/451c1ab78f4e8c146512998ef7b5963fed04540f/src/windows.rs#L25-L27
See also ogham/rust-ansi-term#50 for an explanation.
from pastel.
@rivy Thank you very much for the clarification! I was on the wrong way there..
Your comment actually made me look into our code again and it turns out that this was still a problem with pastel
. There were actually two places where I checked for the COLORTERM
environment variable and only one of them was "patched" in #68 to always yield "truecolor" for Windows.
I just pushed an update that fixes the issue:
from pastel.
Now we just need an external colorpicker for Windows that we could add here:
Lines 64 to 97 in 4ba074c
from pastel.
😄
Ha! You beat me to it.
I was just playing around with it and discovered that COLORTERM=truecolor
fixed the issue.
I was just going to post about it.
from pastel.
Going to close this for now. If someone finds a colorpicker for Windows that could be included, let me know. Apart from this, the Windows build should work just fine.
from pastel.
@sharkdp I know this issue is currently closed but would you be releasing pre-build Windows .exe binaries for this, or must we build from src?
from pastel.
If someone wants to write the deployment scripts (via travis or appveyor), I'm happy to include them. But I'm probably not going to work on this on my own. (Deployment code for Windows can be found in my other Rust projects, e.g. bat
or fd
).
from pastel.
Related Issues (20)
- support all named colors from X11 rgb.txt HOT 5
- Support "short" display option? HOT 2
- github release v0.8.1 HOT 2
- Most similar colors option HOT 1
- fzf preview window does not show colors from pastel's output HOT 5
- Colorpicker options HOT 2
- Rotate in La*b* space HOT 1
- `pick` error HOT 4
- How to print ansi reset code (`\e[m`)? HOT 11
- How to create background colors with `pastel format`? HOT 1
- Can this Generate a Sequence of Color Shade strings? HOT 3
- Performance issue with the redundancy operations HOT 1
- [pastel error]: Could not find any external color picker tool HOT 2
- Picking directly from terminal HOT 2
- It would be great to be able to paint gradients in TMUX and Powerline directly with pastel HOT 1
- Feature request: Short name for some commands HOT 1
- The bars doesn't show colors HOT 1
- colorcheck not in commands list ? HOT 3
- `pastel pick` does not work and suggests unhelpful advice. HOT 1
- missing dependencies HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pastel.