bpytop
bpytop copied to clipboard
[REQUEST] Swap network download/upload graphs
Or make option for this. Because download and upload
Swap them to what? Can you please specify this a bit more or add suggestion picture. :)
Network download and upload
I concur, I find it really disturbing to have the up link down, and the down link up.
There are three places to change if you want to do it yourself (line numbers as per current master:)
Line 2372
{create_box(x=cls.box_x, y=cls.box_y, width=cls.box_width, height=cls.box_height, line_color=THEME.div_line, fill=False, title="Download", title2="Upload")}'
becomes {create_box(x=cls.box_x, y=cls.box_y, width=cls.box_width, height=cls.box_height, line_color=THEME.div_line, fill=False, title="Upload", title2="Download")}'
Line 2409
for direction in ["download", "upload"]:
becomes for direction in ["upload", "download"]:
And in the lines below (2415 and 2416à, replace download
by upload
out += (f'{Mv.to(y, x)}{THEME.graph_text(net.sync_string if CONFIG.net_sync else net.strings[net.nic]["download"]["graph_top"])}'
f'{Mv.to(y+h-1, x)}{THEME.graph_text(net.sync_string if CONFIG.net_sync else net.strings[net.nic]["upload"]["graph_top"])}')
become
out += (f'{Mv.to(y, x)}{THEME.graph_text(net.sync_string if CONFIG.net_sync else net.strings[net.nic]["upload"]["graph_top"])}'
f'{Mv.to(y+h-1, x)}{THEME.graph_text(net.sync_string if CONFIG.net_sync else net.strings[net.nic]["download"]["graph_top"])}')
That's just a hack though, not a config option, and will be reverted when you update BPYTOP.