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

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

Issue 14401007: Add missing unistd.h include after r8765. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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 "SkFontDescriptor.h" 9 #include "SkFontDescriptor.h"
10 #include "SkFontHost.h" 10 #include "SkFontHost.h"
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 const char* last = strrchr(str, '/'); 230 const char* last = strrchr(str, '/');
231 return last ? last + 1 : NULL; 231 return last ? last + 1 : NULL;
232 } 232 }
233 233
234 static bool is_lower(char c) { 234 static bool is_lower(char c) {
235 return c >= 'a' && c <= 'z'; 235 return c >= 'a' && c <= 'z';
236 } 236 }
237 237
238 #include "SkFontMgr.h" 238 #include "SkFontMgr.h"
239 #include <fontconfig/fontconfig.h> 239 #include <fontconfig/fontconfig.h>
240 #include <unistd.h>
240 241
241 static int get_int(FcPattern* pattern, const char field[]) { 242 static int get_int(FcPattern* pattern, const char field[]) {
242 int value; 243 int value;
243 if (FcPatternGetInteger(pattern, field, 0, &value) != FcResultMatch) { 244 if (FcPatternGetInteger(pattern, field, 0, &value) != FcResultMatch) {
244 value = SK_MinS32; 245 value = SK_MinS32;
245 } 246 }
246 return value; 247 return value;
247 } 248 }
248 249
249 static const char* get_name(FcPattern* pattern, const char field[]) { 250 static const char* get_name(FcPattern* pattern, const char field[]) {
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 } 471 }
471 virtual SkTypeface* onCreateFromFile(const char path[], int ttcIndex) { 472 virtual SkTypeface* onCreateFromFile(const char path[], int ttcIndex) {
472 return NULL; 473 return NULL;
473 } 474 }
474 }; 475 };
475 476
476 SkFontMgr* SkFontMgr::Factory() { 477 SkFontMgr* SkFontMgr::Factory() {
477 SkFontConfigInterface* fci = RefFCI(); 478 SkFontConfigInterface* fci = RefFCI();
478 return fci ? SkNEW_ARGS(SkFontMgr_fontconfig, (fci)) : NULL; 479 return fci ? SkNEW_ARGS(SkFontMgr_fontconfig, (fci)) : NULL;
479 } 480 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698