diff options
Diffstat (limited to 'src/canvas')
-rw-r--r-- | src/canvas/widgets/basic_table_arrows.rs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/canvas/widgets/basic_table_arrows.rs b/src/canvas/widgets/basic_table_arrows.rs index bce169e1..d7f79dc6 100644 --- a/src/canvas/widgets/basic_table_arrows.rs +++ b/src/canvas/widgets/basic_table_arrows.rs @@ -139,16 +139,19 @@ impl BasicTableArrows for Painter { ); if app_state.should_get_widget_bounds() { + // The y is +1 as for some reason the height is 2... but we only want a height of 1. if let Some(basic_table) = &mut app_state.basic_table_widget_state { - basic_table.left_tlc = Some((margined_draw_loc[0].x, margined_draw_loc[0].y)); + basic_table.left_tlc = + Some((margined_draw_loc[0].x, margined_draw_loc[0].y + 1)); basic_table.left_brc = Some(( margined_draw_loc[0].x + margined_draw_loc[0].width, - margined_draw_loc[0].y + margined_draw_loc[0].height, + margined_draw_loc[0].y + 1 + margined_draw_loc[0].height, )); - basic_table.right_tlc = Some((margined_draw_loc[2].x, margined_draw_loc[2].y)); + basic_table.right_tlc = + Some((margined_draw_loc[2].x, margined_draw_loc[2].y + 1)); basic_table.right_brc = Some(( margined_draw_loc[2].x + margined_draw_loc[2].width, - margined_draw_loc[2].y + margined_draw_loc[2].height, + margined_draw_loc[2].y + 1 + margined_draw_loc[2].height, )); } } |