Fix stale hover latch on drag release, tooltip anchor, border off-by-one; pin gutter golden test, drop DPI framing
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
// keyboard_strip.h — piano-keyboard geometry for the editor's root strip: per-class key
|
||||
// rects, hit-test, the root marker, and the note name a hovered key reports.
|
||||
//
|
||||
// Same-class keys are one integer width by construction. An arbitrary band width is not
|
||||
// divisible by the 75 white keys, so the residue lands in symmetric end margins — uniform
|
||||
// key widths and gap-free edge-to-edge tiling cannot both hold, and uniformity wins.
|
||||
// See src/core/instrument/CLAUDE.md for the uniform-width-vs-edge-to-edge-tiling tradeoff.
|
||||
|
||||
#pragma once
|
||||
|
||||
@@ -21,7 +19,8 @@ inline constexpr int kStripKeyCount = 128;
|
||||
inline constexpr int kStripWhiteKeyCount = 75;
|
||||
|
||||
struct StripLayout {
|
||||
Rect band; // the surface handed in, edge to edge
|
||||
Rect band; // the surface handed in, edge to edge (no src/ consumer; kept as the tests'
|
||||
// reference bound instead of recomputing Rect::ltrb(0, 0, w, h) at each call site)
|
||||
Rect keys; // the tiled key area, kStripWhiteKeyCount * whiteWidth, centred in band
|
||||
int whiteWidth = 0;
|
||||
int blackWidth = 0;
|
||||
|
||||
Reference in New Issue
Block a user