summaryrefslogtreecommitdiff
path: root/Source/WebCore/rendering/RenderTableSection.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/rendering/RenderTableSection.h')
-rw-r--r--Source/WebCore/rendering/RenderTableSection.h40
1 files changed, 39 insertions, 1 deletions
diff --git a/Source/WebCore/rendering/RenderTableSection.h b/Source/WebCore/rendering/RenderTableSection.h
index dcdc13490..289415306 100644
--- a/Source/WebCore/rendering/RenderTableSection.h
+++ b/Source/WebCore/rendering/RenderTableSection.h
@@ -49,6 +49,9 @@ public:
unsigned start() const { return m_start; }
unsigned end() const { return m_end; }
+ unsigned& start() { return m_start; }
+ unsigned& end() { return m_end; }
+
private:
unsigned m_start;
unsigned m_end;
@@ -114,6 +117,30 @@ public:
Length logicalHeight;
};
+ bool hasSameDirectionAsTable() const
+ {
+ return table()->style()->direction() == style()->direction();
+ }
+
+ const BorderValue& borderAdjoiningTableStart() const
+ {
+ if (hasSameDirectionAsTable())
+ return style()->borderStart();
+
+ return style()->borderEnd();
+ }
+
+ const BorderValue& borderAdjoiningTableEnd() const
+ {
+ if (hasSameDirectionAsTable())
+ return style()->borderEnd();
+
+ return style()->borderStart();
+ }
+
+ const RenderTableCell* firstRowCellAdjoiningTableStart() const;
+ const RenderTableCell* firstRowCellAdjoiningTableEnd() const;
+
CellStruct& cellAt(unsigned row, unsigned col) { return m_grid[row].row[col]; }
const CellStruct& cellAt(unsigned row, unsigned col) const { return m_grid[row].row[col]; }
RenderTableCell* primaryCellAt(unsigned row, unsigned col)
@@ -165,6 +192,8 @@ public:
{
return createAnonymousWithParentRenderer(parent);
}
+
+ virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE;
protected:
virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle);
@@ -183,7 +212,6 @@ private:
virtual void removeChild(RenderObject* oldChild);
- virtual void paint(PaintInfo&, const LayoutPoint&);
virtual void paintCell(RenderTableCell*, PaintInfo&, const LayoutPoint&);
virtual void paintObject(PaintInfo&, const LayoutPoint&);
@@ -202,9 +230,19 @@ private:
CellSpan fullTableRowSpan() const { return CellSpan(0, m_grid.size()); }
CellSpan fullTableColumnSpan() const { return CellSpan(0, table()->columns().size()); }
+ // Flip the rect so it aligns with the coordinates used by the rowPos and columnPos vectors.
+ LayoutRect logicalRectForWritingModeAndDirection(const LayoutRect&) const;
+
CellSpan dirtiedRows(const LayoutRect& repaintRect) const;
CellSpan dirtiedColumns(const LayoutRect& repaintRect) const;
+ // These two functions take a rectangle as input that has been flipped by logicalRectForWritingModeAndDirection.
+ // The returned span of rows or columns is end-exclusive, and empty if start==end.
+ CellSpan spannedRows(const LayoutRect& flippedRect) const;
+ CellSpan spannedColumns(const LayoutRect& flippedRect) const;
+
+ void setLogicalPositionForCell(RenderTableCell*, unsigned effectiveColumn) const;
+
RenderObjectChildList m_children;
Vector<RowStruct> m_grid;