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

Side by Side Diff: Source/platform/fonts/SimpleFontData.cpp

Issue 551373002: Remove debug output formatting from GlyphPageTreeNode and friends (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@mergeImplSquash
Patch Set: Rebased on top of FontPlatformData header merge 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2008, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2008, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2006 Alexey Proskuryakov 3 * Copyright (C) 2006 Alexey Proskuryakov
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 { 211 {
212 if (!m_derivedFontData) 212 if (!m_derivedFontData)
213 m_derivedFontData = DerivedFontData::create(isCustomFont()); 213 m_derivedFontData = DerivedFontData::create(isCustomFont());
214 if (!m_derivedFontData->brokenIdeograph) { 214 if (!m_derivedFontData->brokenIdeograph) {
215 m_derivedFontData->brokenIdeograph = create(m_platformData, isCustomFont () ? CustomFontData::create(): nullptr); 215 m_derivedFontData->brokenIdeograph = create(m_platformData, isCustomFont () ? CustomFontData::create(): nullptr);
216 m_derivedFontData->brokenIdeograph->m_isBrokenIdeographFallback = true; 216 m_derivedFontData->brokenIdeograph->m_isBrokenIdeographFallback = true;
217 } 217 }
218 return m_derivedFontData->brokenIdeograph; 218 return m_derivedFontData->brokenIdeograph;
219 } 219 }
220 220
221 #ifndef NDEBUG
222 String SimpleFontData::description() const
223 {
224 if (isSVGFont())
225 return "[SVG font]";
226 if (isCustomFont())
227 return "[custom font]";
228
229 return platformData().description();
230 }
231 #endif
232
233 PassOwnPtr<SimpleFontData::DerivedFontData> SimpleFontData::DerivedFontData::cre ate(bool forCustomFont) 221 PassOwnPtr<SimpleFontData::DerivedFontData> SimpleFontData::DerivedFontData::cre ate(bool forCustomFont)
234 { 222 {
235 return adoptPtr(new DerivedFontData(forCustomFont)); 223 return adoptPtr(new DerivedFontData(forCustomFont));
236 } 224 }
237 225
238 SimpleFontData::DerivedFontData::~DerivedFontData() 226 SimpleFontData::DerivedFontData::~DerivedFontData()
239 { 227 {
240 if (!forCustomFont) 228 if (!forCustomFont)
241 return; 229 return;
242 230
(...skipping 12 matching lines...) Expand all
255 PassRefPtr<SimpleFontData> SimpleFontData::createScaledFontData(const FontDescri ption& fontDescription, float scaleFactor) const 243 PassRefPtr<SimpleFontData> SimpleFontData::createScaledFontData(const FontDescri ption& fontDescription, float scaleFactor) const
256 { 244 {
257 // FIXME: Support scaled SVG fonts. Given that SVG is scalable in general th is should be achievable. 245 // FIXME: Support scaled SVG fonts. Given that SVG is scalable in general th is should be achievable.
258 if (isSVGFont()) 246 if (isSVGFont())
259 return nullptr; 247 return nullptr;
260 248
261 return platformCreateScaledFontData(fontDescription, scaleFactor); 249 return platformCreateScaledFontData(fontDescription, scaleFactor);
262 } 250 }
263 251
264 } // namespace blink 252 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/fonts/SimpleFontData.h ('k') | Source/platform/fonts/cocoa/FontPlatformDataCocoa.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698