diff --git a/src/utils/netspeed.rs b/src/utils/netspeed.rs index fae36b5..4829f30 100644 --- a/src/utils/netspeed.rs +++ b/src/utils/netspeed.rs @@ -18,8 +18,8 @@ pub async fn get_netspeed() -> ThreadsData { let rx = calculate(rx_bps); let data = format!( - " {} {} {} {} {}", - CONFIG.netspeed.recieve_icon, rx, CONFIG.netspeed.transmit_icon, tx, CONFIG.seperator + "{}{} {}{} {}", + rx, CONFIG.netspeed.recieve_icon, tx, CONFIG.netspeed.transmit_icon, CONFIG.seperator ); ThreadsData::NetSpeed(data) } @@ -43,5 +43,5 @@ fn calculate(speed: u64) -> String { speed /= 1024.0; idx += 1; } - format!("{:.1} {}", speed, lookup[idx]) + format!("{: >5.1}{: >2}", speed, lookup[idx]) }