-
Notifications
You must be signed in to change notification settings - Fork 25
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
[Suggestion] console::Emoji
Struct for Fallback Strings
#121
Comments
Hey @kevinmatthes, Sorry again for taking a while. I'm not sure if there are substitute for all the characters to achieve a somewhat satisfying result. The way I thought about it until now was, that if there are missing symbols it's a good indicator that the font could use an update (or in case of this app font dependencies are missing). Afaik all updated nerd-fonts contain the same characters. Though a missing unicode font could cause issues as well. But both are listed as dependencies. So this is from a perspective not having done a lot of testing on which characters to use as substitutes. If this should be integrated, which one e.g. should we use to substitute the graph? |
At the moment, there are more than three levels for one graph character. I would like to suggest to reduce it to three levels in the fallback using characters like these:
For other emojis, we could use some simple ASCII Art, like I do not know how the Nerd Fonts work for other users but on my machine, it is still not possible to have the emojis displayed properly even with a Nerd Font installed. I still use Hack as font in KDE Konsole. |
For some of the applied emojis, there are also other valid UTF-8 characters which can be rendered in UTF-8 fonts without any problems. The best examples are the wind directions; there are arrows with exactly the same directions in the intervals |
|
Good points, especially that there might be issues depending on the capabilities of the used terminal. This also was one of the functional reasons why I integrated configurable styles. It were the Unicode characters used in the graph (that aren't Nerd Font) could be subject to misalignment in some terminals. However, I haven't experienced a terminal that couldn't display Nerd Fonts yet. I'm using Plasma as my main DE, so Konsole is not far away. If you would like to share more about the font issue you are experiencing, I would be happy to help. In terms of integrating this suggestion: while I wouldn't start implementing on this myself, I'm open to merging it if it's submitted. |
After some research for the My suggestion would be to introduce a new configuration option named something like With such a new option, users who prefer good old ASCII Art to emojis as well as users with restricted terminals could control how the output is generated. What do you thing about this configuration option, @tobealive? Which name would you prefer? |
I would like to suggest to add
console
as dependency in order to access itsEmoji
wrapper struct. That struct allows for the definition of a fallback string in case that some terminals should be unable to display the configured emojis even though having a Nerd Font configured.The library is licensed MIT such that no license issues would arise. The public GitHub repository is https://github.com/console-rs/console, the latest version -- v0.15.5 -- was published in January.
@tobealive, what do you think?
The text was updated successfully, but these errors were encountered: