Show network bandwidth in bits not bytes per second - #541
Conversation
Option to display network speeds in bits-per-second instead of bytes.
danirabbit
left a comment
There was a problem hiding this comment.
Format size takes flags so you don't need to create a new util for this https://valadoc.org/glib-2.0/GLib.FormatSizeFlags.html
Does this also really need to be an option? Is this a case where this would just be the better way to format it?
I added the util because glib only returns the size without the "per second" (actually abbreviated to just "ps") portion, eg. "123 bytes" or "123 MB" while this util shows "123 bps" or "123 MBps". It's intended mainly for file sizes I guess? Can we keep this new util? I see your localization comment in the other PR - can we leave this for another PR? I'm in favour of just defaulting to "bits per second" and remove the option/checkbox because network bandwidth is usually seen this way, advertised by ISPs this way etc. but I remember when I sent a PR to KDE there was some user contention from those who prefer bytes, maybe it's a local/regional thing? CC @stsdc looking forward to your feedback too. |
|
I think maybe we should just switch it to bits and see if anyone complains before adding a setting But I think we need to do proper localization here and not regress on that |
…y/monitor into vishal/network-use-bits-option
This is to match the speeds shown on speed test websites but avoid using IEC units like "MiB/s" (avoid showing the lowercase letter I) and keep units like "Mb/s".
@danirabbit @stsdc I've switch back to use the glib format function and attempted to handle RTL/LTR in cb5438f can revert this commit if it's not good but it's not regressing any current localisation - there is the existing |
Addressed in latest commits/comments.
|
I don't have any objections and Ryo has approved. |
Display network speeds in bits-per-second instead of bytes.