Closed
Bug 1281099
Opened 9 years ago
Closed 9 years ago
Merge three bidi frame properties into one
Categories
(Core :: Layout: Text and Fonts, defect)
Core
Layout: Text and Fonts
Tracking
()
RESOLVED
FIXED
mozilla50
Tracking | Status | |
---|---|---|
firefox50 | --- | fixed |
People
(Reporter: xidorn, Assigned: xidorn)
References
Details
Attachments
(2 files)
Currently, there are three bidi-related frame properties: BaseLevelProperty, EmbeddingLevelProperty, and ParagraphDepthProperty. They are usually set and read together, and they are all 8bit integers.
We can convert them into a structure, and continue using small value property, so that we don't add any overhead. Actually it would likely make things faster because fewer properties lead to fewer calls to linear search procedure looking for properties.
This would also make it more extendable (so that we can store other infomation into this structure easier).
Assignee | ||
Comment 1•9 years ago
|
||
Review commit: https://reviewboard.mozilla.org/r/59906/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/59906/
Attachment #8763779 -
Flags: review?(jfkthame)
Attachment #8763780 -
Flags: review?(jfkthame)
Assignee | ||
Comment 2•9 years ago
|
||
Review commit: https://reviewboard.mozilla.org/r/59908/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/59908/
Assignee | ||
Comment 3•9 years ago
|
||
Comment on attachment 8763780 [details]
Bug 1281099 part 2 - Merge three bidi frame properties into one.
Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59908/diff/1-2/
Updated•9 years ago
|
Attachment #8763779 -
Flags: review?(jfkthame) → review+
Comment 4•9 years ago
|
||
Comment on attachment 8763779 [details]
Bug 1281099 part 1 - Convert some macros to functions to help later change.
https://reviewboard.mozilla.org/r/59906/#review56890
::: layout/generic/nsTextFrame.cpp:1609
(Diff revision 1)
> if (mBidiEnabled &&
> - (NS_GET_EMBEDDING_LEVEL(aFrame1) != NS_GET_EMBEDDING_LEVEL(aFrame2) ||
> - NS_GET_PARAGRAPH_DEPTH(aFrame1) != NS_GET_PARAGRAPH_DEPTH(aFrame2)))
> + (nsBidi::GetEmbeddingLevel(aFrame1) !=
> + nsBidi::GetEmbeddingLevel(aFrame2) ||
> + nsBidi::GetParagraphDepth(aFrame1) !=
> + nsBidi::GetParagraphDepth(aFrame2)))
> return false;
While you're here, might as well add the missing braces for the if-statement body -- thanks.
Assignee | ||
Comment 5•9 years ago
|
||
https://reviewboard.mozilla.org/r/59906/#review56890
> While you're here, might as well add the missing braces for the if-statement body -- thanks.
They would be added in the second patch.
Comment 6•9 years ago
|
||
Comment on attachment 8763780 [details]
Bug 1281099 part 2 - Merge three bidi frame properties into one.
https://reviewboard.mozilla.org/r/59908/#review56894
Nice!
Attachment #8763780 -
Flags: review?(jfkthame) → review+
Comment 7•9 years ago
|
||
(In reply to Xidorn Quan [:xidorn] (UTC+10) from comment #5)
> https://reviewboard.mozilla.org/r/59906/#review56890
>
> > While you're here, might as well add the missing braces for the if-statement body -- thanks.
>
> They would be added in the second patch.
So I just saw - fine, thanks!
Pushed by xquan@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/b53390fe3d19
part 1 - Convert some macros to functions to help later change. r=jfkthame
https://hg.mozilla.org/integration/mozilla-inbound/rev/1c11f8a65526
part 2 - Merge three bidi frame properties into one. r=jfkthame
Comment 9•9 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/b53390fe3d19
https://hg.mozilla.org/mozilla-central/rev/1c11f8a65526
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox50:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla50
You need to log in
before you can comment on or make changes to this bug.
Description
•