| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of the internal font implementation. | 2 * This file is part of the internal font implementation. |
| 3 * | 3 * |
| 4 * Copyright (C) 2006, 2008, 2010 Apple Inc. All rights reserved. | 4 * Copyright (C) 2006, 2008, 2010 Apple Inc. All rights reserved. |
| 5 * Copyright (C) 2007-2008 Torch Mobile, Inc. | 5 * Copyright (C) 2007-2008 Torch Mobile, Inc. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 virtual bool fillGlyphPage(GlyphPage* pageToFill, unsigned offset, unsigned
length, UChar* buffer, unsigned bufferLength) const; | 153 virtual bool fillGlyphPage(GlyphPage* pageToFill, unsigned offset, unsigned
length, UChar* buffer, unsigned bufferLength) const; |
| 154 | 154 |
| 155 protected: | 155 protected: |
| 156 SimpleFontData(const FontPlatformData&, PassRefPtr<CustomFontData> customDat
a, bool isTextOrientationFallback = false); | 156 SimpleFontData(const FontPlatformData&, PassRefPtr<CustomFontData> customDat
a, bool isTextOrientationFallback = false); |
| 157 | 157 |
| 158 SimpleFontData(PassRefPtr<CustomFontData> customData, float fontSize, bool s
yntheticBold, bool syntheticItalic); | 158 SimpleFontData(PassRefPtr<CustomFontData> customData, float fontSize, bool s
yntheticBold, bool syntheticItalic); |
| 159 | 159 |
| 160 private: | 160 private: |
| 161 void platformInit(); | 161 void platformInit(); |
| 162 void platformGlyphInit(); | 162 void platformGlyphInit(); |
| 163 void platformCharWidthInit(); | |
| 164 void platformDestroy(); | |
| 165 | 163 |
| 166 PassRefPtr<SimpleFontData> createScaledFontData(const FontDescription&, floa
t scaleFactor) const; | 164 PassRefPtr<SimpleFontData> createScaledFontData(const FontDescription&, floa
t scaleFactor) const; |
| 167 PassRefPtr<SimpleFontData> platformCreateScaledFontData(const FontDescriptio
n&, float scaleFactor) const; | 165 PassRefPtr<SimpleFontData> platformCreateScaledFontData(const FontDescriptio
n&, float scaleFactor) const; |
| 168 | 166 |
| 169 FontMetrics m_fontMetrics; | 167 FontMetrics m_fontMetrics; |
| 170 float m_maxCharWidth; | 168 float m_maxCharWidth; |
| 171 float m_avgCharWidth; | 169 float m_avgCharWidth; |
| 172 | 170 |
| 173 FontPlatformData m_platformData; | 171 FontPlatformData m_platformData; |
| 174 | 172 |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 width = platformWidthForGlyph(glyph); | 252 width = platformWidthForGlyph(glyph); |
| 255 | 253 |
| 256 m_glyphToWidthMap.setMetricsForGlyph(glyph, width); | 254 m_glyphToWidthMap.setMetricsForGlyph(glyph, width); |
| 257 return width; | 255 return width; |
| 258 } | 256 } |
| 259 | 257 |
| 260 DEFINE_FONT_DATA_TYPE_CASTS(SimpleFontData, false); | 258 DEFINE_FONT_DATA_TYPE_CASTS(SimpleFontData, false); |
| 261 | 259 |
| 262 } // namespace blink | 260 } // namespace blink |
| 263 #endif // SimpleFontData_h | 261 #endif // SimpleFontData_h |
| OLD | NEW |