class TextRunWalker {
422 public:
423
494 private:
512 const Font* const m_font;
513 HB_ShaperItem m_item;
514 uint16_t* m_glyphs16;
515 SkPoint* m_positions;
516 ssize_t m_indexOfNextScriptRun;
517 const int m_startingX;
518 const int m_startingY;
519 int m_offsetX;
520 unsigned m_pixelWidth;
521 unsigned m_numCodePoints;
522 unsigned m_glyphsArrayCapacity;
523
524 OwnPtr<TextRun> m_normalizedRun;
525 OwnArrayPtr<UChar> m_normalizedBuffer;
526 const TextRun& m_run;
527 bool m_iterateBackwards;
528 int m_wordSpacingAdjustment;
529 float m_padding;
530 float m_padPerWordBreak;
531 float m_padError;
532
533
534
535 unsigned m_letterSpacing;
536 };
class Font {
77 public:
236 private:
237 bool loadingCustomFonts() const
238 {
239 return m_fontList && m_fontList->loadingCustomFonts();
240 }
241
242 FontDescription m_fontDescription;
243 mutable RefPtr<FontFallbackList> m_fontList;
244 short m_letterSpacing;
245 short m_wordSpacing;
246 bool m_isPlatformFont;
247 bool m_needsTranscoding;
248 };
40 class FontFallbackList : public RefCounted<FontFallbackList> {
41 public:
54
55 private:
73 mutable Vector<pair<const FontData*, bool>, 1> m_fontList;
74 mutable HashMap<int, GlyphPageTreeNode*> m_pages;
75 mutable GlyphPageTreeNode* m_pageZero;
76 mutable const SimpleFontData* m_cachedPrimarySimpleFontData;
77 RefPtr<FontSelector> m_fontSelector;
78 mutable int m_familyIndex;
79 mutable Pitch m_pitch;
80 mutable bool m_loadingCustomFonts;
81 unsigned m_generation;
82
83 friend class Font;
84 };
53 class FontCache {
54 WTF_MAKE_NONCOPYABLE(FontCache); WTF_MAKE_FAST_ALLOCATED;
55 public:
96 private:
109 friend class SimpleFontData;
110 friend class FontFallbackList;
111 };
112
72 class SimpleFontData : public FontData {
73 public:
186 private:
206 FontMetrics m_fontMetrics;
207 float m_maxCharWidth;
208 float m_avgCharWidth;
209
210 FontPlatformData m_platformData;
211
212 mutable OwnPtr<GlyphMetricsMap<FloatRect> > m_glyphToBoundsMap;
213 mutable GlyphMetricsMap<float> m_glyphToWidthMap;
214
215 bool m_treatAsFixedPitch;
216
217 #if ENABLE(SVG_FONTS)
218 OwnPtr<SVGFontData> m_svgFontData;
219 #endif
220
221 bool m_isCustomFont;
222 bool m_isLoading;
223
224 bool m_isTextOrientationFallback;
225 bool m_isBrokenIdeographFallback;
226 bool m_hasVerticalGlyphs;
227
228 Glyph m_spaceGlyph;
229 float m_spaceWidth;
230
231 Glyph m_zeroWidthSpaceGlyph;
232
233 GlyphData m_missingGlyphData;
234
253 mutable OwnPtr<DerivedFontData> m_derivedFontData;
287 };
288
49 class FontPlatformData {
50 public:
101 private:
121 SkTypeface* m_typeface;
122 float m_textSize;
123 mutable int m_emSizeInFontUnits;
124 bool m_fakeBold;
125 bool m_fakeItalic;
126 FontOrientation m_orientation;
127 TextOrientation m_textOrientation;
128 mutable RefPtr<RefCountedHarfbuzzFace> m_harfbuzzFace;
129 static SkLanguage s_defaultLanguage;
31 class SK_API SkTypeface : public SkRefCnt {
32 public:
33
35 enum Style {
36 kNormal = 0,
37 kBold = 0x01,
38 kItalic = 0x02,
39
40
41 kBoldItalic = 0x03
42 };
155 private:
156 SkFontID fUniqueID;
157 Style fStyle;
158 bool fIsFixedWidth;
159
160 typedef SkRefCnt INHERITED;
161 };
53 class FontDescription {
54 public:
55 enum GenericFamilyType { NoFamily, StandardFamily, SerifFamily, SansSerifFamily,
56 MonospaceFamily, CursiveFamily, FantasyFamily };
57
129 private:
130 FontFamily m_familyList;
131
132 float m_specifiedSize;
133
134 float m_computedSize;
135
136 FontOrientation m_orientation;
137 TextOrientation m_textOrientation;
138
139 FontWidthVariant m_widthVariant;
140
141 bool m_italic : 1;
142 bool m_smallCaps : 1;
143 bool m_isAbsoluteSize : 1;
144
145 unsigned m_weight : 8;
146 unsigned m_genericFamily : 3;
147 bool m_usePrinterFont : 1;
148
149 unsigned m_renderingMode : 1;
150
151 unsigned m_keywordSize : 4;
152
153
154
155 unsigned m_fontSmoothing : 2;
156 unsigned m_textRendering : 2;
157 bool m_isSpecifiedFont : 1;
158 };
37 class FontFamily {
38 public:
52 private:
53 AtomicString m_family; <=====
54 ListRefPtr<SharedFontFamily> m_next; <=====
55 };
56