sane focus

This commit is contained in:
🪞👃🪞 2024-06-21 13:52:21 +03:00
parent be2c2df92b
commit 3177e4ab58
2 changed files with 13 additions and 3 deletions

View file

@ -49,7 +49,7 @@ pub fn render (state: &Plugin, buf: &mut Buffer, Rect { x, y, .. }: Rect)
Some(PluginKind::LV2(ports, instance)) => {
let mut height = 3;
for (i, port) in ports.iter().skip(state.parameter_offset).enumerate() {
if i >= 20 {
if i >= 30 {
break
}
buf.set_string(x + 2, y + 3 + i as u16, &format!("{:30} = {:03}",
@ -58,7 +58,7 @@ pub fn render (state: &Plugin, buf: &mut Buffer, Rect { x, y, .. }: Rect)
), Style::default());
height = height + 1;
}
Ok(draw_box(buf, Rect { x, y, width: 50, height: height.max(20) }))
Ok(draw_box(buf, Rect { x, y, width: 50, height: height.max(30) }))
},
_ => {
buf.set_string(x + 1, y + 3, &format!(" Parameter 1 0.0"), style);