1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-26 17:55:19 +03:00

Fix for TINSIZE | BOLD. If called, BOLD is discarded (#3610)

This commit is contained in:
3djc 2016-06-18 22:15:28 +02:00 committed by Bertrand Songis
parent dad37f36ba
commit ab58151f2a

View file

@ -311,6 +311,8 @@ void BitmapBuffer::drawSizedText(coord_t x, coord_t y, const char * s, uint8_t l
#define INCREMENT_POS(delta) \
do { if (flags & VERTICAL) y -= delta; else x += delta; } while(0)
if ((flags & TINSIZE) && (flags & BOLD)) flags &= ~(BOLD); //TINSIZE | BOLD segfault, so preventing it
int width = getTextWidth(s, len, flags);
int height = getFontHeight(flags);
int fontindex = FONTSIZE(flags) >> 8;