https://bugs.webkit.org/show_bug.cgi?id=86784
Reviewed by Kent Tamura.
Source/WebCore:
Fixed the bug by removing the code that added left and right paddings in input elements.
The code was added in r13567 to match a very old version of Internet Explorer but this quirk
does not seem to exists in IE9 (both in quirks and standard modes).
A lot of tests need to be rebaselined due to 1px difference inside input elements, and 2px
differences for the width of input elements. (In some extreme cases, line breaking changed
due to the width change).
Test: fast/forms/input-textarea-padding-match.html
* css/html.css:
(input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
* rendering/RenderTextControlSingleLine.cpp:
(WebCore::RenderTextControlSingleLine::createInnerTextStyle):
LayoutTests:
Add a regression.
Also rebaseline tests in separate commits per getting rid of extra 1px padding on left and right.
Input elements' widths got shrunk by 2px in most cases and the text moved 1px to the start
(left for LTR and right for RTL).
* fast/forms/input-textarea-padding-match-expected.html: Added.
* fast/forms/input-textarea-padding-match.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@117556
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2012-05-17 Ryosuke Niwa <rniwa@webkit.org>
+
+ WebKit erroneously add 1px padding in input elements
+ https://bugs.webkit.org/show_bug.cgi?id=86784
+
+ Reviewed by Kent Tamura.
+
+ Add a regression.
+
+ Also rebaseline tests in separate commits per getting rid of extra 1px padding on left and right.
+ Input elements' widths got shrunk by 2px in most cases and the text moved 1px to the start
+ (left for LTR and right for RTL).
+
+ * fast/forms/input-textarea-padding-match-expected.html: Added.
+ * fast/forms/input-textarea-padding-match.html: Added.
+
2012-05-18 Ryosuke Niwa <rniwa@webkit.org>
Chromium rebaselines.
--- /dev/null
+<!DOCTYPE html>
+<html>
+<body>
+<p>This test ensures padding inside input and textarea elements match.</p>
+<style type="text/css">
+textarea {
+ display: block;
+ font-family: arial,sans-serif;
+ border: none;
+ padding: 0 0 0 10px;
+ margin: 0;
+ resize: none;
+ width: 20px;
+ height: 10px;
+ overflow: hidden;
+}
+</style>
+<textarea>|</textarea>
+</body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<html>
+<body>
+<p>This test ensures padding inside input and textarea elements match.</p>
+<style type="text/css">
+input {
+ display: block;
+ font-family: arial,sans-serif;
+ border: none;
+ padding: 0 0 0 10px;
+ margin: 0;
+ resize: none;
+ width: 20px;
+ height: 10px;
+ overflow: hidden;
+}
+</style>
+<input type="text" value="|">
+</body>
+</html>
+2012-05-17 Ryosuke Niwa <rniwa@webkit.org>
+
+ WebKit erroneously add 1px padding in input elements
+ https://bugs.webkit.org/show_bug.cgi?id=86784
+
+ Reviewed by Kent Tamura.
+
+ Fixed the bug by removing the code that added left and right paddings in input elements.
+ The code was added in r13567 to match a very old version of Internet Explorer but this quirk
+ does not seem to exists in IE9 (both in quirks and standard modes).
+
+ A lot of tests need to be rebaselined due to 1px difference inside input elements, and 2px
+ differences for the width of input elements. (In some extreme cases, line breaking changed
+ due to the width change).
+
+ Test: fast/forms/input-textarea-padding-match.html
+
+ * css/html.css:
+ (input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
+ * rendering/RenderTextControlSingleLine.cpp:
+ (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
+
2012-05-18 Zalan Bujtas <zbujtas@gmail.com>
[Qt] Gesture tap highlighter needs to take overflow clip into account.
white-space: pre;
word-wrap: normal;
overflow: hidden;
- padding-left: 1px;
- padding-right: 1px;
}
input[type="password"] {
textBlockStyle->setDisplay(BLOCK);
- // We're adding one extra pixel of padding to match WinIE.
- textBlockStyle->setPaddingLeft(Length(1, Fixed));
- textBlockStyle->setPaddingRight(Length(1, Fixed));
-
return textBlockStyle.release();
}