MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / loadAync

Method loadAync

Source/Cache/FontCache.cpp:242–252  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

240}
241
242void FontCache::loadAync(String fontStr, const std::function<void(Font* fontHandle)>& callback) {
243 std::string fontName;
244 int fontSize = 0;
245 bool sdf = false;
246 std::tie(fontName, fontSize, sdf) = getArgsFromStr(fontStr);
247 if (fontName.empty()) {
248 callback(nullptr);
249 return;
250 }
251 loadAync(fontName, fontSize, sdf, callback);
252}
253
254void FontCache::loadAync(String fontName, uint32_t fontSize, bool sdf, const std::function<void(Font* fontHandle)>& callback) {
255 auto name = Path::getName(fontName);

Callers 1

loadAsyncMethod · 0.80

Calls 15

MakeOwnArrayFunction · 0.85
getFullPathMethod · 0.80
createFontByPixelSizeMethod · 0.80
loadAsyncUnsafeMethod · 0.80
createTtfMethod · 0.80
findMethod · 0.65
toStringMethod · 0.65
existMethod · 0.65
getMethod · 0.65
getNameFunction · 0.50
formatFunction · 0.50
ErrorEnum · 0.50

Tested by

no test coverage detected