本文整理匯總了Java中com.google.gwt.user.client.ui.HTML.setStylePrimaryName方法的典型用法代碼示例。如果您正苦於以下問題:Java HTML.setStylePrimaryName方法的具體用法?Java HTML.setStylePrimaryName怎麽用?Java HTML.setStylePrimaryName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.google.gwt.user.client.ui.HTML
的用法示例。
在下文中一共展示了HTML.setStylePrimaryName方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: MotdUi
import com.google.gwt.user.client.ui.HTML; //導入方法依賴的package包/類
/**
* Creates a new output panel for MOTD.
*/
private MotdUi() {
// Initialize UI
text = new HTML();
text.setSize("100%", "100%");
text.setStylePrimaryName("ode-Motd");
panel = new VerticalPanel();
panel.add(text);
panel.setSize("100%", "100%");
panel.setCellHeight(text, "100%");
panel.setCellWidth(text, "100%");
initWidget(panel);
}
示例2: MessagesOutput
import com.google.gwt.user.client.ui.HTML; //導入方法依賴的package包/類
/**
* Creates a new output panel for messages.
*/
private MessagesOutput() {
// Initialize UI
text = new HTML();
text.setSize("100%", "100%");
text.setStylePrimaryName("ode-MessagesOutput");
panel = new VerticalPanel();
panel.add(text);
panel.setSize("100%", "100%");
panel.setCellHeight(text, "100%");
panel.setCellWidth(text, "100%");
initWidget(panel);
}
示例3: createWidget
import com.google.gwt.user.client.ui.HTML; //導入方法依賴的package包/類
@Override
public HTML createWidget() {
HTML b = GWT.create(HTML.class);
b.addClickHandler(this);
b.setStylePrimaryName("v-nativelabel");
return b;
}
示例4: createWidget
import com.google.gwt.user.client.ui.HTML; //導入方法依賴的package包/類
/**
* dirty hack - before we fire onClick we keep last clicked button because of the lost of RelativeElement during converting and the
* issue of different layouts
*/
@Override
public FlowPanel createWidget() {
FlowPanel buttonBar = GWT.create(FlowPanel.class);
buttonBar.setStylePrimaryName("v-button-bar");
int buttonsAdded = 0;
if ((this.buttonBITM & VIEW_BITM) != 0) {
buttonBar.add(genButton(VIEW_BITM));
buttonsAdded++;
}
if ((this.buttonBITM & EDIT_BITM) != 0) {
buttonBar.add(genButton(EDIT_BITM));
buttonsAdded++;
}
if ((this.buttonBITM & DELETE_BITM) != 0) {
buttonBar.add(genButton(DELETE_BITM));
buttonsAdded++;
}
FlowPanel panel = GWT.create(FlowPanel.class);
panel.setStylePrimaryName(STYLE_NAME);
if (buttonsAdded == 3) {
panel.addStyleName("three-buttons");
} else if (buttonsAdded == 2) {
panel.addStyleName("two-buttons");
} else {
panel.addStyleName("one-button");
}
panel.add(buttonBar);
HTML valueLabel = GWT.create(HTML.class);
valueLabel.setStylePrimaryName("v-cell-value");
panel.add(valueLabel);
return panel;
}