feat: add NET graph (download/upload) to System tab
La pestaña Sistema ahora muestra una gráfica de red bajo DISK I/O con dos series (download en cian, upload en naranja) y las velocidades en vivo en la cabecera. Reutiliza los históricos hist.down/hist.up que ya se actualizaban cada frame para la pestaña Red, sin coste extra de muestreo. También fija own_window_type='dock' para que el WM no mueva el widget con Alt+drag y siga recibiendo clicks en las pestañas. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -381,6 +381,14 @@ local function draw_sys(cr)
|
||||
gh = row("DISK I/O", str("${diskio}"), COL.orange, 26)
|
||||
graph(cr, x, y, gw, gh, { { data = hist.diskio, c = COL.purple, fill = true } }); y = y + gh + 6
|
||||
|
||||
-- NET (red: download + upload). Dos series: down (cian) y up (naranja).
|
||||
gh = row("NET", "↓ " .. str("${downspeed " .. NIF .. "}") ..
|
||||
" ↑ " .. str("${upspeed " .. NIF .. "}"), COL.blue, 26)
|
||||
graph(cr, x, y, gw, gh, {
|
||||
{ data = hist.down, c = COL.down },
|
||||
{ data = hist.up, c = COL.up },
|
||||
}); y = y + gh + 6
|
||||
|
||||
-- Uso de discos
|
||||
text(cr, x, y + 10, "USO DE DISCOS", COL.snow, 10, true); y = y + 16
|
||||
local disks = { "/", "/mnt/1tb", "/mnt/2tb", "/mnt/16tb" }
|
||||
|
||||
Reference in New Issue
Block a user