Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(136)

Side by Side Diff: src/ports/SkFontHost_FreeType.cpp

Issue 806653007: Fix up all the easy virtual ... SK_OVERRIDE cases. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/ports/SkFontConfigTypeface.h ('k') | src/ports/SkFontHost_FreeType_common.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkAdvancedTypefaceMetrics.h" 8 #include "SkAdvancedTypefaceMetrics.h"
9 #include "SkBitmap.h" 9 #include "SkBitmap.h"
10 #include "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 SkScalerContext_FreeType(SkTypeface*, const SkDescriptor* desc); 187 SkScalerContext_FreeType(SkTypeface*, const SkDescriptor* desc);
188 virtual ~SkScalerContext_FreeType(); 188 virtual ~SkScalerContext_FreeType();
189 189
190 bool success() const { 190 bool success() const {
191 return fFaceRec != NULL && 191 return fFaceRec != NULL &&
192 fFTSize != NULL && 192 fFTSize != NULL &&
193 fFace != NULL; 193 fFace != NULL;
194 } 194 }
195 195
196 protected: 196 protected:
197 virtual unsigned generateGlyphCount() SK_OVERRIDE; 197 unsigned generateGlyphCount() SK_OVERRIDE;
198 virtual uint16_t generateCharToGlyph(SkUnichar uni) SK_OVERRIDE; 198 uint16_t generateCharToGlyph(SkUnichar uni) SK_OVERRIDE;
199 virtual void generateAdvance(SkGlyph* glyph) SK_OVERRIDE; 199 void generateAdvance(SkGlyph* glyph) SK_OVERRIDE;
200 virtual void generateMetrics(SkGlyph* glyph) SK_OVERRIDE; 200 void generateMetrics(SkGlyph* glyph) SK_OVERRIDE;
201 virtual void generateImage(const SkGlyph& glyph) SK_OVERRIDE; 201 void generateImage(const SkGlyph& glyph) SK_OVERRIDE;
202 virtual void generatePath(const SkGlyph& glyph, SkPath* path) SK_OVERRIDE; 202 void generatePath(const SkGlyph& glyph, SkPath* path) SK_OVERRIDE;
203 virtual void generateFontMetrics(SkPaint::FontMetrics*) SK_OVERRIDE; 203 void generateFontMetrics(SkPaint::FontMetrics*) SK_OVERRIDE;
204 virtual SkUnichar generateGlyphToChar(uint16_t glyph) SK_OVERRIDE; 204 SkUnichar generateGlyphToChar(uint16_t glyph) SK_OVERRIDE;
205 205
206 private: 206 private:
207 SkFaceRec* fFaceRec; 207 SkFaceRec* fFaceRec;
208 FT_Face fFace; // reference to shared face in gFaceRecHead 208 FT_Face fFace; // reference to shared face in gFaceRecHead
209 FT_Size fFTSize; // our own copy 209 FT_Size fFTSize; // our own copy
210 FT_Int fStrikeIndex; 210 FT_Int fStrikeIndex;
211 SkFixed fScaleX, fScaleY; 211 SkFixed fScaleX, fScaleY;
212 FT_Matrix fMatrix22; 212 FT_Matrix fMatrix22;
213 uint32_t fLoadGlyphFlags; 213 uint32_t fLoadGlyphFlags;
214 bool fDoLinearMetrics; 214 bool fDoLinearMetrics;
(...skipping 1502 matching lines...) Expand 10 before | Expand all | Expand 10 after
1717 if (style) { 1717 if (style) {
1718 *style = SkFontStyle(weight, width, slant); 1718 *style = SkFontStyle(weight, width, slant);
1719 } 1719 }
1720 if (isFixedPitch) { 1720 if (isFixedPitch) {
1721 *isFixedPitch = FT_IS_FIXED_WIDTH(face); 1721 *isFixedPitch = FT_IS_FIXED_WIDTH(face);
1722 } 1722 }
1723 1723
1724 FT_Done_Face(face); 1724 FT_Done_Face(face);
1725 return true; 1725 return true;
1726 } 1726 }
OLDNEW
« no previous file with comments | « src/ports/SkFontConfigTypeface.h ('k') | src/ports/SkFontHost_FreeType_common.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698