本文整理汇总了Java中com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign类的典型用法代码示例。如果您正苦于以下问题:Java LabelAlign类的具体用法?Java LabelAlign怎么用?Java LabelAlign使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
LabelAlign类属于com.extjs.gxt.ui.client.widget.form.FormPanel包,在下文中一共展示了LabelAlign类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: initUI
import com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign; //导入依赖的package包/类
private void initUI() {
// ID. (R)
// DisplayName (R)
// DerivedFrom Path. (R)
// CreateDate (R)
// LastModififed (R)
// Alias (R/W)
// DisplayNameExpr (R/W)
// GID (R/W)
// Description (R/W)
setLayout(new FlowLayout());
/*
Label label = new Label("DerivedPath: Ci/Test/Test2/Test3");
label.setHeight("20px");
add(label);
*/
setStyleName("ci-id-panel");
FormPanel form2 = new FormPanel();
form2.setFrame(false);
form2.setHeaderVisible(false);
//form2.setHeading("Identification");
form2.setLayout(new FlowLayout());
//form2.setCollapsible(true);
form2.setSize(-1, 180);
form2.setLabelWidth(60);
form2.setFieldWidth(100);
LayoutContainer main = new LayoutContainer();
main.setLayout(new ColumnLayout());
main.setSize(700, 180);
LayoutContainer left = new LayoutContainer();
FormLayout layout = new FormLayout();
layout.setLabelAlign(LabelAlign.LEFT);
layout.setDefaultWidth(180);
left.setLayout(layout);
FormLayout rightLayout = new FormLayout();
rightLayout.setLabelAlign(LabelAlign.LEFT);
rightLayout.setDefaultWidth(150);
left.setLayout(layout);
LayoutContainer right = new LayoutContainer();
right.setLayout(rightLayout);
getInternalModifyFieldSet(left);
getInternalReadOnlyFieldSet(right);
left.layout();
main.add(left, new ColumnData(.5));
main.add(right, new ColumnData(.5));
form2.add(main);
/*
form2.setButtonAlign(HorizontalAlignment.LEFT);
form2.addButton(new Button("Cancel"));
form2.addButton(new Button("Submit"));
*/
add(form2);
layout();
}
开发者ID:luox12,项目名称:onecmdb,代码行数:66,代码来源:CIIdentityForm.java
示例2: initUI
import com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign; //导入依赖的package包/类
protected void initUI() {
// Layout Fields.
setLayout(new BorderLayout());
List<ColumnConfig> internalAttr = new ArrayList<ColumnConfig>();
List<ColumnConfig> ciAttr = new ArrayList<ColumnConfig>();
/*
for (AttributeColumnConfig aConfig : gridConfig.getColumnConfig()) {
ColumnConfig cfg = EditorFactory.getColumnConfig(aConfig, false);
if (aConfig.isInternal()) {
internalAttr.add(cfg);
} else {
ciAttr.add(cfg);
}
}
*/
LayoutContainer internalPanel = getForm(internalAttr, 2, LabelAlign.LEFT);
LayoutContainer ciPanel = getForm(ciAttr, 3, LabelAlign.TOP);
ContentPanel internalCp = new ContentPanel();
internalCp.setLayout(new FitLayout());
internalCp.setAutoWidth(true);
internalCp.setAutoHeight(true);
internalCp.setHeading("Internal Attributes");
internalCp.setCollapsible(true);
internalCp.add(internalPanel);
ContentPanel attrCp = new ContentPanel();
ToolBar toolbar = new ToolBar();
attrCp.setTopComponent(toolbar);
toolbar.add(new FillToolItem());
toolbar.add(new TextToolItem("Ok"));
toolbar.add(new TextToolItem("Cancel"));
attrCp.setLayout(new FitLayout());
attrCp.setScrollMode(Scroll.ALWAYS);
attrCp.setLayoutOnChange(true);
attrCp.setCollapsible(true);
attrCp.add(ciPanel);
attrCp.setHeading("Attributes");
TabPanel infoTab = new TabPanel();
descriptionTab = new TabItem("Description");
descriptionTab.setStyleName("property-panel-background");
infoTab.add(descriptionTab);
historyTab = new TabItem("History");
historyTab.setStyleName("property-panel-background");
infoTab.add(historyTab);
BorderLayoutData centerData = new BorderLayoutData(LayoutRegion.CENTER);
centerData.setMargins(new Margins(0, 5, 0, 5));
/*
BorderLayoutData northData = new BorderLayoutData(LayoutRegion.NORTH);
northData.setSplit(false);
northData.setCollapsible(true);
northData.setMargins(new Margins(5));
*/
BorderLayoutData southData = new BorderLayoutData(LayoutRegion.SOUTH, 0.3f);
southData.setSplit(true);
southData.setCollapsible(true);
southData.setMargins(new Margins(5));
LayoutContainer fieldCont = new LayoutContainer();
fieldCont.setLayout(new RowLayout());
fieldCont.add(internalCp, new RowData(1,-1));
fieldCont.add(attrCp, new RowData(1,1));
add(fieldCont, centerData);
add(infoTab, southData);
layout();
}
开发者ID:luox12,项目名称:onecmdb,代码行数:81,代码来源:CIValueForm.java
示例3: showRPCException
import com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign; //导入依赖的package包/类
public static void showRPCException(CMDBRPCException e, Listener<WindowEvent> callback) {
Dialog d = new Dialog();
d.setLayout(new FitLayout());
//FormPanel form = new FormPanel();
LayoutContainer area = new LayoutContainer();
area.setStyleAttribute("padding", "0 10px 5px 10px");
//area.setWidth(450);
FormLayout layout = new FormLayout();
layout.setLabelAlign(LabelAlign.TOP);
layout.setDefaultWidth(380);
area.setLayout(layout);
d.setHeading(e.getHeader());
LabelField field = new LabelField("<b>Received an error from server.<b>");
TextArea stackTrace = new TextArea();
stackTrace.setFieldLabel("Stacktrace");
stackTrace.setValue(e.getRemoteStackTrace());
stackTrace.setReadOnly(true);
stackTrace.setHeight(200);
TextArea info = new TextArea();
info.setFieldLabel("Error");
info.setHeight(60);
info.setReadOnly(true);
info.setValue(e.getMessage());
area.add(field);
area.add(info);
area.add(stackTrace);
d.add(area);
d.setSize(430, 430);
d.layout();
d.setHideOnButtonClick(true);
d.show();
/*
MessageBox box = MessageBox.prompt(title, t.getMessage(), true);
box.getTextArea().setValue(t.toString());
*/
//MessageBox.alert(e.getHeader(), e.getMessage() + "<br>" + e.getRemoteStackTrace(), callback);
}
开发者ID:luox12,项目名称:onecmdb,代码行数:46,代码来源:ExceptionErrorDialog.java
示例4: setupPanelLayout
import com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign; //导入依赖的package包/类
@Override
protected void setupPanelLayout() {
LayoutContainer main = new LayoutContainer();
main.setLayout(new ColumnLayout());
FormData formData = new FormData("95%");
LayoutContainer left = new LayoutContainer();
left.setStyleAttribute("paddingRight", "10px");
FormLayout layout = new FormLayout();
layout.setLabelAlign(LabelAlign.TOP);
left.setLayout(layout);
fTemplate = new TextArea();
// first.setHideLabel(true);
fTemplate.setFieldLabel("快递单模板");
fTemplate.setHeight(400);
left.add(fTemplate, formData);
// VerticalPanel right = new VerticalPanel();
// LayoutContainer right = new LayoutContainer();
// right.setStyleAttribute("paddingRight", "10px");
// layout = new FormLayout();
// layout.setLabelAlign(LabelAlign.TOP);
// right.setLayout(layout);
// TextArea last = new TextArea();
// last.setHideLabel(true);
// last.setValue("abc\r\ndef");
// last.setEnabled(false);
// right.add(last, formData);
// ContentPanel right = new ContentPanel();
// right.setHeaderVisible(false);
HtmlContainer right = new HtmlContainer();
right.setHtml("订单模板变量说明:<br>"+
"{$shop_name}表示网店名称<br>"+
"{$province}表示网店所属省份<br>"+
"{$city}表示网店所属城市<br>"
);
main.add(left, new ColumnData(.7));
main.add(right, new ColumnData(.3));
formPanel.add(main);
}
开发者ID:jbosschina,项目名称:jcommerce,代码行数:46,代码来源:ShippingTemplatePanel.java
注:本文中的com.extjs.gxt.ui.client.widget.form.FormPanel.LabelAlign类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论