Closed Bug 2000488 Opened 10 months ago Closed 10 months ago

Simplify logical axis conversion in orthogonal writing modes and self-alignment

Categories

(Core :: Layout: Block and Inline, task)

task

Tracking

()

RESOLVED FIXED
147 Branch
Tracking Status
firefox147 --- fixed

People

(Reporter: TYLin, Assigned: TYLin)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

I have ideas to clean up and simplify the code that handles logical axis conversions in orthogonal writing modes and self-alignment.

Converting a logical axis from one writing mode to another is a common operation
in layout. This helper improves readability.

This patch doesn't change behavior.

Assignee: nobody → aethanyc
Status: NEW → ASSIGNED

AxisPolarityFlipped() returns the negation of
WritingMode::ParallelAxisStartsOnSameSide(). It is sufficient to keep one
implementation in WritingMode and port the shortcut in
ParallelAxisStartsOnSameSide().

Depends on: 2000759
Pushed by aethanyc@gmail.com: https://github.com/mozilla-firefox/firefox/commit/62ad52e72505 https://hg.mozilla.org/integration/autoland/rev/7be8eadcb749 Add a helper method to convert LogicalAxis from one writing mode to another. r=layout-reviewers,jfkthame https://github.com/mozilla-firefox/firefox/commit/a08fe7ba212e https://hg.mozilla.org/integration/autoland/rev/36a6fbbc7ca1 Use nsStylePosition::UsedSelfAlignment() to simplify code. r=layout-reviewers,jfkthame https://github.com/mozilla-firefox/firefox/commit/310a28289424 https://hg.mozilla.org/integration/autoland/rev/ee30037211b4 Remove AxisPolarityFlipped() in ReflowInput.cpp. r=layout-reviewers,jfkthame
Status: ASSIGNED → RESOLVED
Closed: 10 months ago
Resolution: --- → FIXED
Target Milestone: --- → 147 Branch
QA Whiteboard: [qa-triage-done-c148/b147]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: