class ffw::GuiFontFineGraphics

Class List > ffw :: GuiFontFineGraphics

Inherits the following classes: ffw::GuiFont

Public Functions

Type Name
GuiFontFineGraphics (GLCanvas & canvas, const std::string & path, const float size)
virtual ~GuiFontFineGraphics () = default
virtual bool isCreated () override const
virtual void destroy () override
virtual ffw::Pointf getStringSize (const std::string & str, const float maxWidth, const float lineHeight) override const
virtual float getEmptyLineHeight (const float lineHeight) override const
virtual float getCharAdvance (unsigned int c) override const
Returns the advance of the codepoint.
virtual std::vector< Chunk > splitString (const std::string & str, const float maxWidth, const float lineHeight) override const
virtual size_t getCharIndex (const std::string::value_type * str, const size_t len, const Pointf & pos, float * x) override const
virtual float getCharPos (const std::string::value_type * str, const size_t len, const size_t index) override const
float getSize () const
const GLCanvas::Font & getCanvasFont () const

Public Functions Documentation

function GuiFontFineGraphics

ffw::GuiFontFineGraphics::GuiFontFineGraphics (
    GLCanvas & canvas,
    const std::string & path,
    const float size
)

function ~GuiFontFineGraphics

virtual ffw::GuiFontFineGraphics::~GuiFontFineGraphics () = default

function isCreated

virtual bool ffw::GuiFontFineGraphics::isCreated () const

Implements GuiFont::isCreated

function destroy

virtual void ffw::GuiFontFineGraphics::destroy ()

Implements GuiFont::destroy

function getStringSize

virtual ffw::Pointf ffw::GuiFontFineGraphics::getStringSize (
    const std::string & str,
    const float maxWidth,
    const float lineHeight
) const

Implements GuiFont::getStringSize

function getEmptyLineHeight

virtual float ffw::GuiFontFineGraphics::getEmptyLineHeight (
    const float lineHeight
) const

Implements GuiFont::getEmptyLineHeight

function getCharAdvance

virtual float ffw::GuiFontFineGraphics::getCharAdvance (
    unsigned int c
) const

Returns the advance of the codepoint.

Note:

This method is not needed if you use your custom implementation of splitString(), getCharIndex(), and getCharPos(). The default implementations use GuiTextWrapper class which uses this method.

Implements GuiFont::getCharAdvance

function splitString

virtual std::vector< Chunk > ffw::GuiFontFineGraphics::splitString (
    const std::string & str,
    const float maxWidth,
    const float lineHeight
) const

Implements GuiFont::splitString

function getCharIndex

virtual size_t ffw::GuiFontFineGraphics::getCharIndex (
    const std::string::value_type * str,
    const size_t len,
    const Pointf & pos,
    float * x
) const

Implements GuiFont::getCharIndex

function getCharPos

virtual float ffw::GuiFontFineGraphics::getCharPos (
    const std::string::value_type * str,
    const size_t len,
    const size_t index
) const

Implements GuiFont::getCharPos

function getSize

float ffw::GuiFontFineGraphics::getSize () const

function getCanvasFont

const GLCanvas::Font & ffw::GuiFontFineGraphics::getCanvasFont () const

The documentation for this class was generated from the following file: include/ffw/gui/backend/guibackendfinegraphics.h