Flutter Engine
The Flutter Engine
Classes | Functions
SkFontMgr_FontConfigInterface.cpp File Reference
#include "include/core/SkFontMgr.h"
#include "include/core/SkFontStyle.h"
#include "include/core/SkString.h"
#include "include/core/SkTypeface.h"
#include "include/ports/SkFontConfigInterface.h"
#include "include/ports/SkFontMgr_FontConfigInterface.h"
#include "include/private/base/SkMutex.h"
#include "src/core/SkFontDescriptor.h"
#include "src/core/SkResourceCache.h"
#include "src/core/SkTypefaceCache.h"
#include "src/ports/SkFontConfigTypeface.h"
#include "src/ports/SkTypeface_FreeType.h"
#include <new>

Go to the source code of this file.

Classes

class  SkFontStyleSet_FCI
 
class  SkFontRequestCache
 
struct  SkFontRequestCache::Request
 
class  SkFontMgr_FCI
 

Functions

static bool find_by_FontIdentity (SkTypeface *cachedTypeface, void *ctx)
 
SK_API sk_sp< SkFontMgrSkFontMgr_New_FCI (sk_sp< SkFontConfigInterface > fci)
 

Function Documentation

◆ find_by_FontIdentity()

static bool find_by_FontIdentity ( SkTypeface cachedTypeface,
void *  ctx 
)
static

Definition at line 135 of file SkFontMgr_FontConfigInterface.cpp.

135 {
136 typedef SkFontConfigInterface::FontIdentity FontIdentity;
137 SkTypeface_FCI* cachedFCTypeface = static_cast<SkTypeface_FCI*>(cachedTypeface);
138 FontIdentity* identity = static_cast<FontIdentity*>(ctx);
139
140 return cachedFCTypeface->getIdentity() == *identity;
141}
const SkFontConfigInterface::FontIdentity & getIdentity() const

◆ SkFontMgr_New_FCI()

SK_API sk_sp< SkFontMgr > SkFontMgr_New_FCI ( sk_sp< SkFontConfigInterface fci)

Creates a SkFontMgr which wraps a SkFontConfigInterface.

Definition at line 256 of file SkFontMgr_FontConfigInterface.cpp.

256 {
257 SkASSERT(fci);
258 return sk_make_sp<SkFontMgr_FCI>(std::move(fci));
259}
#define SkASSERT(cond)
Definition: SkAssert.h:116