Fixed line feed in prt_escp.c

Per fix by Patrick-Barry, fixes #4477.
This commit is contained in:
Miran Grča
2024-05-22 15:46:53 +02:00
committed by GitHub
parent 050cb542a5
commit 29ac8fd28b

View File

@@ -1475,7 +1475,7 @@ process_char(escp_t *dev, uint8_t ch)
}
dev->curr_x = dev->left_margin;
dev->curr_y += dev->linespacing;
if (dev->curr_y > dev->bottom_margin)
if ((dev->curr_y + 0.0001f) > dev->bottom_margin)
new_page(dev, 1, 0);
return 1;