Flutter Engine
minikin::Layout Class Reference

#include <Layout.h>

Public Member Functions

 Layout ()
 
 Layout (Layout &&layout)=default
 
 Layout (const Layout &)=delete
 
void operator= (const Layout &)=delete
 
void dump () const
 
void doLayout (const uint16_t *buf, size_t start, size_t count, size_t bufSize, bool isRtl, const FontStyle &style, const MinikinPaint &paint, const std::shared_ptr< FontCollection > &collection)
 
size_t nGlyphs () const
 
const MinikinFontgetFont (int i) const
 
FontFakery getFakery (int i) const
 
unsigned int getGlyphId (int i) const
 
uint32_t getGlyphCluster (int i) const
 
float getX (int i) const
 
float getY (int i) const
 
float getAdvance () const
 
void getAdvances (float *advances)
 
float getCharAdvance (size_t i) const
 
void getBounds (MinikinRect *rect) const
 

Static Public Member Functions

static float measureText (const uint16_t *buf, size_t start, size_t count, size_t bufSize, bool isRtl, const FontStyle &style, const MinikinPaint &paint, const std::shared_ptr< FontCollection > &collection, float *advances)
 
static void purgeCaches ()
 

Friends

class LayoutCacheKey
 

Detailed Description

Definition at line 63 of file Layout.h.

Constructor & Destructor Documentation

◆ Layout() [1/3]

minikin::Layout::Layout ( )
inline

Definition at line 65 of file Layout.h.

65  : mGlyphs(), mAdvances(), mFaces(), mAdvance(0), mBounds() {
66  mBounds.setEmpty();
67  }

◆ Layout() [2/3]

minikin::Layout::Layout ( Layout &&  layout)
default

◆ Layout() [3/3]

minikin::Layout::Layout ( const Layout )
delete

Member Function Documentation

◆ doLayout()

void minikin::Layout::doLayout ( const uint16_t *  buf,
size_t  start,
size_t  count,
size_t  bufSize,
bool  isRtl,
const FontStyle style,
const MinikinPaint paint,
const std::shared_ptr< FontCollection > &  collection 
)

◆ dump()

void minikin::Layout::dump ( ) const

◆ getAdvance()

float minikin::Layout::getAdvance ( ) const

◆ getAdvances()

void minikin::Layout::getAdvances ( float *  advances)

◆ getBounds()

void minikin::Layout::getBounds ( MinikinRect rect) const

◆ getCharAdvance()

float minikin::Layout::getCharAdvance ( size_t  i) const
inline

Definition at line 113 of file Layout.h.

Referenced by txt::ParagraphTxt::Layout().

113 { return mAdvances[i]; }

◆ getFakery()

FontFakery minikin::Layout::getFakery ( int  i) const

◆ getFont()

const MinikinFont* minikin::Layout::getFont ( int  i) const

◆ getGlyphCluster()

uint32_t minikin::Layout::getGlyphCluster ( int  i) const

◆ getGlyphId()

unsigned int minikin::Layout::getGlyphId ( int  i) const

◆ getX()

float minikin::Layout::getX ( int  i) const

◆ getY()

float minikin::Layout::getY ( int  i) const

◆ measureText()

static float minikin::Layout::measureText ( const uint16_t *  buf,
size_t  start,
size_t  count,
size_t  bufSize,
bool  isRtl,
const FontStyle style,
const MinikinPaint paint,
const std::shared_ptr< FontCollection > &  collection,
float *  advances 
)
static

◆ nGlyphs()

size_t minikin::Layout::nGlyphs ( ) const

◆ operator=()

void minikin::Layout::operator= ( const Layout )
delete

◆ purgeCaches()

static void minikin::Layout::purgeCaches ( )
static

Friends And Related Function Documentation

◆ LayoutCacheKey

friend class LayoutCacheKey
friend

Definition at line 121 of file Layout.h.


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