Closed Bug 539453 Opened 15 years ago Closed 12 years ago

Scrollbar up and down buttons and mouse scrollwheel doesn't scroll with "font-size: 0"

Categories

(Core :: XUL, defect)

defect
Not set
minor

Tracking

()

RESOLVED DUPLICATE of bug 422132

People

(Reporter: jkm, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.1.7) Gecko/20091221 Firefox/3.5.7 (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.1.7) Gecko/20091221 Firefox/3.5.7 (.NET CLR 3.5.30729)

The following example causes the up and down buttons on a scrollbar to stop working. The same applies for the scroll wheel. It seems that the font-size is somehow used to determine the scroll offset.

<div style="max-height: 100px; overflow-y: auto; font-size: 0;">
    <div style="height: 200px;">Content</div>
</div>

Reproducible: Always

Steps to Reproduce:
1. Add the divs from the example to a page
2. Click up or down buttons on scrollbar
3. Use scrollwheel
4. Remove "font-size: 0" style from example
5. Scroll now works
Actual Results:  
Scroll doesn't work when font-size: 0 is specified.

Expected Results:  
Normal scrolling, independent of font-size.
IIRC, we used to scroll 1px in this case.
Severity: normal → minor
Component: General → XUL
OS: Windows Vista → All
Product: Firefox → Core
QA Contact: general → xptoolkit.widgets
Hardware: x86 → All
If the line-height is 0 (less than a magic number), shouldn't we use line-height of ancestor or root?
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.