28 lines
630 B
C++
28 lines
630 B
C++
#pragma once
|
|
|
|
#include "Display/Graphics/Framebuffer.h"
|
|
#include "Display/UI/Text/FontFace.h"
|
|
#include "Display/UI/Text/GlyphCache.h"
|
|
#include "Display/Graphics/Color.h"
|
|
|
|
#include <string>
|
|
|
|
namespace Display::UI::Text
|
|
{
|
|
|
|
class Renderer
|
|
{
|
|
public:
|
|
Renderer();
|
|
|
|
Renderer(const Renderer &) = delete;
|
|
Renderer &operator=(const Renderer &) = delete;
|
|
|
|
void drawText(Display::Graphics::Framebuffer &fb, int x, int y, const std::string &text, const Display::Graphics::Color &color);
|
|
|
|
private:
|
|
FontFace fontFace;
|
|
GlyphCache glyphCache;
|
|
};
|
|
|
|
} // namespace Display::UI::Text
|