本文整理汇总了Java中com.extjs.gxt.ui.client.Style.HorizontalAlignment类的典型用法代码示例。如果您正苦于以下问题:Java HorizontalAlignment类的具体用法?Java HorizontalAlignment怎么用?Java HorizontalAlignment使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
HorizontalAlignment类属于com.extjs.gxt.ui.client.Style包,在下文中一共展示了HorizontalAlignment类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createFormPanel
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
/**
* Creates the form panel.
*/
private void createFormPanel()
{
formPanel = new FormPanel();
formPanel.setFrame(true);
formPanel.setHeaderVisible(false);
formPanel.setAutoHeight(true);
FieldSet fieldSet = new FieldSet();
fieldSet.setHeading("Search Management");
fieldSet.setCheckboxToggle(false);
fieldSet.setCollapsible(false);
FormLayout layout = new FormLayout();
fieldSet.setLayout(layout);
search = new Button("Search", new SelectionListener<ButtonEvent>()
{
@Override
public void componentSelected(ButtonEvent ce)
{
Dispatcher.forwardEvent(GeofenceEvents.SHOW_SEARCH_USER_WIDGET);
}
});
ButtonBar bar = new ButtonBar();
bar.setAlignment(HorizontalAlignment.CENTER);
bar.add(search);
Button p = new Button("get AOIs");
Button q = new Button("get Features");
bar.add(p);
bar.add(q);
fieldSet.add(bar);
formPanel.add(fieldSet);
}
示例2: buildToolbar
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
/**
* Builds the actions toolbar.
*
* @return The actions toolbar.
*/
private ToolBar buildToolbar() {
// Save button.
saveButton = Forms.button(I18N.CONSTANTS.save(), IconImageBundle.ICONS.save());
saveButton.setEnabled(false);
// Actions toolbar.
final ToolBar toolBar = new ToolBar();
toolBar.setAlignment(HorizontalAlignment.LEFT);
toolBar.setBorders(false);
toolBar.add(saveButton);
toolBar.add(new FillToolItem());
return toolBar;
}
示例3: buildToolbar
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
/**
* Builds the actions toolbar.
*
* @return The actions toolbar.
*/
private ToolBar buildToolbar() {
// Save button.
saveButton = Forms.button(I18N.CONSTANTS.save(), IconImageBundle.ICONS.save());
saveButton.setEnabled(false);
// Actions toolbar.
final ToolBar toolBar = new ToolBar();
toolBar.setAlignment(HorizontalAlignment.LEFT);
toolBar.setBorders(false);
toolBar.add(saveButton);
// ExportForm button
exportButton = Forms.button(I18N.CONSTANTS.export(), IconImageBundle.ICONS.excel());
toolBar.add(new FillToolItem());
toolBar.add(exportButton);
return toolBar;
}
示例4: AddDepartmentToAssignmentWindow
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
public AddDepartmentToAssignmentWindow(final Integer assignmentId,final ProjectPanel projectPanel){
this.projectPanel=projectPanel;
setWidth(310);
setHeight(300);
// setFrame(true);
setClosable(true);
setHeaderVisible(true);
setBodyBorder(true);
this.setOnEsc(true);
setButtonAlign(HorizontalAlignment.CENTER);
setLayout(new ColumnLayout());
doDepartmentPanel();
setData(assignmentId);
show();
}
示例5: buildCurrentRegionLabel
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
private void buildCurrentRegionLabel(){
currentRegionPanel = new ContentPanel();
currentRegionPanel.setHeaderVisible(false);
TableRowLayout tableLayout = new TableRowLayout();
tableLayout.setWidth("100%");
tableLayout.setBorder(0);
tableLayout.setCellHorizontalAlign(HorizontalAlignment.CENTER);
tableLayout.setCellVerticalAlign(VerticalAlignment.BOTTOM);
currentRegionPanel.setLayout(tableLayout);
currentRegionPanel.setHeight(40);
current_Label = new LabelField();
current_name = RegionForm.getHiddenNameField();
current_type = RegionForm.getTypeField();
currentRegionPanel.add(current_Label);
currentRegionPanel.add(current_name);
currentRegionPanel.add(current_type);
super.add(currentRegionPanel);
}
示例6: PasswordAccessAuditDialog
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
public PasswordAccessAuditDialog(Password password)
{
this.setSize("350", "460");
this.setHeading(textMessages.passwordAccessAuditLog());
VBoxLayout boxLayout = new VBoxLayout();
boxLayout.setVBoxLayoutAlign(VBoxLayoutAlign.CENTER);
this.setLayout(boxLayout);
this.setModal(true);
this.setResizable(false);
gridStore = new ListStore<PasswordAccessAuditData>();
List<ColumnConfig> configs = new ArrayList<ColumnConfig>();
ColumnConfig columnConfigDate = new ColumnConfig(Constants.DATE, textMessages.dateAccessed(), 130);
columnConfigDate.setDateTimeFormat(DateTimeFormat.getFormat(textMessages.displayDateFormat()));
configs.add(columnConfigDate);
ColumnConfig columnConfigUser = new ColumnConfig(Constants.USER, textMessages.userAccessed(), 160);
configs.add(columnConfigUser);
Grid<PasswordAccessAuditData> grid = new Grid<PasswordAccessAuditData>(gridStore, new ColumnModel(configs));
grid.setStripeRows(true);
add(grid);
grid.setSize("320px", "390px");
grid.setBorders(true);
Button closeButton = new Button(textMessages.close(), new SelectionListener<ButtonEvent>() {
@Override
public void componentSelected(ButtonEvent ce) {
doClose();
}
});
setButtonAlign(HorizontalAlignment.CENTER);
addButton(closeButton);
loadAccessAuditData(password.getId());
}
示例7: AssignmentDetailPanel
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
public AssignmentDetailPanel(ContentPanel contentPanel){
this.parentPanel=contentPanel;
setWidth("100%");
setHeight(300);
setFrame(true);
setHeaderVisible(false);
setPadding(0);
setBodyBorder(false);
setLabelAlign(LabelAlign.TOP);
setButtonAlign(HorizontalAlignment.CENTER);
doDetailPanel();
}
示例8: AssignmentDepartmentPanel
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
public AssignmentDepartmentPanel(){
setWidth(700);
setHeight(300);
setFrame(true);
setHeaderVisible(false);
setBodyBorder(false);
setButtonAlign(HorizontalAlignment.CENTER);
setLayout(new ColumnLayout());
doDepartmentPanel();
doDetailPanel();
}
示例9: onRender
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
@Override
protected void onRender(Element parent, int index) {
super.onRender(parent, index);
basePanel.setHeading(Resources.constants.OrderDetail_baseInfo());
renderBasePanel();
add(basePanel);
btnEditConsignee = new Button(Resources.constants.OrderDetail_edit());
consigneePanel.setHeading(Resources.constants.OrderDetail_consigneeInfo(), btnEditConsignee);
renderConsigneePanel();
add(consigneePanel);
btnEditGoods = new Button(Resources.constants.OrderDetail_edit());
goodsPanel.setHeading(Resources.constants.OrderDetail_goodsInfo(), btnEditGoods);
renderGoodsPanel();
add(goodsPanel);
btnEditFee = new Button(Resources.constants.OrderDetail_edit());
feePanel.setHeading(Resources.constants.OrderDetail_feeInfo(), btnEditFee);
renderFeePanel();
add(feePanel);
operationPanel.setFrame(true);
operationPanel.setCollapsible(true);
operationPanel.setAnimCollapse(false);
operationPanel.setButtonAlign(HorizontalAlignment.CENTER);
operationPanel.setIconStyle("icon-table");
// operationPanel.setLayout(new FitLayout());
// operationPanel.setHeight(300);
// operationPanel.setWidth("100%");
operationPanel.setHeading(Resources.constants.OrderDetail_operationInfo());
renderOperationPanel();
add(operationPanel);
}
示例10: afterRender
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
@Override
protected void afterRender() {
// super.afterRender();
//TODO 添加按钮
super.add(formPanel);
FormLayout fl = new FormLayout();
fl.setLabelWidth(150);
fl.setLabelPad(50);
formPanel.setLayout(fl);
setupPanelLayout();
btnOk = new Button("确定");
btnOk.addSelectionListener(selectionListener);
btnPre = new Button("上一步", new SelectionListener<ButtonEvent>() {
public void componentSelected(ButtonEvent ce) {
OrderGoodsPanel.State newState = new OrderGoodsPanel.State();
newState.setIsEdit(false);
newState.setUserId(getCurState().getUserId());
newState.setId(getCurState().getOrderId());
newState.execute();
}
});
btnNext = new Button("下一步");
btnNext.addSelectionListener(selectionListener);
btnCancel = new Button("取消", new SelectionListener<ButtonEvent>() {
public void componentSelected(ButtonEvent ce) {
cancel();
}
});
formPanel.setButtonAlign(HorizontalAlignment.CENTER);
formPanel.addButton(btnOk);
formPanel.addButton(btnPre);
formPanel.addButton(btnNext);
formPanel.addButton(btnCancel);
}
示例11: getPayPanel
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
public static ContentPanel getPayPanel(){
List<String> wantedFields = new ArrayList<String>();
wantedFields.add(IOrder.PAYMENT);
wantedFields.add(IOrder.PAYNOTE);
BasePagingLoader loader = new PagingListService().getLoader(ModelNames.ORDER, wantedFields);
final ListStore<BeanObject> store = new ListStore<BeanObject>(loader);
List<ColumnConfig> columns = new ArrayList<ColumnConfig>();
final CheckBoxSelectionModel<BeanObject> smRowSelection = new CheckBoxSelectionModel<BeanObject>();
columns.add(smRowSelection.getColumn());
columns.add(new ColumnConfig(IOrder.PAYMENT, "名称", 80));
columns.add(new ColumnConfig(IOrder.PAYNOTE, "描述", 104));
columns.add(new ColumnConfig("handlingFee", "手续费", 80));
ColumnModel cm = new ColumnModel(columns);
Grid<BeanObject> grid = new EditorGrid<BeanObject>(store, cm);
grid.setLoadMask(true);
grid.setBorders(true);
grid.setSize(750, 200);
final ContentPanel panel = new ContentPanel();
panel.setFrame(true);
panel.setCollapsible(true);
panel.setAnimCollapse(false);
panel.setButtonAlign(HorizontalAlignment.CENTER);
panel.setSize(750, 200);
panel.setLayout(new FitLayout());
panel.setHeading("选择支付方式");
panel.add(grid);
return panel;
}
示例12: onRender
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
@Override
protected void onRender(Element parent, int index) {
super.onRender(parent, index);
basePanel.setLayout(new BorderLayout());
basePanel.setStyleAttribute("padding", "10px");
super.add(basePanel);
FormLayout fl = new FormLayout();
fl.setLabelWidth(150);
fl.setLabelPad(50);
formPanel.setLayout(fl);
initCommentLayout();
initReplyLayout();
btnNew.setText(Resources.constants.ok());
btnReset.setText(Resources.constants.reset());
formPanel.setButtonAlign(HorizontalAlignment.CENTER);
formPanel.addButton(btnNew);
formPanel.addButton(btnReset);
btnNew.addSelectionListener(selectionListener);
btnReset.addSelectionListener(
new SelectionListener<ButtonEvent>() {
public void componentSelected(ButtonEvent sender) {
formPanel.reset();
}
}
);
}
示例13: onRender
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
protected void onRender(com.google.gwt.user.client.Element parent, int index) {
super.onRender(parent, index);
add(contentPanel);
Button searchBt = new Button("搜索", new SelectionListener<ButtonEvent>() {
public void componentSelected(ButtonEvent ce) {
criteria.removeAll();
if (!goodsNameTxt.getText().trim().equals("")) {
criteria.addCondition(new Condition(IGoods.NAME, Condition.EQUALS, goodsNameTxt.getText()));
}
toolBar.refresh();
}
});
HorizontalPanel goodsSearchPanel = new HorizontalPanel();
goodsSearchPanel.add(new Label("商品名称: "));
goodsSearchPanel.add(goodsNameTxt);
goodsSearchPanel.add(searchBt);
contentPanel.createPanel(IGoods.NAME, null,goodsSearchPanel);
final ListStore<BeanObject> store= onInitailization();
final ContentPanel panel = new ContentPanel();
panel.setFrame(true);
panel.setCollapsible(true);
panel.setAnimCollapse(false);
panel.setButtonAlign(HorizontalAlignment.CENTER);
panel.setIconStyle("icon-table");
panel.setLayout(new FitLayout());
panel.add(grid);
panel.setSize(880, 350);
panel.setBottomComponent(toolBar);
add(panel);
HorizontalPanel datePickerOPeratePanel = initDatePickerPanel(store);
add(datePickerOPeratePanel);
}
示例14: afterRender
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
@Override
protected void afterRender() {
super.afterRender();
// add(formPanel);
super.add(formPanel);
// formPanel.setBodyBorder(false);
//formPanel.setWidth(800);
FormLayout fl = new FormLayout();
fl.setLabelWidth(150);
fl.setLabelPad(50);
formPanel.setLayout(fl);
formPanel.setWidth("100%");
setupPanelLayout();
btnNew.setText(Resources.constants.ok());
btnReset.setText(Resources.constants.reset());
// panel.add(btnNew);
// panel.add(btnCancel);
formPanel.setButtonAlign(HorizontalAlignment.CENTER);
formPanel.addButton(btnNew);
formPanel.addButton(btnReset);
btnNew.addSelectionListener(selectionListener);
btnReset.addSelectionListener(
new SelectionListener<ButtonEvent>() {
public void componentSelected(ButtonEvent sender) {
formPanel.reset();
}
}
);
}
示例15: updateInputForm
import com.extjs.gxt.ui.client.Style.HorizontalAlignment; //导入依赖的package包/类
protected boolean updateInputForm(LayoutContainer container, List<CIModel> model) {
final FormPanel editForm = new FormPanel();
editForm.setWidth("100%");
editForm.setHeight("100%");
editForm.setScrollMode(Scroll.AUTO);
editForm.setFrame(true);
editForm.setFieldWidth(60);
editForm.setLabelWidth(100);
editForm.setButtonAlign(HorizontalAlignment.CENTER);
if (model.size() == 0) {
editForm.setHeading("Can't edit!!!!");
} else if (model.size() > 1) {
editForm.setHeading("Edit Multiple CI");
} else {
editForm.setHeading("Edit CI " + model.get(0).getDisplayName());
}
editForm.setIconStyle("icon-form");
editForm.setStyleAttribute("padding", "0");
if (model.size() > 0) {
CIModel m = model.get(0);
/*
m.getChildren(mdr, new AsyncCallback<List<? extends ModelData>>() {
public void onFailure(Throwable arg0) {
// TODO Auto-generated method stub
}
public void onSuccess(List<? extends ModelData> arg0) {
for (AttributeModel a : (List<AttributeModel>)arg0) {
// TODO: Switch on type, etc...
if (a.isComplex()) {
continue;
}
List<ValueModel> values = a.getValues();
if (values.size() == 0) {
editForm.add(getField(a, null));
} else if (values.size() == 1) {
editForm.add(getField(a, values.get(0)));
} else {
for (ValueModel v : values) {
editForm.add(getField(a, v));
}
}
}
editForm.layout();
}
});
*/
}
container.removeAll();
container.add(editForm);
container.layout();
return(true);
}