if (preferredSize != null) { boolean msie = isMSIE(component); if (msie && "px".equals(preferredSize.getWidthUnit())) { int oversize = calculateHorizontalOversize(component, false); styleString .append("px;"); else if (!SDimension.AUTO.equals(preferredSize.getWidthUnit())) styleString.append("width:").append(preferredSize.getWidth()).append(';');
private static String getInitScript(SPopup popup) { String anchor = popup.isAnchored() ? popup.getAnchor().getName() : ""; String corner = popup.isAnchored() ? popup.getCorner() : ""; String name = "popup_" + popup.getName(); SDimension dim = popup.getPreferredSize(); if (dim == null) { dim = DEFAULT_DIMENSION; } String heightUnit = dim.getHeightUnit(); if (heightUnit != null && !heightUnit.equals("px")) { throw new IllegalStateException("Only 'px' is a valid unit, but height was specified as " + dim.getHeight()); } String widthUnit = dim.getWidthUnit(); if (widthUnit != null && !widthUnit.equals("px")) { throw new IllegalStateException("Only 'px' is a valid unit, but width was specified as " + dim.getWidth()); } StringBuilder code = new StringBuilder(); code.append("if (document.getElementById('").append(popup.getName()).append("yahoo') != null) { return; }\n"); code.append(name). append(" = new wingS.Popup("). append('\'').append(popup.getName()).append("', ").append(popup.getX()).append(", ").append(popup.getY()).append(", "). append(dim.getWidthInt()).append(", "). append(dim.getHeightInt()).append(", "). append('\'').append(anchor).append("', "). append('\'').append(corner).append('\''). append(");"); code.append(name).append(".show();"); return code.toString(); }
SDimension preferredSize = component.getPreferredSize(); if (preferredSize != null) { String widthUnit = preferredSize.getWidthUnit(); if (!SDimension.AUTO.equals(widthUnit)) { if (percentageUnitOnly && !"%".equals(widthUnit))
@Override public void writeInternal(Device device, final XRichTextEditor component) throws IOException { SDimension preferredSize = component.getPreferredSize(); boolean tableWrapping = Utils.isMSIE(component) && preferredSize != null && "%".equals(preferredSize.getWidthUnit()); if (tableWrapping) { String actualWidth = preferredSize.getWidth();
boolean tableWrapping = Utils.isMSIE(component) && preferredSize != null && "%".equals(preferredSize.getWidthUnit()); String actualWidth = null; if (tableWrapping) {
boolean ieTableWrapping = Utils.isMSIE(component) && preferredSize != null && "%".equals(preferredSize.getWidthUnit()); String actualWidth = null; if (ieTableWrapping) {
boolean tableWrapping = Utils.isMSIE(component) && preferredSize != null && "%".equals(preferredSize.getWidthUnit()); String actualWidth = null; if (tableWrapping) {