Open Bug 369581 Opened 18 years ago Updated 2 years ago

'height:auto' non-box frames don't respect height of overridable nsITheme::GetMinimumWidgetSize

Categories

(Core :: Layout, defect)

defect

Tracking

()

People

(Reporter: dbaron, Unassigned)

References

Details

Attachments

(2 files, 2 obsolete files)

non-box frames with 'height: auto' (such as buttons) don't respect the height part of the result from nsITheme::GetMinimumWidgetSize when the canOverride out parameter is true.  This is because nsFrame::ComputeSize doesn't adjust a height that it NS_UNCONSTRAINEDSIZE.

I think the way we need to fix this is to set mComputedMinHeight in the reflow state.
Blocks: 369584
Attached patch patch (obsolete) — Splinter Review
I think this should work.  It's against a tree from before Eli landed last night, and requires merging.
Attached patch patch (obsolete) — Splinter Review
Merged with bug 177805.
Attachment #254347 - Attachment is obsolete: true
Attached patch patchSplinter Review
Fix the comment too.
Attachment #254365 - Attachment is obsolete: true
Patch doesn't seem to work for me. I am specifying a minimum height of 20 for buttons and I am still getting native buttons with frame heights < 20.
Attached patch test patch v1.0Splinter Review
If you apply this simple patch to a Firefox tree and then visit bugzilla.mozilla.org (the main page) you'll see button frames that are smaller then the minimum size specified. You can see that the button draws outside of the frame because it cannot draw smaller.
Blocks: 540078
Product: Core → Core Graveyard
Component: Layout: Misc Code → Layout
Product: Core Graveyard → Core
Assignee: dbaron → nobody
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: