Correlation 4.10.0
An Analysis Tool for Liquids and for Amorphous Solids
Loading...
Searching...
No Matches
correlation::plotters::Roboto Class Reference

High-fidelity Roboto vector font implementation. More...

#include <PathFont.hpp>

Public Member Functions

std::string render (TextRenderParameters const &params)
 Renders a string of text as SVG path data using parameters struct.

Static Public Member Functions

static Roboto & instance ()

Private Member Functions

 Roboto ()
void add (GlyphParameters const &params)
void add (uint32_t code_point, real_t left_bearing, real_t right_bearing, std::span< const Point2D > points, std::span< const size_t > stroke_lengths)
void registerBasic1 ()
void registerBasic2 ()
void registerExtended ()

Static Private Member Functions

static std::vector< uint32_t > utf8ToUnicode (const std::string &utf8_string)

Private Attributes

std::map< uint32_t, Glyph > glyphs_
 Local storage for character glyph data.

Detailed Description

High-fidelity Roboto vector font implementation.

Constructor & Destructor Documentation

◆ Roboto()

correlation::plotters::Roboto::Roboto ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ add() [1/2]

void correlation::plotters::Roboto::add ( GlyphParameters const & params)
private
Here is the caller graph for this function:

◆ add() [2/2]

void correlation::plotters::Roboto::add ( uint32_t code_point,
real_t left_bearing,
real_t right_bearing,
std::span< const Point2D > points,
std::span< const size_t > stroke_lengths )
private
Here is the call graph for this function:

◆ instance()

Roboto & correlation::plotters::Roboto::instance ( )
static
Returns
Singleton instance of the Roboto font.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ registerBasic1()

void correlation::plotters::Roboto::registerBasic1 ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ registerBasic2()

void correlation::plotters::Roboto::registerBasic2 ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ registerExtended()

void correlation::plotters::Roboto::registerExtended ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ render()

std::string correlation::plotters::Roboto::render ( TextRenderParameters const & params)

Renders a string of text as SVG path data using parameters struct.

Parameters
paramsRendering options including text, coordinates, font size, and text anchor.
Returns
A string containing SVG path instructions (M/L/Z commands).
Here is the call graph for this function:
Here is the caller graph for this function:

◆ utf8ToUnicode()

std::vector< uint32_t > correlation::plotters::Roboto::utf8ToUnicode ( const std::string & utf8_string)
staticprivate
Here is the caller graph for this function:

Member Data Documentation

◆ glyphs_

std::map<uint32_t, Glyph> correlation::plotters::Roboto::glyphs_
private

Local storage for character glyph data.


The documentation for this class was generated from the following files: