OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) Research In Motion Limited 2010-2012. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2010-2012. All rights reserved. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 | 64 |
65 void computeCurrentFragmentMetrics(SVGInlineTextBox*); | 65 void computeCurrentFragmentMetrics(SVGInlineTextBox*); |
66 void recordTextFragment(SVGInlineTextBox*); | 66 void recordTextFragment(SVGInlineTextBox*); |
67 | 67 |
68 void beginTextPathLayout(SVGInlineFlowBox*); | 68 void beginTextPathLayout(SVGInlineFlowBox*); |
69 void endTextPathLayout(); | 69 void endTextPathLayout(); |
70 | 70 |
71 void layoutInlineTextBox(SVGInlineTextBox*); | 71 void layoutInlineTextBox(SVGInlineTextBox*); |
72 void layoutTextOnLineOrPath(SVGInlineTextBox*, LineLayoutSVGInlineText, cons
t ComputedStyle&); | 72 void layoutTextOnLineOrPath(SVGInlineTextBox*, LineLayoutSVGInlineText, cons
t ComputedStyle&); |
73 | 73 |
74 bool currentLogicalCharacterAttributes(SVGTextLayoutAttributes*&); | 74 const SVGTextLayoutAttributes* nextLogicalAttributes(); |
75 bool currentLogicalCharacterMetrics(SVGTextLayoutAttributes*&, SVGTextMetric
s&); | 75 const SVGTextLayoutAttributes* currentLogicalCharacterMetrics(SVGTextMetrics
&); |
76 void advanceToNextLogicalCharacter(const SVGTextMetrics&); | 76 void advanceToNextLogicalCharacter(const SVGTextMetrics&); |
77 | 77 |
78 private: | 78 // Logical iteration state. |
79 Vector<SVGTextLayoutAttributes*>& m_layoutAttributes; | 79 Vector<SVGTextLayoutAttributes*>& m_layoutAttributes; |
| 80 unsigned m_layoutAttributesPosition; |
| 81 unsigned m_logicalCharacterOffset; |
| 82 unsigned m_logicalMetricsListOffset; |
80 | 83 |
81 Vector<SVGInlineTextBox*> m_lineLayoutBoxes; | 84 Vector<SVGInlineTextBox*> m_lineLayoutBoxes; |
82 | 85 |
83 SVGTextFragment m_currentTextFragment; | 86 SVGTextFragment m_currentTextFragment; |
84 unsigned m_layoutAttributesPosition; | |
85 unsigned m_logicalCharacterOffset; | |
86 unsigned m_logicalMetricsListOffset; | |
87 SVGInlineTextMetricsIterator m_visualMetricsIterator; | 87 SVGInlineTextMetricsIterator m_visualMetricsIterator; |
88 FloatPoint m_textPosition; | 88 FloatPoint m_textPosition; |
89 bool m_isVerticalText; | 89 bool m_isVerticalText; |
90 bool m_inPathLayout; | 90 bool m_inPathLayout; |
91 bool m_textLengthSpacingInEffect; | 91 bool m_textLengthSpacingInEffect; |
92 | 92 |
93 // Text on path layout | 93 // Text on path layout |
94 OwnPtr<PathPositionMapper> m_textPath; | 94 OwnPtr<PathPositionMapper> m_textPath; |
95 float m_textPathStartOffset; | 95 float m_textPathStartOffset; |
96 float m_textPathCurrentOffset; | 96 float m_textPathCurrentOffset; |
97 float m_textPathDisplacement; | 97 float m_textPathDisplacement; |
98 float m_textPathSpacing; | 98 float m_textPathSpacing; |
99 float m_textPathScaling; | 99 float m_textPathScaling; |
100 }; | 100 }; |
101 | 101 |
102 } // namespace blink | 102 } // namespace blink |
103 | 103 |
104 #endif | 104 #endif |
OLD | NEW |