- From: <bugzilla@jessica.w3.org>
- Date: Thu, 06 Dec 2012 17:19:59 +0000
- To: www-validator-cvs@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=20277
Bug ID: 20277
Summary: Incorrect implementation of
CssBackgroundPositionValue.toString()
Classification: Unclassified
Product: CSSValidator
Version: CSS Validator
Hardware: All
OS: All
Status: NEW
Severity: major
Priority: P2
Component: Parser
Assignee: dave.null@w3.org
Reporter: hannes+w3cbugs@erven.at
QA Contact: www-validator-cvs@w3.org
The current code swaps the horizonal and vertical offsets in its toString()
output.
Here's a patch for the file
org/w3c/css/properties/css3/CssBackgroundPosition.java :
Index: CssBackgroundPosition.java
===================================================================
--- CssBackgroundPosition.java (revision 8290)
+++ CssBackgroundPosition.java (working copy)
@@ -439,21 +439,22 @@
public String toString() {
StringBuilder sb = new StringBuilder();
+ if (horizontal != null) {
+ sb.append(horizontal);
+ if (horizontal_offset != null) {
+ sb.append(' ').append(horizontal_offset);
+ }
+ if (vertical != null) {
+ sb.append(' ');
+ }
+ }
+
if (vertical != null) {
sb.append(vertical);
if (vertical_offset != null) {
sb.append(' ').append(vertical_offset);
}
- if (horizontal != null) {
- sb.append(' ');
- }
}
- if (horizontal != null) {
- sb.append(horizontal);
- if (horizontal_offset != null) {
- sb.append(' ').append(horizontal_offset);
- }
- }
return sb.toString();
}
}
--
You are receiving this mail because:
You are the QA Contact for the bug.
Received on Thursday, 6 December 2012 17:20:02 UTC