diff --git a/src/canvas.rs b/src/canvas.rs index 3a3549a2..4a834ae4 100644 --- a/src/canvas.rs +++ b/src/canvas.rs @@ -333,9 +333,9 @@ impl Painter { ] } else { [ - Constraint::Percentage(20), - Constraint::Percentage(60), - Constraint::Percentage(20), + Constraint::Percentage(15), + Constraint::Percentage(70), + Constraint::Percentage(15), ] }) .split(vertical_dialog_chunk[1]); diff --git a/src/canvas/dialogs/help_dialog.rs b/src/canvas/dialogs/help_dialog.rs index b125e73f..c315bc8c 100644 --- a/src/canvas/dialogs/help_dialog.rs +++ b/src/canvas/dialogs/help_dialog.rs @@ -1,4 +1,4 @@ -use std::cmp::max; +use std::cmp::{max, min}; use unicode_width::UnicodeWidthStr; @@ -88,7 +88,7 @@ impl Painter { .scroll_state .current_scroll_index; - *index = max(*index, *max_scroll_index); + *index = min(*index, *max_scroll_index); } f.render_widget( diff --git a/src/constants.rs b/src/constants.rs index a10b766b..0d073423 100644 --- a/src/constants.rs +++ b/src/constants.rs @@ -219,7 +219,7 @@ pub static NORD_LIGHT_COLOUR_PALETTE: Lazy = Lazy::new(|| ConfigC // Help text pub const HELP_CONTENTS_TEXT: [&str; 8] = [ - "Press the corresponding numbers to jump to the section, or scroll:", + "Either scroll or press the number key to go to the corresponding help menu section:", "1 - General", "2 - CPU widget", "3 - Process widget",