/* * Copyright 2006 The Android Open Source Project * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file.
*/
class SkData; class SkFontDescriptor; class SkStreamAsset; class SkTypeface;
/** The base SkTypeface implementation for the custom font manager. */ class SkTypeface_Custom : public SkTypeface_FreeType { public:
SkTypeface_Custom(const SkFontStyle& style, bool isFixedPitch, bool sysFont, SkString familyName, int index); bool isSysFont() const;
/** The empty SkTypeface implementation for the custom font manager. * Used as the last resort fallback typeface.
*/ class SkTypeface_Empty : public SkTypeface_Custom { public:
SkTypeface_Empty() ;
/** The file SkTypeface implementation for the custom font manager. */ class SkTypeface_File : public SkTypeface_Custom { public:
SkTypeface_File(const SkFontStyle& style, bool isFixedPitch, bool sysFont,
SkString familyName, constchar path[], int index);
/** * SkFontStyleSet_Custom * * This class is used by SkFontMgr_Custom to hold SkTypeface_Custom families.
*/ class SkFontStyleSet_Custom : public SkFontStyleSet { public: explicit SkFontStyleSet_Custom(SkString familyName);
/** Should only be called during the initial build phase. */ void appendTypeface(sk_sp<SkTypeface> typeface); int count() override; void getStyle(int index, SkFontStyle* style, SkString* name) override;
sk_sp<SkTypeface> createTypeface(int index) override;
sk_sp<SkTypeface> matchStyle(const SkFontStyle& pattern) override;
SkString getFamilyName();
/** * SkFontMgr_Custom * * This class is essentially a collection of SkFontStyleSet_Custom, * one SkFontStyleSet_Custom for each family. This class may be modified * to load fonts from any source by changing the initialization.
*/ class SkFontMgr_Custom : public SkFontMgr { public: typedef skia_private::TArray<sk_sp<SkFontStyleSet_Custom>> Families; class SystemFontLoader { public: virtual ~SystemFontLoader() { } virtualvoid loadSystemFonts(const SkFontScanner*, Families*) const = 0;
}; explicit SkFontMgr_Custom(const SystemFontLoader& loader);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.