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

Side by Side Diff: third_party/WebKit/Source/platform/fonts/FontPlatformData.h

Issue 2581083003: Initial OpenType Font Variations Support (Closed)
Patch Set: Fix makeUnique syntax Created 3 years, 12 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2006, 2007, 2008, Google Inc. All rights reserved. 2 * Copyright (c) 2006, 2007, 2008, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 } 67 }
68 #endif // OS(MACOSX) 68 #endif // OS(MACOSX)
69 69
70 class SkTypeface; 70 class SkTypeface;
71 typedef uint32_t SkFontID; 71 typedef uint32_t SkFontID;
72 72
73 namespace blink { 73 namespace blink {
74 74
75 class Font; 75 class Font;
76 class HarfBuzzFace; 76 class HarfBuzzFace;
77 class FontVariationSettings;
77 78
78 class PLATFORM_EXPORT FontPlatformData { 79 class PLATFORM_EXPORT FontPlatformData {
79 USING_FAST_MALLOC(FontPlatformData); 80 USING_FAST_MALLOC(FontPlatformData);
80 81
81 public: 82 public:
82 // Used for deleted values in the font cache's hash tables. The hash table 83 // Used for deleted values in the font cache's hash tables. The hash table
83 // will create us with this structure, and it will compare other values 84 // will create us with this structure, and it will compare other values
84 // to this "Deleted" one. It expects the Deleted one to be differentiable 85 // to this "Deleted" one. It expects the Deleted one to be differentiable
85 // from the 0 one (created with the empty constructor), so we can't just 86 // from the 0 one (created with the empty constructor), so we can't just
86 // set everything to 0. 87 // set everything to 0.
87 FontPlatformData(WTF::HashTableDeletedValueType); 88 FontPlatformData(WTF::HashTableDeletedValueType);
88 FontPlatformData(); 89 FontPlatformData();
89 FontPlatformData(const FontPlatformData&); 90 FontPlatformData(const FontPlatformData&);
90 FontPlatformData(float size, 91 FontPlatformData(float size,
91 bool syntheticBold, 92 bool syntheticBold,
92 bool syntheticItalic, 93 bool syntheticItalic,
93 FontOrientation = FontOrientation::Horizontal); 94 FontOrientation = FontOrientation::Horizontal);
94 FontPlatformData(const FontPlatformData& src, float textSize); 95 FontPlatformData(const FontPlatformData& src, float textSize);
95 #if OS(MACOSX) 96 #if OS(MACOSX)
96 FontPlatformData(NSFont*, 97 FontPlatformData(NSFont*,
97 float size, 98 float size,
98 bool syntheticBold = false, 99 bool syntheticBold,
99 bool syntheticItalic = false, 100 bool syntheticItalic,
100 FontOrientation = FontOrientation::Horizontal); 101 FontOrientation,
102 FontVariationSettings*);
101 #endif 103 #endif
102 FontPlatformData(sk_sp<SkTypeface>, 104 FontPlatformData(sk_sp<SkTypeface>,
103 const char* name, 105 const char* name,
104 float textSize, 106 float textSize,
105 bool syntheticBold, 107 bool syntheticBold,
106 bool syntheticItalic, 108 bool syntheticItalic,
107 FontOrientation = FontOrientation::Horizontal); 109 FontOrientation = FontOrientation::Horizontal);
108 ~FontPlatformData(); 110 ~FontPlatformData();
109 111
110 #if OS(MACOSX) 112 #if OS(MACOSX)
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 #if OS(WIN) 188 #if OS(WIN)
187 int m_paintTextFlags; 189 int m_paintTextFlags;
188 unsigned m_minSizeForAntiAlias; 190 unsigned m_minSizeForAntiAlias;
189 float m_minSizeForSubpixel; 191 float m_minSizeForSubpixel;
190 #endif 192 #endif
191 }; 193 };
192 194
193 } // namespace blink 195 } // namespace blink
194 196
195 #endif // ifdef FontPlatformData_h 197 #endif // ifdef FontPlatformData_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698