Search in sources :

Example 1 with Div

use of org.zkoss.zul.Div in project adempiere by adempiere.

the class WTranslationDialog method zkInit.

private void zkInit() throws Exception {
    centerPanel.appendChild(centerLayout);
    lClient.setText(Msg.translate(Env.getCtx(), "AD_Client_ID"));
    lLanguage.setText(Msg.translate(Env.getCtx(), "AD_Language"));
    lLanguage.setTooltiptext(Msg.translate(Env.getCtx(), "IsSystemLanguage"));
    lTable.setText(Msg.translate(Env.getCtx(), "AD_Table_ID"));
    //
    bExport.setLabel(Msg.getMsg(Env.getCtx(), "Export"));
    bExport.addActionListener(this);
    bImport.setLabel(Msg.getMsg(Env.getCtx(), "Import"));
    bImport.addActionListener(this);
    Rows rows = centerLayout.newRows();
    Row row = rows.newRow();
    row.appendChild(lClient.rightAlign());
    row.appendChild(cbClient);
    row = rows.newRow();
    row.appendChild(lLanguage.rightAlign());
    row.appendChild(cbLanguage);
    row = rows.newRow();
    row.appendChild(lTable.rightAlign());
    row.appendChild(cbTable);
    Div div = new Div();
    div.setAlign("right");
    div.appendChild(bExport);
    row = rows.newRow();
    row.appendChild(div);
    row.appendChild(bImport);
}
Also used : Div(org.zkoss.zul.Div) Row(org.adempiere.webui.component.Row) Rows(org.adempiere.webui.component.Rows)

Example 2 with Div

use of org.zkoss.zul.Div in project adempiere by adempiere.

the class WGenForm method zkInit.

//	init
/**
	 *	Static Init.
	 *  <pre>
	 *  selPanel (tabbed)
	 *      fOrg, fBPartner
	 *      scrollPane & miniTable
	 *  genPanel
	 *      info
	 *  </pre>
	 *  @throws Exception
	 */
void zkInit() throws Exception {
    //
    selPanel.setWidth("99%");
    selPanel.setHeight("90%");
    selPanel.setStyle("border: none; position: absolute");
    DesktopTabpanel tabpanel = new DesktopTabpanel();
    tabpanel.appendChild(selPanel);
    Tabpanels tabPanels = new Tabpanels();
    tabPanels.appendChild(tabpanel);
    tabbedPane.appendChild(tabPanels);
    Tabs tabs = new Tabs();
    tabbedPane.appendChild(tabs);
    Tab tab = new Tab(Msg.getMsg(Env.getCtx(), "Select"));
    tabs.appendChild(tab);
    North north = new North();
    selPanel.appendChild(north);
    north.appendChild(selNorthPanel);
    South south = new South();
    selPanel.appendChild(south);
    south.appendChild(confirmPanelSel);
    Center center = new Center();
    selPanel.appendChild(center);
    center.appendChild(miniTable);
    center.setHflex("true");
    center.setVflex("true");
    miniTable.setHeight("99%");
    confirmPanelSel.addActionListener(this);
    //
    tabpanel = new DesktopTabpanel();
    tabPanels.appendChild(tabpanel);
    tabpanel.appendChild(genPanel);
    tab = new Tab(Msg.getMsg(Env.getCtx(), "Generate"));
    tabs.appendChild(tab);
    genPanel.setWidth("99%");
    genPanel.setHeight("90%");
    genPanel.setStyle("border: none; position: absolute");
    center = new Center();
    genPanel.appendChild(center);
    Div div = new Div();
    div.appendChild(info);
    center.appendChild(div);
    south = new South();
    genPanel.appendChild(south);
    south.appendChild(confirmPanelGen);
    confirmPanelGen.addActionListener(this);
}
Also used : Div(org.zkoss.zul.Div) Center(org.zkoss.zul.Center) Tab(org.adempiere.webui.component.Tab) Tabpanels(org.adempiere.webui.component.Tabpanels) South(org.zkoss.zul.South) Tabs(org.adempiere.webui.component.Tabs) North(org.zkoss.zul.North) DesktopTabpanel(org.adempiere.webui.component.DesktopTabpanel)

Example 3 with Div

use of org.zkoss.zul.Div in project adempiere by adempiere.

the class LayoutUtils method makeRightAlign.

public static Component makeRightAlign(Label label) {
    Div div = new Div();
    div.setStyle("text-align: right");
    div.appendChild(label);
    return div;
}
Also used : Div(org.zkoss.zul.Div)

