Bar soft wraps if terminal window is too narrow (wide unicode chars are tricky)
See original GitHub issueAs in the title: when terminal window is too narrow progress bar stops animating and it prints itself line by line.
I’m using code from README:
with alive_bar(len(text)) as bar:
for i in range(len(text)):
#do some stuff
bar(text="xd", incr=1)
Here’s output:
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:51 (39 by maintainers)
Top Results From Across the Web
Need a single width unicode character to indicate a wide ...
I'm looking at formatting a utf8 free text string to fit an exact column width on a terminal. I'm coding various truncation methods ......
Read more >Double-width characters in Unicode 9+ - Freedesktop GitLab
Making a character narrower is way more problematic when it comes to line wrapping. You print a double-wide character first, but there was ......
Read more >Unicode and UTF-8 Output Text Buffer - Windows Command ...
In this post, we'll discuss the improvements we've been making to the Windows Console's internal text buffer, enabling it to better store and ......
Read more >UTS #18: Unicode Regular Expressions
Unicode is a large character set—regular expression engines that are only adapted to handle small character sets will not scale well. Unicode ......
Read more >mintty [OPTION]... [ - | PROGRAM [ARG]... ]
Determine whether to keep the terminal window open when the command has ... while the horizontal terminal view is narrower than the actual...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Here it is:
Hello @MartinHammarstedt, how are you?
Good news, this is ready and working! 🎉 After realizing that v2 was getting way too big, I’ve decided to split this implementation in two: now we’ll get a static soft wrap behavior right in this major (so including python 2 support), and someday that adaptive one I’ve talked about.
This new version will include:
Wow, that will make a very mature and feature complete progress bar for python 2, ready to expand for python 3 only.