Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Member Functions | Friends | List of all members
SkTypefaceProxyPrototype Class Reference

#include <SkTypeface_remote.h>

Public Member Functions

 SkTypefaceProxyPrototype (const SkTypeface &typeface)
 
 SkTypefaceProxyPrototype (SkTypefaceID typefaceID, int glyphCount, int32_t styleValue, bool isFixedPitch, bool glyphMaskNeedsCurrentColor)
 
void flatten (SkWriteBuffer &buffer) const
 
SkTypefaceID serverTypefaceID () const
 

Static Public Member Functions

static std::optional< SkTypefaceProxyPrototypeMakeFromBuffer (SkReadBuffer &buffer)
 

Friends

class SkTypefaceProxy
 

Detailed Description

Definition at line 60 of file SkTypeface_remote.h.

Constructor & Destructor Documentation

◆ SkTypefaceProxyPrototype() [1/2]

SkTypefaceProxyPrototype::SkTypefaceProxyPrototype ( const SkTypeface typeface)
explicit

Definition at line 112 of file SkTypeface_remote.cpp.

113 : fServerTypefaceID{typeface.uniqueID()}
114 , fGlyphCount{typeface.countGlyphs()}
115 , fStyleValue{typeface.fontStyle().fValue}
116 , fIsFixedPitch{typeface.isFixedPitch()}
117 , fGlyphMaskNeedsCurrentColor{typeface.glyphMaskNeedsCurrentColor()} {}
int countGlyphs() const
Definition: SkTypeface.cpp:432
SkTypefaceID uniqueID() const
Definition: SkTypeface.h:101
SkFontStyle fontStyle() const
Definition: SkTypeface.h:55
bool isFixedPitch() const
Definition: SkTypeface.h:68

◆ SkTypefaceProxyPrototype() [2/2]

SkTypefaceProxyPrototype::SkTypefaceProxyPrototype ( SkTypefaceID  typefaceID,
int  glyphCount,
int32_t  styleValue,
bool  isFixedPitch,
bool  glyphMaskNeedsCurrentColor 
)

Definition at line 119 of file SkTypeface_remote.cpp.

122 : fServerTypefaceID {typefaceID}
123 , fGlyphCount{glyphCount}
124 , fStyleValue{styleValue}
125 , fIsFixedPitch{isFixedPitch}
126 , fGlyphMaskNeedsCurrentColor{glyphMaskNeedsCurrentColor} {}

Member Function Documentation

◆ flatten()

void SkTypefaceProxyPrototype::flatten ( SkWriteBuffer buffer) const

Definition at line 128 of file SkTypeface_remote.cpp.

128 {
129 buffer.writeUInt(fServerTypefaceID);
130 buffer.writeInt(fGlyphCount);
131 buffer.write32(fStyleValue);
132 buffer.writeBool(fIsFixedPitch);
133 buffer.writeBool(fGlyphMaskNeedsCurrentColor);
134}
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
Definition: switches.h:126

◆ MakeFromBuffer()

std::optional< SkTypefaceProxyPrototype > SkTypefaceProxyPrototype::MakeFromBuffer ( SkReadBuffer buffer)
static

Definition at line 96 of file SkTypeface_remote.cpp.

96 {
97 SkASSERT(buffer.isValid());
98 const SkTypefaceID typefaceID = buffer.readUInt();
99 const int glyphCount = buffer.readInt();
100 const int32_t styleValue = buffer.read32();
101 const bool isFixedPitch = buffer.readBool();
102 const bool glyphMaskNeedsCurrentColor = buffer.readBool();
103
104 if (buffer.isValid()) {
106 typefaceID, glyphCount, styleValue, isFixedPitch, glyphMaskNeedsCurrentColor};
107 }
108
109 return std::nullopt;
110}
#define SkASSERT(cond)
Definition: SkAssert.h:116
uint32_t SkTypefaceID
Definition: SkTypeface.h:38

◆ serverTypefaceID()

SkTypefaceID SkTypefaceProxyPrototype::serverTypefaceID ( ) const
inline

Definition at line 71 of file SkTypeface_remote.h.

71{ return fServerTypefaceID; }

Friends And Related Function Documentation

◆ SkTypefaceProxy

friend class SkTypefaceProxy
friend

Definition at line 74 of file SkTypeface_remote.h.


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