Commit 166ac5f1 authored by adele's avatar adele

LayoutTests:

        Reviewed by Hyatt.

        Test for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php

        * fast/forms/control-restrict-line-height-expected.checksum: Added.
        * fast/forms/control-restrict-line-height-expected.png: Added.
        * fast/forms/control-restrict-line-height-expected.txt: Added.
        * fast/forms/control-restrict-line-height.html: Added.

WebCore:

        Reviewed by Hyatt.

        Fix for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php
        
        Test: fast/forms/control-restrict-line-height.html

        * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::setFontFromControlSize): Don't honor line-height for controls that
          have restricted font size.



git-svn-id: svn://svn.chromium.org/blink/trunk@18993 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 3f454843
2007-01-19 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
Test for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php
* fast/forms/control-restrict-line-height-expected.checksum: Added.
* fast/forms/control-restrict-line-height-expected.png: Added.
* fast/forms/control-restrict-line-height-expected.txt: Added.
* fast/forms/control-restrict-line-height.html: Added.
2007-01-19 Darin Adler <darin@apple.com> 2007-01-19 Darin Adler <darin@apple.com>
Reviewed by Adele. Reviewed by Adele.
ee2bc86eb2f43790d4c2d8b8c714e02d
\ No newline at end of file
layer at (0,0) size 800x600
RenderView at (0,0) size 800x600
layer at (0,0) size 800x600
RenderBlock {HTML} at (0,0) size 800x600
RenderBody {BODY} at (8,8) size 784x584
RenderText {#text} at (0,0) size 519x18
text run at (0,0) width 519: "This tests that we don't honor line-height for controls that have restricted font size. "
RenderBR {BR} at (0,0) size 0x0
RenderMenuList {SELECT} at (2,20) size 309x18 [bgcolor=#FFFFFF]
RenderBlock (anonymous) at (8,2) size 278x13
RenderText at (0,0) size 280x13
text run at (0,0) width 280: "This text should be centered vertically in the button"
RenderText {#text} at (313,19) size 4x18
text run at (313,19) width 4: " "
RenderBR {BR} at (0,0) size 0x0
RenderButton {INPUT} at (2,42) size 296x18 [bgcolor=#C0C0C0]
RenderBlock (anonymous) at (8,2) size 280x13
RenderText at (0,0) size 280x13
text run at (0,0) width 280: "This text should be centered vertically in the button"
RenderText {#text} at (300,41) size 4x18
text run at (300,41) width 4: " "
RenderBR {BR} at (0,0) size 0x0
RenderTextControl {INPUT} at (2,64) size 148x19 [bgcolor=#FFFFFF] [border: (2px inset #000000)]
RenderBlock {DIV} at (3,3) size 142x13
RenderBlock {DIV} at (0,0) size 8x11
RenderBlock {DIV} at (129,0) size 13x11
RenderText {#text} at (0,0) size 0x0
RenderText {#text} at (0,0) size 0x0
layer at (21,75) size 121x13 scrollWidth 282
RenderBlock {DIV} at (8,0) size 121x13
RenderText {#text} at (1,0) size 280x13
text run at (1,0) width 280: "This text should be centered vertically in the button"
<html>
<head>
<style>
.tall {
line-height: 20pt;
}
</style>
</head>
<body>
This tests that we don't honor line-height for controls that have restricted font size.
<br>
<select class="tall">
<option selected="selected">This text should be centered vertically in the button</option>
</select>
<br>
<input type="button" class="tall" value="This text should be centered vertically in the button"></input>
<br>
<input type="search" class="tall" value="This text should be centered vertically in the button"></input>
</body>
</html>
2007-01-19 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
Fix for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php
Test: fast/forms/control-restrict-line-height.html
* rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::setFontFromControlSize): Don't honor line-height for controls that
have restricted font size.
2007-01-19 Darin Adler <darin@apple.com> 2007-01-19 Darin Adler <darin@apple.com>
Reviewed by Adele. Reviewed by Adele.
......
...@@ -352,6 +352,9 @@ void RenderThemeMac::setFontFromControlSize(CSSStyleSelector* selector, RenderSt ...@@ -352,6 +352,9 @@ void RenderThemeMac::setFontFromControlSize(CSSStyleSelector* selector, RenderSt
fontDescription.setComputedSize([font pointSize]); fontDescription.setComputedSize([font pointSize]);
fontDescription.setSpecifiedSize([font pointSize]); fontDescription.setSpecifiedSize([font pointSize]);
// Reset line height
style->setLineHeight(RenderStyle::initialLineHeight());
if (style->setFontDescription(fontDescription)) if (style->setFontDescription(fontDescription))
style->font().update(); style->font().update();
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment