| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2003, 2006, 2007, 2010, 2011 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003, 2006, 2007, 2010, 2011 Apple Inc. All rights reserved. |
| 6 * Copyright (C) 2008 Holger Hans Peter Freyther | 6 * Copyright (C) 2008 Holger Hans Peter Freyther |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 * | 22 * |
| 23 */ | 23 */ |
| 24 | 24 |
| 25 #ifndef Font_h | 25 #ifndef Font_h |
| 26 #define Font_h | 26 #define Font_h |
| 27 | 27 |
| 28 #include "platform/LayoutUnit.h" | 28 #include "platform/LayoutUnit.h" |
| 29 #include "platform/PlatformExport.h" | 29 #include "platform/PlatformExport.h" |
| 30 #include "platform/fonts/FontDescription.h" | 30 #include "platform/fonts/FontDescription.h" |
| 31 #include "platform/fonts/FontFallbackList.h" | 31 #include "platform/fonts/FontFallbackList.h" |
| 32 #include "platform/fonts/FontFallbackPriority.h" |
| 32 #include "platform/fonts/SimpleFontData.h" | 33 #include "platform/fonts/SimpleFontData.h" |
| 33 #include "platform/text/TabSize.h" | 34 #include "platform/text/TabSize.h" |
| 34 #include "platform/text/TextDirection.h" | 35 #include "platform/text/TextDirection.h" |
| 35 #include "platform/text/TextPath.h" | 36 #include "platform/text/TextPath.h" |
| 36 #include "wtf/Allocator.h" | 37 #include "wtf/Allocator.h" |
| 37 #include "wtf/HashMap.h" | 38 #include "wtf/HashMap.h" |
| 38 #include "wtf/HashSet.h" | 39 #include "wtf/HashSet.h" |
| 39 #include "wtf/MathExtras.h" | 40 #include "wtf/MathExtras.h" |
| 40 #include "wtf/text/CharacterNames.h" | 41 #include "wtf/text/CharacterNames.h" |
| 41 | 42 |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 float floatWidthForComplexText(const TextRun&, HashSet<const SimpleFontData*
>* fallbackFonts, FloatRect* glyphBounds) const; | 133 float floatWidthForComplexText(const TextRun&, HashSet<const SimpleFontData*
>* fallbackFonts, FloatRect* glyphBounds) const; |
| 133 int offsetForPositionForComplexText(const TextRun&, float position, bool inc
ludePartialGlyphs) const; | 134 int offsetForPositionForComplexText(const TextRun&, float position, bool inc
ludePartialGlyphs) const; |
| 134 FloatRect selectionRectForComplexText(const TextRun&, const FloatPoint&, int
h, int from, int to) const; | 135 FloatRect selectionRectForComplexText(const TextRun&, const FloatPoint&, int
h, int from, int to) const; |
| 135 | 136 |
| 136 bool computeCanShapeWordByWord() const; | 137 bool computeCanShapeWordByWord() const; |
| 137 | 138 |
| 138 friend struct SimpleShaper; | 139 friend struct SimpleShaper; |
| 139 | 140 |
| 140 public: | 141 public: |
| 141 FontSelector* fontSelector() const; | 142 FontSelector* fontSelector() const; |
| 142 PassRefPtr<FontFallbackIterator> createFontFallbackIterator() const; | 143 PassRefPtr<FontFallbackIterator> createFontFallbackIterator( |
| 144 FontFallbackPriority) const; |
| 143 | 145 |
| 144 void willUseFontData(UChar32) const; | 146 void willUseFontData(UChar32) const; |
| 145 | 147 |
| 146 bool loadingCustomFonts() const; | 148 bool loadingCustomFonts() const; |
| 147 bool isFallbackValid() const; | 149 bool isFallbackValid() const; |
| 148 | 150 |
| 149 private: | 151 private: |
| 150 bool shouldSkipDrawing() const | 152 bool shouldSkipDrawing() const |
| 151 { | 153 { |
| 152 return m_fontFallbackList && m_fontFallbackList->shouldSkipDrawing(); | 154 return m_fontFallbackList && m_fontFallbackList->shouldSkipDrawing(); |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 // if the distance to the next tab stop is less than that, advance an additi
onal tab stop. | 195 // if the distance to the next tab stop is less than that, advance an additi
onal tab stop. |
| 194 if (distanceToTabStop < std::max(fontDescription().letterSpacing(), LayoutUn
it::epsilon())) | 196 if (distanceToTabStop < std::max(fontDescription().letterSpacing(), LayoutUn
it::epsilon())) |
| 195 distanceToTabStop += baseTabWidth; | 197 distanceToTabStop += baseTabWidth; |
| 196 | 198 |
| 197 return distanceToTabStop; | 199 return distanceToTabStop; |
| 198 } | 200 } |
| 199 | 201 |
| 200 } // namespace blink | 202 } // namespace blink |
| 201 | 203 |
| 202 #endif | 204 #endif |
| OLD | NEW |