270 Row(
unsigned int rowTop,
unsigned int rowHeight) : width(0), top(rowTop), height(rowHeight) {}
280 typedef std::map<Uint32, Glyph> GlyphTable;
292 unsigned int nextRow;
293 std::vector<Row> rows;
312 Glyph loadGlyph(Uint32 codePoint,
unsigned int characterSize,
bool bold)
const;
324 IntRect findGlyphRect(Page& page,
unsigned int width,
unsigned int height)
const;
334 bool setCurrentSize(
unsigned int characterSize)
const;
339 typedef std::map<unsigned int, Page> PageTable;
349 mutable PageTable m_pages;
350 mutable std::vector<Uint8> m_pixelBuffer;
351 #ifdef SFML_SYSTEM_ANDROID
#define SFML_GRAPHICS_API
const Glyph & getGlyph(Uint32 codePoint, unsigned int characterSize, bool bold) const
Retrieve a glyph of the font.
float getLineSpacing(unsigned int characterSize) const
Get the line spacing.
Font()
Default constructor.
float getKerning(Uint32 first, Uint32 second, unsigned int characterSize) const
Get the kerning offset of two glyphs.
const Texture & getTexture(unsigned int characterSize) const
Retrieve the texture containing the loaded glyphs of a certain size.
float getUnderlinePosition(unsigned int characterSize) const
Get the position of the underline.
Font(const Font ©)
Copy constructor.
const Info & getInfo() const
Get the font information.
bool loadFromFile(const std::string &filename)
Load the font from a file.
bool loadFromStream(InputStream &stream)
Load the font from a custom stream.
bool loadFromMemory(const void *data, std::size_t sizeInBytes)
Load the font from a file in memory.
float getUnderlineThickness(unsigned int characterSize) const
Get the thickness of the underline.
Structure describing a glyph.
Image living on the graphics card that can be used for drawing.
Holds various information about a font.
std::string family
The font family.