Flutter Engine
minikin::FontFamily Class Reference

#include <FontFamily.h>

Public Member Functions

 FontFamily (std::vector< Font > &&fonts)
 
 FontFamily (int variant, std::vector< Font > &&fonts)
 
 FontFamily (uint32_t langId, int variant, std::vector< Font > &&fonts)
 
FakedFont getClosestMatch (FontStyle style) const
 
uint32_t langId () const
 
int variant () const
 
size_t getNumFonts () const
 
const std::shared_ptr< MinikinFont > & getFont (size_t index) const
 
FontStyle getStyle (size_t index) const
 
bool isColorEmojiFamily () const
 
const std::unordered_set< AxisTag > & supportedAxes () const
 
const SparseBitSetgetCoverage () const
 
bool hasGlyph (uint32_t codepoint, uint32_t variationSelector) const
 
bool hasVSTable () const
 
std::shared_ptr< FontFamilycreateFamilyWithVariation (const std::vector< FontVariation > &variations) const
 

Static Public Member Functions

static bool analyzeStyle (const std::shared_ptr< MinikinFont > &typeface, int *weight, bool *italic)
 

Detailed Description

Definition at line 133 of file FontFamily.h.

Constructor & Destructor Documentation

◆ FontFamily() [1/3]

minikin::FontFamily::FontFamily ( std::vector< Font > &&  fonts)
explicit

◆ FontFamily() [2/3]

minikin::FontFamily::FontFamily ( int  variant,
std::vector< Font > &&  fonts 
)

◆ FontFamily() [3/3]

minikin::FontFamily::FontFamily ( uint32_t  langId,
int  variant,
std::vector< Font > &&  fonts 
)

Member Function Documentation

◆ analyzeStyle()

static bool minikin::FontFamily::analyzeStyle ( const std::shared_ptr< MinikinFont > &  typeface,
int *  weight,
bool *  italic 
)
static

◆ createFamilyWithVariation()

std::shared_ptr<FontFamily> minikin::FontFamily::createFamilyWithVariation ( const std::vector< FontVariation > &  variations) const

◆ getClosestMatch()

FakedFont minikin::FontFamily::getClosestMatch ( FontStyle  style) const

◆ getCoverage()

const SparseBitSet& minikin::FontFamily::getCoverage ( ) const
inline

Definition at line 161 of file FontFamily.h.

161 { return mCoverage; }

◆ getFont()

const std::shared_ptr<MinikinFont>& minikin::FontFamily::getFont ( size_t  index) const
inline

Definition at line 151 of file FontFamily.h.

151  {
152  return mFonts[index].typeface;
153  }

◆ getNumFonts()

size_t minikin::FontFamily::getNumFonts ( ) const
inline

Definition at line 150 of file FontFamily.h.

150 { return mFonts.size(); }

◆ getStyle()

FontStyle minikin::FontFamily::getStyle ( size_t  index) const
inline

Definition at line 154 of file FontFamily.h.

154 { return mFonts[index].style; }

◆ hasGlyph()

bool minikin::FontFamily::hasGlyph ( uint32_t  codepoint,
uint32_t  variationSelector 
) const

◆ hasVSTable()

bool minikin::FontFamily::hasVSTable ( ) const
inline

Definition at line 169 of file FontFamily.h.

169 { return mHasVSTable; }

◆ isColorEmojiFamily()

bool minikin::FontFamily::isColorEmojiFamily ( ) const

◆ langId()

uint32_t minikin::FontFamily::langId ( ) const
inline

Definition at line 145 of file FontFamily.h.

145 { return mLangId; }

◆ supportedAxes()

const std::unordered_set<AxisTag>& minikin::FontFamily::supportedAxes ( ) const
inline

Definition at line 156 of file FontFamily.h.

156  {
157  return mSupportedAxes;
158  }

◆ variant()

int minikin::FontFamily::variant ( ) const
inline

Definition at line 146 of file FontFamily.h.

146 { return mVariant; }

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