Closed
Bug 1155880
Opened 9 years ago
Closed 9 years ago
Rename table layout strategy "column width" APIs to use "isize" instead
Categories
(Core :: Layout: Tables, defect)
Core
Layout: Tables
Tracking
()
RESOLVED
FIXED
mozilla40
Tracking | Status | |
---|---|---|
firefox40 | --- | fixed |
People
(Reporter: dholbert, Assigned: dholbert)
References
Details
Attachments
(3 files)
10.39 KB,
patch
|
jfkthame
:
review+
|
Details | Diff | Splinter Review |
13.37 KB,
patch
|
jfkthame
:
review+
|
Details | Diff | Splinter Review |
8.63 KB,
patch
|
jfkthame
:
review+
|
Details | Diff | Splinter Review |
Lots of our table code is about determining column widths. In particular, the nsITableLayoutStrategy interface does most of its interesting work in the function "ComputeColumnWidths". (and the implementations of this method call nsTableColFrame::GetFinalWidth/SetFinalWidth) In vertical writing-modes, though, column direction will be swapped (so that each column will be a horizontal thing, instead of a vertical thing). Then, we'll need to be computing & setting column *heights*, not *widths*. In general, we should be computing the inline-dimension size of table columns; so we should generify this language to just use "ISize" instead of "Width".
Assignee | ||
Comment 1•9 years ago
|
||
[sorry, had assignee & CC fields' contents swapped when filing]
Assignee: jfkthame → dholbert
Assignee | ||
Comment 2•9 years ago
|
||
Attachment #8594213 -
Flags: review?(jfkthame)
Assignee | ||
Comment 3•9 years ago
|
||
Following the rabbit-hole -- the function changed in part 1 (ComputeColumnWidths) does its work using nsTableColFrame::GetFinalWidth/SetFinalWidth. So, this patch does the same renaming on these nsTableColFrame methods (and the member-var "mFinalWidth" controlled by these methods, since its usages are pretty minimal & simple).
Attachment #8594215 -
Flags: review?(jfkthame)
Assignee | ||
Comment 4•9 years ago
|
||
Following the rabbit-hole one more step: as shown in previous patch, nsTableColFrame::GetFinalWidth (now called GetFinalISize) is also exposed via a nsTableFrame method, "GetColumnWidth". This patch renames that method as well, for consistency / completeness (or an approximation thereof).
Attachment #8594217 -
Flags: review?(jfkthame)
Comment 5•9 years ago
|
||
The renaming here all looks reasonable, though it puts us in a state where various "ISize" methods are in fact still working on physical-coordinate widths, so the new names are rather misleading at this stage. But you're intending to fix that in following patches/bugs, I'm sure.....
Updated•9 years ago
|
Attachment #8594213 -
Flags: review?(jfkthame) → review+
Updated•9 years ago
|
Attachment #8594215 -
Flags: review?(jfkthame) → review+
Updated•9 years ago
|
Attachment #8594217 -
Flags: review?(jfkthame) → review+
Assignee | ||
Comment 6•9 years ago
|
||
(In reply to Jonathan Kew (:jfkthame) from comment #5) > The renaming here all looks reasonable, though it puts us in a state where > various "ISize" methods are in fact still working on physical-coordinate > widths, so the new names are rather misleading at this stage. True -- though, these classes are already in that state (& inconsistently so). These TableLayoutStrategy classes already have methods GetPrefISize() and MarkIntrinsicISizesDirty(), which actually operate on width-flavored values. These methods were renamed last year in bug 1031241 (parts 1 and 3). So, the patches here just make this code more consistent about displaying an "ISize" facade. :) > But you're > intending to fix that in following patches/bugs, I'm sure..... At some point soon, yes. (not necessarily immediately, but sometime this quarter, in support of bug 1077521.)
Assignee | ||
Comment 7•9 years ago
|
||
(Thanks for the reviews!)
https://hg.mozilla.org/integration/mozilla-inbound/rev/352e8f8c5915 https://hg.mozilla.org/integration/mozilla-inbound/rev/15f970a06d93 https://hg.mozilla.org/integration/mozilla-inbound/rev/98fd24ddd601
Assignee | ||
Updated•9 years ago
|
Flags: in-testsuite-
Comment 9•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/352e8f8c5915 https://hg.mozilla.org/mozilla-central/rev/15f970a06d93 https://hg.mozilla.org/mozilla-central/rev/98fd24ddd601
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in
before you can comment on or make changes to this bug.
Description
•