diff options
Diffstat (limited to 'Userland/Applications/FontEditor/GlyphEditorWidget.cpp')
-rw-r--r-- | Userland/Applications/FontEditor/GlyphEditorWidget.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Userland/Applications/FontEditor/GlyphEditorWidget.cpp b/Userland/Applications/FontEditor/GlyphEditorWidget.cpp index 9a25ed3e71..8844d73113 100644 --- a/Userland/Applications/FontEditor/GlyphEditorWidget.cpp +++ b/Userland/Applications/FontEditor/GlyphEditorWidget.cpp @@ -39,7 +39,7 @@ void GlyphEditorWidget::delete_glyph() { if (on_undo_event) on_undo_event(); - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); for (int x = 0; x < bitmap.width(); x++) for (int y = 0; y < bitmap.height(); y++) bitmap.set_bit_at(x, y, false); @@ -56,7 +56,7 @@ void GlyphEditorWidget::cut_glyph() void GlyphEditorWidget::copy_glyph() { - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); u8 bits[bitmap.width()][bitmap.height()]; for (int x = 0; x < bitmap.width(); x++) { for (int y = 0; y < bitmap.height(); y++) { @@ -105,7 +105,7 @@ void GlyphEditorWidget::paste_glyph() } } - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); for (int x = 0; x < min(bitmap.width(), buffer_width.value()); x++) { for (int y = 0; y < min(bitmap.height(), buffer_height.value()); y++) { if (bits[x][y]) @@ -138,7 +138,7 @@ void GlyphEditorWidget::paint_event(GUI::PaintEvent& event) for (int x = 1; x < font().max_glyph_width(); ++x) painter.draw_line({ x * m_scale, 0 }, { x * m_scale, font().glyph_height() * m_scale }, palette().threed_shadow2()); - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); for (int y = 0; y < font().glyph_height(); ++y) { for (int x = 0; x < font().max_glyph_width(); ++x) { @@ -155,7 +155,7 @@ void GlyphEditorWidget::paint_event(GUI::PaintEvent& event) bool GlyphEditorWidget::is_glyph_empty() { - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); for (int x = 0; x < bitmap.width(); x++) for (int y = 0; y < bitmap.height(); y++) if (bitmap.bit_at(x, y)) @@ -176,7 +176,7 @@ void GlyphEditorWidget::mousedown_event(GUI::MouseEvent& event) draw_at_mouse(event); } else { memset(m_movable_bits, 0, sizeof(m_movable_bits)); - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); for (int x = s_max_width; x < s_max_width + bitmap.width(); x++) for (int y = s_max_height; y < s_max_height + bitmap.height(); y++) m_movable_bits[x][y] = bitmap.bit_at(x - s_max_width, y - s_max_height); @@ -221,7 +221,7 @@ void GlyphEditorWidget::draw_at_mouse(const GUI::MouseEvent& event) return; int x = (event.x() - 1) / m_scale; int y = (event.y() - 1) / m_scale; - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); if (x < 0 || x >= bitmap.width()) return; if (y < 0 || y >= bitmap.height()) @@ -238,7 +238,7 @@ void GlyphEditorWidget::move_at_mouse(const GUI::MouseEvent& event) { int x_delta = ((event.x() - 1) / m_scale) - x_offset; int y_delta = ((event.y() - 1) / m_scale) - y_offset; - auto bitmap = font().glyph(m_glyph).glyph_bitmap(); + auto bitmap = font().raw_glyph(m_glyph).glyph_bitmap(); if (abs(x_delta) > bitmap.width() || abs(y_delta) > bitmap.height()) return; for (int x = 0; x < bitmap.width(); x++) { |