本文整理匯總了Java中com.google.gwt.dom.client.Style.setPaddingRight方法的典型用法代碼示例。如果您正苦於以下問題:Java Style.setPaddingRight方法的具體用法?Java Style.setPaddingRight怎麽用?Java Style.setPaddingRight使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.google.gwt.dom.client.Style
的用法示例。
在下文中一共展示了Style.setPaddingRight方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: QuickDocViewImpl
import com.google.gwt.dom.client.Style; //導入方法依賴的package包/類
@Inject
public QuickDocViewImpl() {
super(true, true);
addCloseHandler(
new CloseHandler<PopupPanel>() {
@Override
public void onClose(CloseEvent<PopupPanel> event) {
if (delegate != null) {
delegate.onCloseView();
}
}
});
setSize("400px", "200px");
Style style = getElement().getStyle();
style.setProperty("resize", "both");
style.setPaddingBottom(0, Style.Unit.PX);
style.setPaddingTop(3, Style.Unit.PX);
style.setPaddingLeft(3, Style.Unit.PX);
style.setPaddingRight(3, Style.Unit.PX);
createFrame();
add(frame);
}
示例2: TextBoxDOMElement
import com.google.gwt.dom.client.Style; //導入方法依賴的package包/類
public TextBoxDOMElement(final TextBox widget,
final GridLayer gridLayer,
final GridWidget gridWidget) {
super(widget,
gridLayer,
gridWidget);
final Style style = widget.getElement().getStyle();
style.setWidth(100,
Style.Unit.PCT);
style.setHeight(HEIGHT,
Style.Unit.PX);
style.setPaddingLeft(2,
Style.Unit.PX);
style.setPaddingRight(2,
Style.Unit.PX);
style.setFontSize(10,
Style.Unit.PX);
// --- Workaround for BS2 ---
style.setPosition(Style.Position.RELATIVE);
style.setPaddingTop(0,
Style.Unit.PX);
style.setPaddingBottom(0,
Style.Unit.PX);
style.setProperty("WebkitBoxSizing",
"border-box");
style.setProperty("MozBoxSizing",
"border-box");
style.setProperty("boxSizing",
"border-box");
style.setProperty("lineHeight",
"normal");
// --- End workaround ---
getContainer().getElement().getStyle().setPaddingLeft(5,
Style.Unit.PX);
getContainer().getElement().getStyle().setPaddingRight(5,
Style.Unit.PX);
getContainer().setWidget(widget);
}
示例3: ListBoxDOMElement
import com.google.gwt.dom.client.Style; //導入方法依賴的package包/類
public ListBoxDOMElement(final ListBox widget,
final GridLayer gridLayer,
final GridWidget gridWidget) {
super(widget,
gridLayer,
gridWidget);
final Style style = widget.getElement().getStyle();
style.setWidth(100,
Style.Unit.PCT);
style.setHeight(HEIGHT,
Style.Unit.PX);
style.setPaddingLeft(2,
Style.Unit.PX);
style.setPaddingRight(2,
Style.Unit.PX);
style.setFontSize(10,
Style.Unit.PX);
// --- Workaround for BS2 ---
style.setPosition(Style.Position.RELATIVE);
style.setPaddingTop(0,
Style.Unit.PX);
style.setPaddingBottom(0,
Style.Unit.PX);
style.setProperty("WebkitBoxSizing",
"border-box");
style.setProperty("MozBoxSizing",
"border-box");
style.setProperty("boxSizing",
"border-box");
style.setProperty("lineHeight",
"normal");
// --- End workaround ---
getContainer().getElement().getStyle().setPaddingLeft(5,
Style.Unit.PX);
getContainer().getElement().getStyle().setPaddingRight(5,
Style.Unit.PX);
getContainer().setWidget(widget);
}