LibGfx: Remove unused CharacterBitmap class

This commit is contained in:
Andreas Kling 2024-06-18 14:20:56 +02:00
parent ab56b8c8dc
commit fed4668fb1
Notes: sideshowbarker 2024-07-16 21:30:46 +09:00
3 changed files with 0 additions and 42 deletions

View file

@ -1,40 +0,0 @@
/*
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
* Copyright (c) 2022, the SerenityOS developers.
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include "Size.h"
#include <AK/RefCounted.h>
#include <AK/RefPtr.h>
#include <AK/StringView.h>
namespace Gfx {
class CharacterBitmap {
public:
CharacterBitmap() = delete;
constexpr CharacterBitmap(StringView ascii_data, unsigned width, unsigned height)
: m_bits(ascii_data)
, m_size(width, height)
{
}
constexpr ~CharacterBitmap() = default;
constexpr bool bit_at(unsigned x, unsigned y) const { return m_bits[y * width() + x] == '#'; }
constexpr StringView bits() const { return m_bits; }
constexpr IntSize size() const { return m_size; }
constexpr unsigned width() const { return m_size.width(); }
constexpr unsigned height() const { return m_size.height(); }
private:
StringView m_bits {};
IntSize m_size {};
};
}

View file

@ -11,7 +11,6 @@ namespace Gfx {
class Bitmap;
class CMYKBitmap;
class ImmutableBitmap;
class CharacterBitmap;
class Color;
template<typename T>

View file

@ -25,7 +25,6 @@
#include <AK/StdLibExtras.h>
#include <AK/StringBuilder.h>
#include <AK/Utf8View.h>
#include <LibGfx/CharacterBitmap.h>
#include <LibGfx/Palette.h>
#include <LibGfx/Path.h>
#include <LibGfx/Quad.h>