LibGUI: Fix compiler warnings.

This commit is contained in:
Andreas Kling 2019-06-22 14:41:11 +02:00
commit 3f0f7caa45
Notes: sideshowbarker 2024-07-19 13:31:22 +09:00
6 changed files with 21 additions and 13 deletions

View file

@ -107,7 +107,7 @@ RefPtr<Font> Font::load_from_memory(const byte* data)
size_t bytes_per_glyph = sizeof(unsigned) * header.glyph_height;
auto* rows = (unsigned*)(data + sizeof(FontFileHeader));
auto* rows = const_cast<unsigned*>((const unsigned*)(data + sizeof(FontFileHeader)));
byte* widths = nullptr;
if (header.is_variable_width)
widths = (byte*)(rows) + 256 * bytes_per_glyph;