Closed Bug 89791 Opened 23 years ago Closed 23 years ago

if-else cascade cleanup

Categories

(Core :: Layout: Text and Fonts, defect, P1)

defect

Tracking

()

VERIFIED FIXED
mozilla0.9.4

People

(Reporter: drepper, Assigned: dbaron)

Details

Attachments

(2 files)

I came across this while reading the code.  The nsTextFrame::Paint function
currently contains a mess of if-else cases to decide whether PaintUnicodeText or
PaintAsciiText has to be used.  This mess cannot be cleaned up automatically by
the compiler (at least gcc cannot do it).  I'll attach a patch now which cleans
this code up and makes it IMO much more readable.  It saves 76 bytes on x86 :-).
Keywords: patch
Keywords: review
I guess I'll try to get this in.
Assignee: karnaze → dbaron
Component: Layout → BiDi Hebrew & Arabic
Priority: -- → P1
Target Milestone: --- → mozilla0.9.3
Am I missing something amid the convoluted logic here or did you remove the test
of |(hints & NS_RENDERING_HINT_FAST_8BIT_TEXT)|?
Status: NEW → ASSIGNED
r/sr=waterson
Yep, that's what I ended up with after merging the if clauses.

r=jag
Target Milestone: mozilla0.9.3 → mozilla0.9.4
Fix checked in 2001-07-31 20:10 PDT.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Since I 'm not exactly sure how to test this, I'm marking verified based on the
last comments.

Status: RESOLVED → VERIFIED
Component: Layout: BiDi Hebrew & Arabic → Layout: Text
QA Contact: chrispetersen → layout.fonts-and-text
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: