OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef LineLayoutText_h | 5 #ifndef LineLayoutText_h |
6 #define LineLayoutText_h | 6 #define LineLayoutText_h |
7 | 7 |
8 #include "core/layout/LayoutText.h" | 8 #include "core/layout/LayoutText.h" |
9 #include "core/layout/api/LineLayoutItem.h" | 9 #include "core/layout/api/LineLayoutItem.h" |
10 #include "platform/LayoutUnit.h" | 10 #include "platform/LayoutUnit.h" |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 SelectionState selectionState() const | 115 SelectionState selectionState() const |
116 { | 116 { |
117 return toText()->selectionState(); | 117 return toText()->selectionState(); |
118 } | 118 } |
119 | 119 |
120 void selectionStartEnd(int& spos, int& epos) const | 120 void selectionStartEnd(int& spos, int& epos) const |
121 { | 121 { |
122 return toText()->selectionStartEnd(spos, epos); | 122 return toText()->selectionStartEnd(spos, epos); |
123 } | 123 } |
124 | 124 |
| 125 unsigned textStartOffset() const |
| 126 { |
| 127 return toText()->textStartOffset(); |
| 128 } |
| 129 |
125 private: | 130 private: |
126 LayoutText* toText() { return toLayoutText(layoutObject()); } | 131 LayoutText* toText() { return toLayoutText(layoutObject()); } |
127 const LayoutText* toText() const { return toLayoutText(layoutObject()); } | 132 const LayoutText* toText() const { return toLayoutText(layoutObject()); } |
128 }; | 133 }; |
129 | 134 |
130 } // namespace blink | 135 } // namespace blink |
131 | 136 |
132 #endif // LineLayoutText_h | 137 #endif // LineLayoutText_h |
OLD | NEW |