Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | List of all members
skia::textlayout::FontCollection::FamilyKey::Hasher Struct Reference

#include <FontCollection.h>

Public Member Functions

size_t operator() (const FamilyKey &key) const
 

Detailed Description

Definition at line 68 of file FontCollection.h.

Member Function Documentation

◆ operator()()

size_t skia::textlayout::FontCollection::FamilyKey::Hasher::operator() ( const FamilyKey &  key) const

Definition at line 25 of file FontCollection.cpp.

25 {
26 size_t hash = 0;
27 for (const SkString& family : key.fFamilyNames) {
28 hash ^= std::hash<std::string>()(family.c_str());
29 }
30 return hash ^
31 std::hash<uint32_t>()(key.fFontStyle.weight()) ^
32 std::hash<uint32_t>()(key.fFontStyle.slant()) ^
33 std::hash<std::optional<FontArguments>>()(key.fFontArguments);
34}
static uint32_t hash(const SkShaderBase::GradientInfo &v)

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