]> source.dussan.org Git - vaadin-framework.git/commitdiff
Fixes #3028: CheckBox captions wrap in IE
authorJouni Koivuviita <jouni.koivuviita@itmill.com>
Thu, 3 Sep 2009 12:01:31 +0000 (12:01 +0000)
committerJouni Koivuviita <jouni.koivuviita@itmill.com>
Thu, 3 Sep 2009 12:01:31 +0000 (12:01 +0000)
svn changeset:8652/svn branch:6.1

WebContent/VAADIN/themes/base/button/button.css
WebContent/VAADIN/themes/base/styles.css
WebContent/VAADIN/themes/reindeer/styles.css
WebContent/VAADIN/themes/runo/styles.css
src/com/vaadin/terminal/gwt/client/ui/VCheckBox.java

index 4e5c032af085aa59a90888c9012d891cc5b7e88a..9dbc5e8309f03f64faca18fbda5dde92e0813001 100644 (file)
 \r
 .v-checkbox,\r
 .v-checkbox label,\r
-.v-checkbox input {\r
+.v-checkbox input,\r
+.v-checkbox .v-icon {\r
        vertical-align: middle;\r
        white-space: nowrap;\r
 }\r
-.v-checkbox img {\r
-       display: inline;\r
-       vertical-align: middle;\r
-       margin-right: 3px;\r
+.v-checkbox .v-icon {\r
+       margin: 0 2px;\r
 }\r
 .v-checkbox .v-errorindicator {\r
        float: none;\r
        display: inline;\r
-       padding-left: 1em;\r
-       background-position: left;\r
-}\r
-/* Error indicator on checkbox fix for IE6 */\r
-.v-ie6 .v-checkbox * {\r
-       float: left;\r
-       display: inline; /* In effect, does nothing, since float:left forces block-rendering, but will fix "double-float-margin-bug" */\r
-}\r
-.v-ie6 .v-checkbox .v-errorindicator {\r
-       background-position: right;\r
-       display: inline;\r
-       float: left;\r
-       padding-left: 0; \r
-       padding-right: 0.4em;\r
-}\r
-/* Error indicator on checkbox fix for IE7 */\r
-.v-ie7 .v-checkbox *,\r
-.v-ie8 .v-checkbox * {\r
-       float: left;\r
-}\r
-.v-ie7 .v-checkbox .v-errorindicator,\r
-.v-ie8 .v-checkbox .v-errorindicator {\r
-       background-position: right;\r
-       float: left;\r
-       padding-left: 0;\r
-       padding-right: 0.7em;\r
+       display: inline-block;\r
+       zoom: 1;\r
 }\r
 \r
 \r
index def4572a0058f024d54fd9e72b0164d6f02bfc1f..2a7f98294890ed311f42c7a5f76462ebe377275b 100644 (file)
 
 .v-checkbox,
 .v-checkbox label,
-.v-checkbox input {
+.v-checkbox input,
+.v-checkbox .v-icon {
        vertical-align: middle;
        white-space: nowrap;
 }
-.v-checkbox img {
-       display: inline;
-       vertical-align: middle;
-       margin-right: 3px;
+.v-checkbox .v-icon {
+       margin: 0 2px;
 }
 .v-checkbox .v-errorindicator {
        float: none;
        display: inline;
-       padding-left: 1em;
-       background-position: left;
-}
-/* Error indicator on checkbox fix for IE6 */
-.v-ie6 .v-checkbox * {
-       float: left;
-       display: inline; /* In effect, does nothing, since float:left forces block-rendering, but will fix "double-float-margin-bug" */
-}
-.v-ie6 .v-checkbox .v-errorindicator {
-       background-position: right;
-       display: inline;
-       float: left;
-       padding-left: 0; 
-       padding-right: 0.4em;
-}
-/* Error indicator on checkbox fix for IE7 */
-.v-ie7 .v-checkbox *,
-.v-ie8 .v-checkbox * {
-       float: left;
-}
-.v-ie7 .v-checkbox .v-errorindicator,
-.v-ie8 .v-checkbox .v-errorindicator {
-       background-position: right;
-       float: left;
-       padding-left: 0;
-       padding-right: 0.7em;
+       display: inline-block;
+       zoom: 1;
 }
 
 
index 368b2808f874f147a50aef42d80f29080b6c10c4..0844706e39cb30a535d6c3f115e76e860f3557e0 100644 (file)
 
 .v-checkbox,
 .v-checkbox label,
-.v-checkbox input {
+.v-checkbox input,
+.v-checkbox .v-icon {
        vertical-align: middle;
        white-space: nowrap;
 }
-.v-checkbox img {
-       display: inline;
-       vertical-align: middle;
-       margin-right: 3px;
+.v-checkbox .v-icon {
+       margin: 0 2px;
 }
 .v-checkbox .v-errorindicator {
        float: none;
        display: inline;
-       padding-left: 1em;
-       background-position: left;
-}
-/* Error indicator on checkbox fix for IE6 */
-.v-ie6 .v-checkbox * {
-       float: left;
-       display: inline; /* In effect, does nothing, since float:left forces block-rendering, but will fix "double-float-margin-bug" */
-}
-.v-ie6 .v-checkbox .v-errorindicator {
-       background-position: right;
-       display: inline;
-       float: left;
-       padding-left: 0; 
-       padding-right: 0.4em;
-}
-/* Error indicator on checkbox fix for IE7 */
-.v-ie7 .v-checkbox *,
-.v-ie8 .v-checkbox * {
-       float: left;
-}
-.v-ie7 .v-checkbox .v-errorindicator,
-.v-ie8 .v-checkbox .v-errorindicator {
-       background-position: right;
-       float: left;
-       padding-left: 0;
-       padding-right: 0.7em;
+       display: inline-block;
+       zoom: 1;
 }
 
 
index 957913d450ef7bd3f01abbbbc4976ab43e0c05cb..fb1523b970763db691212a5b8311780f91899480 100644 (file)
 
 .v-checkbox,
 .v-checkbox label,
-.v-checkbox input {
+.v-checkbox input,
+.v-checkbox .v-icon {
        vertical-align: middle;
        white-space: nowrap;
 }
-.v-checkbox img {
-       display: inline;
-       vertical-align: middle;
-       margin-right: 3px;
+.v-checkbox .v-icon {
+       margin: 0 2px;
 }
 .v-checkbox .v-errorindicator {
        float: none;
        display: inline;
-       padding-left: 1em;
-       background-position: left;
-}
-/* Error indicator on checkbox fix for IE6 */
-.v-ie6 .v-checkbox * {
-       float: left;
-       display: inline; /* In effect, does nothing, since float:left forces block-rendering, but will fix "double-float-margin-bug" */
-}
-.v-ie6 .v-checkbox .v-errorindicator {
-       background-position: right;
-       display: inline;
-       float: left;
-       padding-left: 0; 
-       padding-right: 0.4em;
-}
-/* Error indicator on checkbox fix for IE7 */
-.v-ie7 .v-checkbox *,
-.v-ie8 .v-checkbox * {
-       float: left;
-}
-.v-ie7 .v-checkbox .v-errorindicator,
-.v-ie8 .v-checkbox .v-errorindicator {
-       background-position: right;
-       float: left;
-       padding-left: 0;
-       padding-right: 0.7em;
+       display: inline-block;
+       zoom: 1;
 }
 
 
index ec460d1e5e9964990af72efa05832261be5ac7a5..3bd6f656f26a8e3067d7b9abc36353472ed1e3d1 100644 (file)
@@ -65,7 +65,7 @@ public class VCheckBox extends com.google.gwt.user.client.ui.CheckBox implements
 
         if (uidl.hasAttribute("error")) {
             if (errorIndicatorElement == null) {
-                errorIndicatorElement = DOM.createDiv();
+                errorIndicatorElement = DOM.createSpan();
                 errorIndicatorElement.setInnerHTML("&nbsp;");
                 DOM.setElementProperty(errorIndicatorElement, "className",
                         "v-errorindicator");