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

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

Issue 574873002: Add onGetFamilyName to SkTypeface. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Add .get() for DirectWrite. Created 6 years, 3 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_linux.cpp » ('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 2008 Google Inc. 2 * Copyright 2008 Google Inc.
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 "SkFontConfigInterface.h" 8 #include "SkFontConfigInterface.h"
9 #include "SkFontConfigTypeface.h" 9 #include "SkFontConfigTypeface.h"
10 #include "SkFontDescriptor.h" 10 #include "SkFontDescriptor.h"
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 SkAutoTUnref<SkFontConfigInterface> fci(RefFCI()); 155 SkAutoTUnref<SkFontConfigInterface> fci(RefFCI());
156 if (NULL == fci.get()) { 156 if (NULL == fci.get()) {
157 return NULL; 157 return NULL;
158 } 158 }
159 stream = fci->openStream(this->getIdentity()); 159 stream = fci->openStream(this->getIdentity());
160 *ttcIndex = this->getIdentity().fTTCIndex; 160 *ttcIndex = this->getIdentity().fTTCIndex;
161 } 161 }
162 return stream; 162 return stream;
163 } 163 }
164 164
165 void FontConfigTypeface::onGetFamilyName(SkString* familyName) const {
166 *familyName = this->getFamilyName();
167 }
168
165 void FontConfigTypeface::onGetFontDescriptor(SkFontDescriptor* desc, 169 void FontConfigTypeface::onGetFontDescriptor(SkFontDescriptor* desc,
166 bool* isLocalStream) const { 170 bool* isLocalStream) const {
167 desc->setFamilyName(this->getFamilyName()); 171 desc->setFamilyName(this->getFamilyName());
168 *isLocalStream = SkToBool(this->getLocalStream()); 172 *isLocalStream = SkToBool(this->getLocalStream());
169 } 173 }
OLDNEW
« no previous file with comments | « src/ports/SkFontConfigTypeface.h ('k') | src/ports/SkFontHost_linux.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698