mirror of
https://github.com/QB64-Phoenix-Edition/QB64pe.git
synced 2024-07-09 10:45:13 +00:00
Currently there is a bug where if a variable width font is in use and text printed would exactly fit to the end of the row, it is instead wrapped and printed on the next line. Ex. You're printing a character that is 10 pixels wide, starting from position 90 on an image that is 100 pixels wide. This should fix, but instead your character will be printed on the next line. The reason this happens is an off by one error, cursor_x (effectively the X value passed to LOCATE) is one based even when using a variable width font where cursor_x represents a pixel location. The location that check if the next character can fit on the screen never handles the base one, so it ends up treating the ending Y coordinate as one past where it will actually end, which makes the code thing the print will go past the edge of the screen. To fix we simply subtract one before doing the comparison to give us the actual ending pixel column. |
||
---|---|---|
.. | ||
c | ||
help | ||
source | ||
support | ||
temp | ||
clean.bat |