Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
skottie::Shaper::Result Struct Reference

#include <TextShaper.h>

Public Member Functions

SkRect computeVisualBounds () const
 

Public Attributes

std::vector< FragmentfFragments
 
size_t fMissingGlyphCount = 0
 
float fScale = 1.0f
 

Detailed Description

Definition at line 78 of file TextShaper.h.

Member Function Documentation

◆ computeVisualBounds()

SkRect skottie::Shaper::Result::computeVisualBounds ( ) const

Definition at line 736 of file TextShaper.cpp.

736 {
737 auto bounds = SkRect::MakeEmpty();
738
739 for (const auto& frag: fFragments) {
740 bounds.join(frag.fGlyphs.computeBounds(ShapedGlyphs::BoundsType::kTight)
741 .makeOffset(frag.fOrigin));
742 }
743
744 return bounds;
745}
Optional< SkRect > bounds
Definition SkRecords.h:189
static constexpr SkRect MakeEmpty()
Definition SkRect.h:595
std::vector< Fragment > fFragments
Definition TextShaper.h:79

Member Data Documentation

◆ fFragments

std::vector<Fragment> skottie::Shaper::Result::fFragments

Definition at line 79 of file TextShaper.h.

◆ fMissingGlyphCount

size_t skottie::Shaper::Result::fMissingGlyphCount = 0

Definition at line 80 of file TextShaper.h.

◆ fScale

float skottie::Shaper::Result::fScale = 1.0f

Definition at line 84 of file TextShaper.h.


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