Formatting.

This commit is contained in:
Jeff Young 2022-01-11 14:34:16 +00:00
parent 8f7d2dd06a
commit 33338aa0f2
1 changed files with 22 additions and 23 deletions

View File

@ -37,14 +37,13 @@ namespace KIGFX {
const FONT_GLYPH_TYPE* LookupGlyph( unsigned int aCodepoint ) const FONT_GLYPH_TYPE* LookupGlyph( unsigned int aCodepoint )
{ {
#ifdef BITMAP_FONT_USE_SPANS #ifdef BITMAP_FONT_USE_SPANS
auto *end = font_codepoint_spans auto *end = font_codepoint_spans + sizeof( font_codepoint_spans ) / sizeof(FONT_SPAN_TYPE);
+ sizeof( font_codepoint_spans ) / sizeof(FONT_SPAN_TYPE);
auto ptr = std::upper_bound( font_codepoint_spans, end, aCodepoint, auto ptr = std::upper_bound( font_codepoint_spans, end, aCodepoint,
[]( unsigned int codepoint, const FONT_SPAN_TYPE& span ) []( unsigned int codepoint, const FONT_SPAN_TYPE& span )
{ {
return codepoint < span.end; return codepoint < span.end;
} } );
);
if( ptr != end && ptr->start <= aCodepoint ) if( ptr != end && ptr->start <= aCodepoint )
{ {