Use ellipses when truncating progress#15330
Use ellipses when truncating progress#15330WhyNotHugo wants to merge 1 commit intorust-lang:masterfrom
Conversation
Use ellipses when truncating progress instead of three periods. While this allows an extra two characters to fit on screen, the main motivation it to reduce the visual quirkiness or the resulting output.
|
r? @weihanglo rustbot has assigned @weihanglo. Use |
| } else { | ||
| string.truncate(ellipsis_pos); | ||
| string.push_str("..."); | ||
| string.push_str("…"); |
There was a problem hiding this comment.
We do not unconditionally output unicode characters but need to check either shell().out_unicode() or shell().err_unicode().
There was a problem hiding this comment.
Unicode is a superset of ascii. I assume you mean non-ascii Unicode?
It actually slipped my mind that this is non-ascii. I'll update this and review the tests below.
There was a problem hiding this comment.
Unicode is a superset of ascii. I assume you mean non-ascii Unicode?
Yes
|
Thanks for contributing this! It would be great to find ways to better leverage unicode output now that we can with |
|
@rustbot user |
Use ellipses when truncating progress instead of three periods. While this allows an extra two characters to fit on screen, the main motivation it to reduce the visual quirkiness or the resulting output. Closes rust-lang#15330
### What does this PR try to resolve? Use ellipses when truncating progress instead of three periods. While this allows an extra two characters to fit on screen, the main motivation it to reduce the visual quirkiness or the resulting output. ### How to test and review this PR? This applies the review feedback left in #15330 Closes #15330
What does this PR try to resolve?
Visual quirkiness in progress that doesn't fit on screen. Instead of using three periods at the end of the screen, use an ellipses.
How should we test and review this PR?
Any regular operation on a narrow screen should make the difference evident.
Additional information
n/a