5#ifndef INCLUDE_FIFECHAN_FONT_HPP_
6#define INCLUDE_FIFECHAN_FONT_HPP_
10#include "fifechan/platform.hpp"
23 class FIFEGUI_API Font
26 virtual ~Font() =
default;
28 Font(Font
const &) =
default;
29 Font& operator=(Font
const &) =
default;
30 Font(Font&&) =
default;
31 Font& operator=(Font&&) =
default;
40 virtual int getWidth(std::string
const & text)
const = 0;
virtual int getWidth(std::string const &text) const =0
Gets the width of a string.
virtual int getHeight() const =0
Gets the height of the glyphs in the font.
virtual void drawString(Graphics *graphics, std::string const &text, int x, int y)=0
Draws a string.
virtual int getStringIndexAt(std::string const &text, int x) const
Gets a string index in a string providing an x coordinate.
Abstract interface providing primitive drawing functions (lines, rectangles, etc.).