use of org.zkoss.zul.Hbox in project adempiere by adempiere.
the class WWFActivity method init.
private void init() {
Grid grid = new Grid();
grid.setWidth("100%");
grid.setHeight("100%");
grid.setStyle("margin:0; padding:0; position: absolute; align: center; valign: center;");
grid.makeNoStrip();
grid.setOddRowSclass("even");
Rows rows = new Rows();
grid.appendChild(rows);
Row row = new Row();
rows.appendChild(row);
Div div = new Div();
div.setAlign("right");
div.appendChild(lNode);
row.appendChild(div);
row.appendChild(fNode);
fNode.setWidth("100%");
fNode.setReadonly(true);
row = new Row();
rows.appendChild(row);
row.setValign("top");
div = new Div();
div.setAlign("right");
div.appendChild(lDesctiption);
row.appendChild(div);
row.appendChild(fDescription);
fDescription.setMultiline(true);
fDescription.setWidth("100%");
fDescription.setReadonly(true);
row = new Row();
rows.appendChild(row);
div = new Div();
div.setAlign("right");
div.appendChild(lHelp);
row.appendChild(div);
row.appendChild(fHelp);
fHelp.setMultiline(true);
fHelp.setWidth("100%");
fHelp.setReadonly(true);
fHelp.setRows(3);
row.appendChild(new Label());
row = new Row();
rows.appendChild(row);
div = new Div();
div.setAlign("right");
div.appendChild(lHistory);
row.appendChild(div);
row.appendChild(fHistory);
row.appendChild(new Label());
row = new Row();
rows.appendChild(row);
div = new Div();
div.setAlign("right");
div.appendChild(lAnswer);
row.appendChild(div);
Hbox hbox = new Hbox();
hbox.appendChild(fAnswerText);
hbox.appendChild(fAnswerList);
hbox.appendChild(fAnswerButton);
fAnswerButton.addEventListener(Events.ON_CLICK, this);
row.appendChild(hbox);
row.appendChild(bZoom);
bZoom.addEventListener(Events.ON_CLICK, this);
row = new Row();
rows.appendChild(row);
div = new Div();
div.setAlign("right");
div.appendChild(lTextMsg);
row.appendChild(div);
row.appendChild(fTextMsg);
fTextMsg.setMultiline(true);
fTextMsg.setWidth("100%");
row.appendChild(new Label());
row = new Row();
rows.appendChild(row);
div = new Div();
div.setAlign("right");
div.appendChild(lForward);
row.appendChild(div);
hbox = new Hbox();
hbox.appendChild(fForward.getComponent());
hbox.appendChild(lOptional);
row.appendChild(hbox);
row.appendChild(bOK);
bOK.addEventListener(Events.ON_CLICK, this);
Borderlayout layout = new Borderlayout();
layout.setWidth("100%");
layout.setHeight("100%");
layout.setStyle("background-color: transparent; position: absolute;");
North north = new North();
north.appendChild(listbox);
north.setSplittable(true);
north.setHflex("true");
//north.setVflex("true");
north.setHeight("50%");
layout.appendChild(north);
north.setStyle("background-color: transparent");
listbox.addEventListener(Events.ON_SELECT, this);
Center center = new Center();
center.appendChild(grid);
layout.appendChild(center);
center.setStyle("background-color: transparent");
center.setHflex("true");
center.setVflex("true");
South south = new South();
south.appendChild(statusBar);
layout.appendChild(south);
south.setStyle("background-color: transparent");
this.appendChild(layout);
this.setStyle("height: 100%; width: 100%; position: absolute;");
}
use of org.zkoss.zul.Hbox in project adempiere by adempiere.
the class WPAttributeInstance method init.
/**
* Static Init
* @throws Exception
*/
private void init() throws Exception {
showAll.setLabel(Msg.getMsg(Env.getCtx(), "ShowAll"));
this.appendChild(mainLayout);
// North
Hbox box = new Hbox();
box.setParent(northPanel);
box.setPack("end");
box.appendChild(showAll);
showAll.addEventListener(Events.ON_CHECK, this);
North north = new North();
north.setParent(mainLayout);
north.appendChild(northPanel);
// Center
Center center = new Center();
center.setParent(mainLayout);
center.setHflex("true");
center.setVflex("true");
center.appendChild(m_table);
// South
South south = new South();
south.setParent(mainLayout);
south.appendChild(confirmPanel);
confirmPanel.addActionListener(this);
}
use of org.zkoss.zul.Hbox in project adempiere by adempiere.
the class WLocationDialog method init.
private void init() {
Row pnlAddress1 = new Row();
pnlAddress1.appendChild(lblAddress1.rightAlign());
pnlAddress1.appendChild(txtAddress1);
Row pnlAddress2 = new Row();
pnlAddress2.appendChild(lblAddress2.rightAlign());
pnlAddress2.appendChild(txtAddress2);
Row pnlAddress3 = new Row();
pnlAddress3.appendChild(lblAddress3.rightAlign());
pnlAddress3.appendChild(txtAddress3);
Row pnlAddress4 = new Row();
pnlAddress4.appendChild(lblAddress4.rightAlign());
pnlAddress4.appendChild(txtAddress4);
Row pnlCity = new Row();
pnlCity.appendChild(lblCity.rightAlign());
pnlCity.appendChild(txtCity);
Row pnlPostal = new Row();
pnlPostal.appendChild(lblPostal.rightAlign());
pnlPostal.appendChild(txtPostal);
Row pnlPostalAdd = new Row();
pnlPostalAdd.appendChild(lblPostalAdd.rightAlign());
pnlPostalAdd.appendChild(txtPostalAdd);
Row pnlRegion = new Row();
pnlRegion.appendChild(lblRegion.rightAlign());
pnlRegion.appendChild(lstRegion);
Row pnlCountry = new Row();
pnlCountry.appendChild(lblCountry.rightAlign());
pnlCountry.appendChild(lstCountry);
Panel pnlButtonLeft = new Panel();
pnlButtonLeft.appendChild(btnUrl);
pnlButtonLeft.setAlign("left");
Panel pnlButtonRight = new Panel();
pnlButtonRight.appendChild(btnCancel);
pnlButtonRight.appendChild(btnOk);
pnlButtonRight.setWidth("100%");
pnlButtonRight.setStyle("text-align:right");
Hbox hboxButton = new Hbox();
hboxButton.appendChild(pnlButtonLeft);
hboxButton.appendChild(pnlButtonRight);
hboxButton.setWidth("100%");
this.appendChild(mainPanel);
this.appendChild(hboxButton);
}
use of org.zkoss.zul.Hbox in project adempiere by adempiere.
the class WBrowserSearch method formatEditor.
public void formatEditor(CEditor editor1, CEditor editor2) {
WEditor editor = (WEditor) editor1;
WEditor editorTo = (WEditor) editor2;
//
configColumns(editor, editorTo);
WEditorPopupMenu popupMenu;
// Editor
//setup editor context menu
popupMenu = editor.getPopupMenu();
if (popupMenu != null) {
popupMenu.addMenuListener((ContextMenuListener) editor);
mainPanel.appendChild(popupMenu);
}
//streach component to fill grid cell
editor.fillHorizontal();
Div div = new Div();
div.setAlign("right");
Label label = editor.getLabel();
div.appendChild(label);
if (label.getDecorator() != null)
div.appendChild(label.getDecorator());
//
currentRow.appendChild(div);
// Add Child
cols += 2;
//
Hbox box;
if (editorTo != null) {
box = new Hbox();
box.appendChild(editor.getComponent());
} else {
currentRow.appendChild(editor.getComponent());
m_separators.add(null);
return;
}
// EditorTo
//setup editor context menu
popupMenu = editorTo.getPopupMenu();
if (popupMenu != null) {
popupMenu.addMenuListener((ContextMenuListener) editor2);
mainPanel.appendChild(popupMenu);
}
//
editorTo.fillHorizontal();
Label separator = new Label(" - ");
m_separators.add(separator);
box.appendChild(separator);
box.appendChild(editorTo.getComponent());
// Add
currentRow.appendChild(box);
}
use of org.zkoss.zul.Hbox in project adempiere by adempiere.
the class ZkReportViewer method cmd_export.
// cmd_archive
/**
* Export
*/
private void cmd_export() {
log.config("");
if (!m_isCanExport) {
FDialog.error(m_WindowNo, this, "AccessCannotExport", getTitle());
return;
}
if (winExportFile == null) {
winExportFile = new Window();
winExportFile.setTitle(Msg.getMsg(Env.getCtx(), "Export") + ": " + getTitle());
winExportFile.setWidth("450px");
winExportFile.setClosable(true);
winExportFile.setBorder("normal");
winExportFile.setStyle("position:absolute");
cboType.setMold("select");
cboType.getItems().clear();
cboType.appendItem("ps" + " - " + Msg.getMsg(Env.getCtx(), "FilePS"), "ps");
cboType.appendItem("xml" + " - " + Msg.getMsg(Env.getCtx(), "FileXML"), "xml");
ListItem li = cboType.appendItem("pdf" + " - " + Msg.getMsg(Env.getCtx(), "FilePDF"), "pdf");
cboType.appendItem("html" + " - " + Msg.getMsg(Env.getCtx(), "FileHTML"), "html");
cboType.appendItem("txt" + " - " + Msg.getMsg(Env.getCtx(), "FileTXT"), "txt");
cboType.appendItem("ssv" + " - " + Msg.getMsg(Env.getCtx(), "FileSSV"), "ssv");
cboType.appendItem("csv" + " - " + Msg.getMsg(Env.getCtx(), "FileCSV"), "csv");
cboType.appendItem("xls" + " - " + Msg.getMsg(Env.getCtx(), "FileXLS"), "xls");
cboType.setSelectedItem(li);
Hbox hb = new Hbox();
Div div = new Div();
div.setAlign("right");
div.appendChild(new Label(Msg.getMsg(Env.getCtx(), "FilesOfType")));
hb.appendChild(div);
hb.appendChild(cboType);
cboType.setWidth("100%");
Vbox vb = new Vbox();
vb.setWidth("390px");
winExportFile.appendChild(vb);
vb.appendChild(hb);
vb.appendChild(confirmPanel);
confirmPanel.addActionListener(this);
}
AEnv.showCenterScreen(winExportFile);
}
Aggregations