You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Graphics and barcodes export half-dot ^FO/^FT origins #667
Follow-up to #660. As you suggested, the change is attached as a patch (applies with git am on top of 5485f91a).
Problem
Smart snap can leave an object on a half dot. On main, a box at x = 100.5 exports ^FO100.5, while a text field at the same x exports ^FO101, so the two can print one dot apart. Ellipses, lines, images and barcodes do the same.
Proposed change
One helper, wholeDot, rounds every ^FO/^FT origin the way text already does.
Axis-aligned lines go through graphicAnchor, like diagonal ones.
emittedAnchorDots, and the check that drops a field pushed below 0 by ^LH/^LT, use the rounded origin, so preflight and that check agree with what is emitted.
Tests
17 new cases in zplGenerator.test.ts and emittedAnchor.test.ts. They fail on main and pass with the patch. pnpm lint, tsc -b and pnpm test pass.
Activity