Fix: Right Edge of G-code Viewer Legend Rows Not Interactive (#11899)

Fix legend hover hit-testing

Fix GCode viewer legend where the eye icon and right edge don’t respond to hover/click unless you click slightly left (works after switching view types unless the vertical slide is used).
This commit is contained in:
Kiss Lorand
2026-05-14 19:46:05 +03:00
committed by GitHub
parent d2ca5d3a1e
commit 700292f9a6
3 changed files with 49 additions and 28 deletions

View File

@@ -33,7 +33,8 @@ class OpenGLManager;
static const float GCODE_VIEWER_SLIDER_SCALE = 0.6f;
static const float SLIDER_DEFAULT_RIGHT_MARGIN = 10.0f;
static const float SLIDER_DEFAULT_BOTTOM_MARGIN = 10.0f;
static const float SLIDER_RIGHT_MARGIN = 124.0f;
// ORCA: match right margin to the vertical slider window width to prevent overlap.
static inline const float SLIDER_RIGHT_MARGIN = IMSlider::vertical_slider_window_width();
static const float SLIDER_BOTTOM_MARGIN = 64.0f;
class GCodeViewer
{