\r
public void updateFromUIDL(UIDL uidl, ApplicationConnection client) {\r
rendering = true;\r
-\r
+ boolean measure = false;\r
if (this.client == null) {\r
this.client = client;\r
- borderPaddingVertical = getOffsetHeight();\r
- borderPaddingHorizontal = getOffsetWidth() - desc.getOffsetWidth();\r
+ measure = true;\r
}\r
\r
if (client.updateComponent(this, uidl, false)) {\r
return;\r
}\r
\r
+ if (measure) {\r
+ // Measure the border when the style names have been set\r
+ borderPaddingVertical = getOffsetHeight();\r
+ int ow = getOffsetWidth();\r
+ int dow = desc.getOffsetWidth();\r
+ borderPaddingHorizontal = ow - dow;\r
+ }\r
+\r
boolean legendEmpty = true;\r
if (uidl.hasAttribute("caption")) {\r
DOM.setInnerText(caption, uidl.getStringAttribute("caption"));\r