Uptime location experiment
See original GitHub issuehttps://github.com/aristocratos/bpytop/blob/59916c9a85f416d1927d2c6b3e3abdee0708a5fe/bpytop.py#L1640
Changed this to:
out += f'{Mv.to(y - 1, x + w - 32)}{THEME.graph_text} up {cpu.uptime} '
I modified the uptime display location in my copy of bpytop just to see how it would turn out. I haven’t gotten sophisticated enough to add the vertical green lines, but I have to say for now I’m just fine with how it looks, after adding a space at the beginning and end.
It works at all window sizes, and should have enough room at 80x24 even on a system with up to 999 days of uptime. There does seem to be a small glitch when it rolls over from 23:59 hours to 0:00, which leaves two spaces at the end instead of one until the app is restarted (or you get back to 10:00 or more hours of uptime).
I’m not offering this up as a pull request for now, but I am curious why anyone would not want this to be the default. It actually seems to balance the menu bar out a bit now that the mini mode indicator has been added to the left side. The balance would be even better if " days" was changed to “d” to make it more compact. Then it could be moved over to about x + w - 29
instead of x + w - 32
.
Of course the main point of trying this out was because I didn’t like the way the current uptime location interferes with the CPU graph rendering. This fixes that, for me, in a way that I like, and I wonder what others think of doing it this way.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (6 by maintainers)
Top GitHub Comments
Since this relates to design choices rather than functionality and is very subjective, I’ll leave this open for others to voice opinions before making any changes.
I’m going to close this since there seems to be little interest in moving the uptime, and the battery info is now inhabiting the top bar.