Example 4 with Div

use of org.zkoss.zul.Div in project adempiere by adempiere.

the class ValuePreference method init.

/**
	 *  Static Layout
	 *  @throws Exception
	 */
private void init() throws Exception {
    //
    lAttribute.setValue(Msg.translate(m_ctx, "Attribute").replace("&", ""));
    lValue.setValue(Msg.translate(m_ctx, "Value").replace("&", ""));
    lSetFor.setValue(Msg.getMsg(m_ctx, "ValuePreferenceSetFor"));
    cbClient.setLabel(Msg.translate(m_ctx, "AD_Client_ID"));
    cbOrg.setLabel(Msg.translate(m_ctx, "AD_Org_ID"));
    cbUser.setLabel(Msg.translate(m_ctx, "AD_User_ID"));
    cbUser.setChecked(true);
    cbWindow.setLabel(Msg.translate(m_ctx, "AD_Window_ID"));
    cbWindow.setChecked(true);
    // 
    setPanel.appendChild(setLayout);
    fAttribute.setReadonly(true);
    fValue.setReadonly(true);
    Vbox box = new Vbox();
    box.setWidth("100%");
    box.setHeight("100%");
    box.setParent(this);
    box.appendChild(setPanel);
    Rows rows = new Rows();
    rows.setParent(setLayout);
    Row row = new Row();
    Div div = new Div();
    div.setSclass("label-right");
    div.appendChild(lAttribute);
    row.appendCellChild(div);
    row.appendCellChild(fAttribute, 4);
    fAttribute.setWidth("100%");
    row.appendCellChild(lAttributeValue);
    rows.appendChild(row);
    row = new Row();
    div = new Div();
    div.setSclass("label-right");
    div.appendChild(lValue);
    row.appendCellChild(div);
    row.appendCellChild(fValue, 4);
    fValue.setWidth("100%");
    row.appendCellChild(lValueValue);
    rows.appendChild(row);
    row = new Row();
    div = new Div();
    div.setSclass("label-right");
    div.appendChild(lSetFor);
    row.appendChild(div);
    row.appendChild(cbClient);
    row.appendChild(cbOrg);
    row.appendChild(cbUser);
    row.appendChild(cbWindow);
    rows.appendChild(row);
    row = new Row();
    row.appendChild(new Space());
    row.appendCellChild(lExplanation, 5);
    rows.appendChild(row);
    //
    Separator separator = new Separator();
    separator.setBar(true);
    //TODO move to theme
    separator.setHeight("20px");
    box.appendChild(separator);
    box.appendChild(confirmPanel);
    this.setBorder("normal");
    setLayout.makeNoStrip();
    setLayout.setOddRowSclass("even");
}
Also used : Div(org.zkoss.zul.Div) Space(org.zkoss.zul.Space) Row(org.adempiere.webui.component.Row) Vbox(org.zkoss.zul.Vbox) Separator(org.zkoss.zul.Separator) Rows(org.adempiere.webui.component.Rows)

Example 5 with Div

use of org.zkoss.zul.Div 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);
}
Also used : Div(org.zkoss.zul.Div) Hbox(org.zkoss.zul.Hbox) Label(org.adempiere.webui.component.Label) WEditor(org.adempiere.webui.editor.WEditor) WEditorPopupMenu(org.adempiere.webui.editor.WEditorPopupMenu)

Aggregations

Div (org.zkoss.zul.Div)51 Label (org.adempiere.webui.component.Label)18 Row (org.adempiere.webui.component.Row)18 Rows (org.adempiere.webui.component.Rows)15 Center (org.zkoss.zul.Center)13 North (org.zkoss.zul.North)11 Hbox (org.zkoss.zul.Hbox)10 South (org.zkoss.zul.South)10 Borderlayout (org.zkoss.zul.Borderlayout)9 Separator (org.zkoss.zul.Separator)9 ConfirmPanel (org.adempiere.webui.component.ConfirmPanel)8 Grid (org.adempiere.webui.component.Grid)7 Component (org.zkoss.zk.ui.Component)7 Tabpanel (org.adempiere.webui.component.Tabpanel)6 Center (org.zkoss.zkex.zul.Center)6 North (org.zkoss.zkex.zul.North)6 Vbox (org.zkoss.zul.Vbox)6 Tab (org.adempiere.webui.component.Tab)5 Text (org.zkoss.zhtml.Text)5 Listbox (org.adempiere.webui.component.Listbox)4