Currently most of the code makes the assumption that cells have the same alignment as their section. This is wrong and caused bug 79272. Example from RenderTableCell::computeCollapsedStartBorder: CollapsedBorderValue prevCellBorder = CollapsedBorderValue(prevCell->style()->borderEnd(), includeColor ? prevCell->style()->visitedDependentColor(endColorProperty) : Color(), BCELL); This assumes that |prevCell| has the same direction as |this| or this will pick up the wrong border. The idea of this refactoring is to introduce some new direction-aware function to get adjoining borders.
Created attachment 164253 [details] Proposed refactoring. Introduce several new helper functions.
Created attachment 164620 [details] Proposed change 2. Forgot to update the column code too.
Comment on attachment 164620 [details] Proposed change 2. Forgot to update the column code too. Attachment 164620 [details] did not pass mac-ews (mac): Output: http://queues.webkit.org/results/13897299
Created attachment 164756 [details] v3: Fixed Mac build, removed unused parameter in RenderTableCol functions.
Comment on attachment 164756 [details] v3: Fixed Mac build, removed unused parameter in RenderTableCol functions. I find the names all very similar, but different in subtle ways. I couldn't think of any better names though. :(
Comment on attachment 164756 [details] v3: Fixed Mac build, removed unused parameter in RenderTableCol functions. Thanks Ojan! The Qt bots are b0rken, based on previous patches not breaking Qt, this patch should be fine to land.
Comment on attachment 164756 [details] v3: Fixed Mac build, removed unused parameter in RenderTableCol functions. Clearing flags on attachment: 164756 Committed r129078: <http://trac.webkit.org/changeset/129078>
All reviewed patches have been landed. Closing bug.