Review thread on src/LHDocument.mm line 53
width = std::ceil(natural + 0.01);
RS
Rin Sato ยท 16:05

Why + 0.01? Feels like a magic number ๐Ÿค” If natural is already integral we add a whole pixel after ceil.

๐Ÿ‘€ 2๐Ÿค” 1
LP
Leo Park ยท 16:07

Float noise: natural comes back as e.g. 212.99998, and rendering at exactly that width wraps the last word. The epsilon only matters in that case โ€” ceil(213.0 + 0.01) is 214, you're right, I'll use ceil(natural - 0.001) + a comment.

๐Ÿ‘ 3๐ŸŽฏ 1
RS
Rin Sato ยท 16:08

Perfect, thanks! Approving once that lands โœ…

RESOLVEDReply