本文整理匯總了Java中com.google.gwt.user.client.ui.VerticalPanel.setStyleName方法的典型用法代碼示例。如果您正苦於以下問題:Java VerticalPanel.setStyleName方法的具體用法?Java VerticalPanel.setStyleName怎麽用?Java VerticalPanel.setStyleName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.google.gwt.user.client.ui.VerticalPanel
的用法示例。
在下文中一共展示了VerticalPanel.setStyleName方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: initializeStatusPanel
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
private void initializeStatusPanel() {
String comboWidth = "125px";
statusPanel = new VerticalPanel();
StyleInjector.inject(".statusPanelStyle { " + "background: #E0ECF8;"
+ "border-radius: 5px 10px;" + "opacity: 0.8}");
statusPanel.setStyleName("statusPanelStyle");
statusPanel.setSpacing(5);
statusPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
initializeLayerCombo(comboWidth);
initializeEpsgCombo(comboWidth);
initializeStatusGrid();
statusPanel.add(new FieldLabel(layerCombo, UIMessages.INSTANCE
.sbSelectLayerLabel()));
statusPanel.add(new FieldLabel(epsgCombo, UIMessages.INSTANCE
.sbEpsgLabel()));
statusPanel.add(statusGrid);
statusPanel.setVisible(false);
}
示例2: MockListView
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* Creates a new MockListView component. It places a label inside a simplepanel which
* is then placed into a vertical panel
*
* @param editor editor of source file the component belongs to
*/
public MockListView(SimpleEditor editor) {
super(editor, TYPE, images.listview());
listViewWidget = new VerticalPanel();
//TODO (Jose) extract magic numbers as ComponentConstants.java
listViewWidget.setSize(ComponentConstants.LISTVIEW_PREFERRED_WIDTH + "px", "100%");
listViewWidget.setStylePrimaryName("ode-SimpleMockComponent");
listViewWidget.setStyleName("listViewComponentStyle", true);
createFilterBox();
// textColor must be set before the component is initialized, because onPropertyChange
// might call setSlementsFromString, which tries to set the item textcolor
textColor = DEFAULT_TEXT_COLOR;
initComponent(listViewWidget);
MockComponentsUtil.setWidgetBackgroundColor(listViewWidget, DEFAULT_BACKGROUND_COLOR);
}
示例3: Browser
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* Browser
*/
public Browser() {
verticalSplitLayoutPanel = new VerticalSplitLayoutExtended(new VerticalResizeHandler() {
@Override
public void onResize(int topHeight, int bottomHeight) {
resizePanels();
}
});
fileBrowser = new FileBrowser();
tabPropertiesPanel = new VerticalPanel();
tabMultiple = new TabMultiple();
tabPropertiesPanel.add(tabMultiple);
tabPropertiesPanel.setStyleName("okm-Properties-Tab");
verticalSplitLayoutPanel.getSplitPanel().addNorth(fileBrowser, 300);
verticalSplitLayoutPanel.getSplitPanel().add(tabPropertiesPanel);
initWidget(verticalSplitLayoutPanel);
}
示例4: information
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* Standard information dialog with prompt and "OK" button.
*
* @param message message to display
*/
public static void information(String message) {
PopupChrome chrome = PopupChromeFactory.createPopupChrome();
final UniversalPopup popup = PopupFactory.createPopup(RootPanel.getBodyElement(),
new CenterPopupPositioner(), chrome, true);
VerticalPanel verticalPanel = new VerticalPanel();
verticalPanel.setStyleName(Dialog.getCss().verticalPanel());
Label label = new Label(message);
verticalPanel.add(label);
DialogButton okButton = new DialogButton(messages.ok(), new Command() {
@Override
public void execute() {
popup.hide();
}
});
DialogBox.create(popup, messages.confirmation(), verticalPanel,
new DialogButton[] { okButton });
popup.show();
requestFocus(okButton.getButton());
}
示例5: loadLayoutStructure
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
private void loadLayoutStructure() {
page = new VerticalPanel();
mainView = new HorizontalPanel();
leftPanel = new VerticalPanel();
mainView.setStyleName("mainViewLayer");
mainView.setWidth("100%");
leftPanel.setStyleName("leftPanelLayer");
leftPanel.setWidth("700px");
page.setWidth("100%");
Label title = new Label("Import configuration");
title.setStyleName("title");
//Main layout
page.add(title);
page.add(mainView);
//Left layout
mainView.add(leftPanel);
grid = new Grid(1,2);
grid.setCellPadding(5);
leftPanel.add(grid);
}
示例6: createComponentDetailsWidget
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
@SuppressWarnings("rawtypes")
@Override
protected Widget createComponentDetailsWidget() {
VerticalPanel layout = new VerticalPanel();
layout.setStyleName("fill-layout-width"); //$NON-NLS-1$
layout.add(new ContentGroupLabel(MESSAGES.label_configuredProperties()));
String title = MESSAGES.label_socketAddress(SOCKET_ADDR);
_socketAddr = new TextItem(SOCKET_ADDR, title) {
@Override
public void setValue(String value) {
if (value == null || value.length() == 0) {
value = MESSAGES.constant_notSet();
}
super.setValue(value);
}
};
RenderMetaData metaData = new RenderMetaData();
metaData.setNumColumns(1);
metaData.setTitleWidth(title.length());
layout.add(new DefaultGroupRenderer().render(metaData, "null", //$NON-NLS-1$
Collections.<String, FormItem> singletonMap(SOCKET_ADDR, _socketAddr)));
return layout;
}
示例7: generateIndicatorWidget
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
protected Widget generateIndicatorWidget(JSONObject v) {
VerticalPanel panel = new VerticalPanel();
GaugeImage img = new GaugeImage();
img.setEvidence( v.get( "p" ).isString().stringValue(), v.get( "m" ).isString().stringValue() );
SimplePanel pp = new SimplePanel();
pp.setWidget(img);
pp.setStyleName("contentResultsTable");
panel.add(pp);
panel.add( new HTML(
"Exposure: <font color='red'>" +
v.get( "e" ).isObject().get( "e" ).isNumber().doubleValue() +
"</font>") );
panel.setStyleName("headerTable");
panel.setHeight("100%");
return panel;
}
示例8: asWidget
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
@Override
public Widget asWidget() {
if (_widget == null) {
VerticalPanel layout = new VerticalPanel();
layout.setStyleName("fill-layout-width"); //$NON-NLS-1$
_componentNameLabel = createComponentNameLabel();
if (_componentNameLabel != null) {
layout.add(_componentNameLabel);
}
Widget details = createComponentDetailsWidget();
if (details != null) {
layout.add(details);
}
_widget = layout;
}
return _widget;
}
示例9: setSelectedRiskSes
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
private void setSelectedRiskSes(String name, int k) {
newName.setText("");
g.setWidget(2, 0, null);
g.setWidget(2, 1, null);
g.setWidget(2, 2, null);
selectedRiskSession = name;
elem = k;
page.clear();
top.remove(g);
vPanel = new VerticalPanel();
vPanel.setStyleName("leftPanelLayer");
rasPanel = new RASPanel(this);
rasPanel.loadRAS(list.get(k).getId());
vPanel.add(rasPanel);
title.setText(selectedRiskSession);
page.add(vPanel);
}
示例10: AbstractDataTable
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
protected AbstractDataTable(String label) {
_layout = new VerticalPanel();
_layout.setStyleName("fill-layout-width"); //$NON-NLS-1$
_layout.getElement().setAttribute("style", "padding-top:5px;"); //$NON-NLS-1$ //$NON-NLS-2$
_table = new DefaultCellTable<T>(5);
ProvidesKey<T> keyProvider = createKeyProvider();
_selectionModel = createSelectionModel(keyProvider);
_table.setSelectionModel(_selectionModel);
_dataProvider = new ListDataProvider<T>(keyProvider);
_dataProvider.addDataDisplay(_table);
createColumns(_table, _dataProvider);
DefaultPager pager = new DefaultPager();
pager.setDisplay(_table);
_layout.add(new ContentGroupLabel(label));
_layout.add(_table);
_layout.add(pager);
}
示例11: createComponentDetailsWidget
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
@SuppressWarnings("rawtypes")
@Override
protected Widget createComponentDetailsWidget() {
VerticalPanel layout = new VerticalPanel();
layout.setStyleName("fill-layout-width"); //$NON-NLS-1$
layout.add(new ContentGroupLabel(MESSAGES.label_configuredProperties()));
String title = MESSAGES.label_cacheName(CACHE_NAME);
_cacheName = new TextItem(CACHE_NAME, title) {
@Override
public void setValue(String value) {
if (value == null || value.length() == 0) {
value = MESSAGES.constant_notSet();
}
super.setValue(value);
}
};
RenderMetaData metaData = new RenderMetaData();
metaData.setNumColumns(1);
metaData.setTitleWidth(title.length());
layout.add(new DefaultGroupRenderer().render(metaData, "null", //$NON-NLS-1$
Collections.<String, FormItem> singletonMap(CACHE_NAME, _cacheName)));
return layout;
}
示例12: init
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
protected void init(String msg, String title) {
this.setTitle("stdErr");
this.setGlassEnabled(true);
HTML closeButton = new HTML("X");
closeButton.setSize("10px", "10px");
closeButton.setStyleName("closebtn");
closeButton.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
StdPanel.this.hide();
}
});
ScrollPanel scvp = new ScrollPanel();
VerticalPanel verticalPanel = new VerticalPanel();
verticalPanel.add(closeButton);
verticalPanel.setCellHeight(closeButton, "30px");
verticalPanel.setStyleName("vpanel");
HTML desc = new HTML(title);
desc.setStyleName("popupTitle");
verticalPanel.add(desc);
verticalPanel.setCellHeight(desc, "30px");
TextArea label = new TextArea();
label.setText(msg);
label.setReadOnly(true);
label.setSize("650px", "400px");
verticalPanel.add(label);
scvp.add(verticalPanel);
this.add(scvp);
this.setStyleName("loading_container");
this.center();
this.show();
}
示例13: TabWorkspaceExample
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* TabWorkspaceExample
*/
public TabWorkspaceExample() {
vPanel = new VerticalPanel();
vPanel.add(new HTML("new workspace example"));
vPanel.setStyleName("okm-Input");
initWidget(vPanel);
}
示例14: FilePath
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* FilePath
*/
public FilePath() {
panel = new VerticalPanel();
path = new HTML(Main.i18n("filebrowser.path") + ": ", false);
panel.setStyleName("okm-FilePath-Title");
panel.setSize("100%", "22px");
panel.add(path);
panel.setCellVerticalAlignment(path, VerticalPanel.ALIGN_MIDDLE);
initWidget(panel);
// Only executes first time when object is created to initalize values
getRootPath();
}
示例15: confirm
import com.google.gwt.user.client.ui.VerticalPanel; //導入方法依賴的package包/類
/**
* Standard confirmation dialog with prompt, "OK" and "Cancel" buttons.
*
* @param message message to display
* @param okCommand command to be executed if OK button is pressed
*/
public static void confirm(String message, final Command okCommand) {
PopupChrome chrome = PopupChromeFactory.createPopupChrome();
final UniversalPopup popup = PopupFactory.createPopup(RootPanel.getBodyElement(),
new CenterPopupPositioner(), chrome, true);
VerticalPanel verticalPanel = new VerticalPanel();
verticalPanel.setStyleName(Dialog.getCss().verticalPanel());
Label label = new Label(message);
verticalPanel.add(label);
DialogButton okButton = new DialogButton(messages.ok(), new Command() {
@Override
public void execute() {
popup.hide();
if (okCommand != null) {
okCommand.execute();
}
}
});
DialogBox.create(popup, messages.confirmation(), verticalPanel,
new DialogButton[] { okButton, createCancelButton(popup) });
popup.show();
requestFocus(okButton.getButton());
}