Index: third_party/WebKit/Source/core/layout/LayoutTableCol.h |
diff --git a/third_party/WebKit/Source/core/layout/LayoutTableCol.h b/third_party/WebKit/Source/core/layout/LayoutTableCol.h |
index c9c54ed6c52d3bc9c024c9c90076d2e450db8a67..251672d5df19ad9f8c304f375740180fca53bbb2 100644 |
--- a/third_party/WebKit/Source/core/layout/LayoutTableCol.h |
+++ b/third_party/WebKit/Source/core/layout/LayoutTableCol.h |
@@ -67,7 +67,7 @@ class LayoutTableCol final : public LayoutTableBoxComponent { |
// For CSS table columns or colgroups, this is always 1. |
unsigned Span() const { return span_; } |
- bool IsTableColumnGroupWithColumnChildren() { return FirstChild(); } |
+ bool IsTableColumnGroupWithColumnChildren() const { return FirstChild(); } |
bool IsTableColumn() const { |
return Style()->Display() == EDisplay::kTableColumn; |
} |
@@ -76,6 +76,7 @@ class LayoutTableCol final : public LayoutTableBoxComponent { |
} |
LayoutTableCol* EnclosingColumnGroup() const; |
+ LayoutTableCol* LastColumnInGroup() const; |
// Returns the next column or column-group. |
LayoutTableCol* NextColumn() const; |
@@ -88,6 +89,12 @@ class LayoutTableCol final : public LayoutTableBoxComponent { |
const char* GetName() const override { return "LayoutTableCol"; } |
+ // Return indexes to all columns inside this element. |
+ // Can return vector with size 0 if LayoutTableCol is out of range. |
+ // <col> element can return size() > 2 if it spans multiple columns |
+ // <colgroup> element can return any size. |
+ Vector<unsigned> GetEffectiveColumnIndexes() const; |
+ |
private: |
bool IsOfType(LayoutObjectType type) const override { |
return type == kLayoutObjectLayoutTableCol || LayoutBox::IsOfType(type); |