A simple CPU rendered GUI IDE experience.
fast scroll
| -rw-r--r-- | src/main.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index df2555f..7fa9356 100644 --- a/src/main.rs +++ b/src/main.rs @@ -478,7 +478,7 @@ pub(crate) fn entry(event_loop: EventLoop<()>) { phase: _, }, } => { - let rows = rows * 3.; + let rows = if alt() { rows * 8. } else { rows * 3. }; if rows < 0.0 { let rows = rows.ceil().abs() as usize; text.vo = (text.vo + rows).min(text.l() - 1); @@ -745,6 +745,9 @@ pub static BFONT: LazyLock<Instance<'static>> = fn shift() -> bool { unsafe { MODIFIERS }.shift_key() } +fn alt() -> bool { + unsafe { MODIFIERS }.alt_key() +} fn ctrl() -> bool { unsafe { MODIFIERS }.control_key() } |