OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007 Rob Buis <buis@kde.org> | 2 * Copyright (C) 2007 Rob Buis <buis@kde.org> |
3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> | 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> |
4 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 4 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 12 matching lines...) Expand all Loading... |
23 #define SVGInlineTextBox_h | 23 #define SVGInlineTextBox_h |
24 | 24 |
25 #include "core/layout/line/FloatToLayoutUnit.h" | 25 #include "core/layout/line/FloatToLayoutUnit.h" |
26 #include "core/layout/line/InlineTextBox.h" | 26 #include "core/layout/line/InlineTextBox.h" |
27 #include "core/rendering/svg/SVGTextLayoutEngine.h" | 27 #include "core/rendering/svg/SVGTextLayoutEngine.h" |
28 | 28 |
29 namespace blink { | 29 namespace blink { |
30 | 30 |
31 class SVGInlineTextBox final : public InlineTextBox { | 31 class SVGInlineTextBox final : public InlineTextBox { |
32 public: | 32 public: |
33 SVGInlineTextBox(RenderObject&, int start, unsigned short length); | 33 SVGInlineTextBox(LayoutObject&, int start, unsigned short length); |
34 | 34 |
35 virtual bool isSVGInlineTextBox() const override { return true; } | 35 virtual bool isSVGInlineTextBox() const override { return true; } |
36 | 36 |
37 virtual FloatWillBeLayoutUnit virtualLogicalHeight() const override { return
m_logicalHeight; } | 37 virtual FloatWillBeLayoutUnit virtualLogicalHeight() const override { return
m_logicalHeight; } |
38 void setLogicalHeight(FloatWillBeLayoutUnit height) { m_logicalHeight = heig
ht; } | 38 void setLogicalHeight(FloatWillBeLayoutUnit height) { m_logicalHeight = heig
ht; } |
39 | 39 |
40 virtual int offsetForPosition(FloatWillBeLayoutUnit x, bool includePartialGl
yphs = true) const override; | 40 virtual int offsetForPosition(FloatWillBeLayoutUnit x, bool includePartialGl
yphs = true) const override; |
41 virtual FloatWillBeLayoutUnit positionForOffset(int offset) const override; | 41 virtual FloatWillBeLayoutUnit positionForOffset(int offset) const override; |
42 | 42 |
43 virtual void paint(const PaintInfo&, const LayoutPoint&, LayoutUnit lineTop,
LayoutUnit lineBottom) override; | 43 virtual void paint(const PaintInfo&, const LayoutPoint&, LayoutUnit lineTop,
LayoutUnit lineBottom) override; |
(...skipping 25 matching lines...) Expand all Loading... |
69 FloatWillBeLayoutUnit m_logicalHeight; | 69 FloatWillBeLayoutUnit m_logicalHeight; |
70 bool m_startsNewTextChunk : 1; | 70 bool m_startsNewTextChunk : 1; |
71 Vector<SVGTextFragment> m_textFragments; | 71 Vector<SVGTextFragment> m_textFragments; |
72 }; | 72 }; |
73 | 73 |
74 DEFINE_INLINE_BOX_TYPE_CASTS(SVGInlineTextBox); | 74 DEFINE_INLINE_BOX_TYPE_CASTS(SVGInlineTextBox); |
75 | 75 |
76 } // namespace blink | 76 } // namespace blink |
77 | 77 |
78 #endif // SVGInlineTextBox_h | 78 #endif // SVGInlineTextBox_h |
OLD | NEW |