Skip to content

Commit

Permalink
Fix #2793
Browse files Browse the repository at this point in the history
  • Loading branch information
Bodmer committed Aug 18, 2023
1 parent 5c1f163 commit caa1076
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Extensions/Sprite.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1985,10 +1985,6 @@ void TFT_eSprite::drawChar(int32_t x, int32_t y, uint16_t c, uint32_t color, uin
{
if ( _vpOoB || !_created ) return;

if ((x >= _vpW - _xDatum) || // Clip right
(y >= _vpH - _yDatum)) // Clip bottom
return;

if (c < 32) return;
#ifdef LOAD_GLCD
//>>>>>>>>>>>>>>>>>>
Expand All @@ -1997,6 +1993,10 @@ void TFT_eSprite::drawChar(int32_t x, int32_t y, uint16_t c, uint32_t color, uin
#endif
//>>>>>>>>>>>>>>>>>>

if ((x >= _vpW - _xDatum) || // Clip right
(y >= _vpH - _yDatum)) // Clip bottom
return;

if (((x + 6 * size - 1) < (_vpX - _xDatum)) || // Clip left
((y + 8 * size - 1) < (_vpY - _yDatum))) // Clip top
return;
Expand Down

0 comments on commit caa1076

Please sign in to comment.