flexTable.getFlexCellFormatter().setVerticalAlignment(0, 0, HasVerticalAlignment.ALIGN_MIDDLE); verticalPanel.setHeight("100%"); flexTable.setWidget(0, 1, verticalPanel); flexTable.getFlexCellFormatter().setVerticalAlignment(0, 1, HasVerticalAlignment.ALIGN_MIDDLE);
/** {@inheritDoc} */ @SuppressWarnings({"deprecation"}) protected Widget createInactive() { FlexTable panel = getDockPanel(); Label label = getLabel(); Image image = getImage(); String header = String.valueOf(getValue()); label.setText(header.length() == 0 ? " " : header); if (panel.getRowCount() < 1) { panel.setWidget(0, 0, label); panel.getFlexCellFormatter().setVerticalAlignment(0, 0, HasVerticalAlignment.ALIGN_MIDDLE); panel.setCellPadding(0); panel.setCellSpacing(0); } if (isSortable() && panel.getCellCount(0) < 2) panel.setWidget(0, 1, image); return panel; }
public int addAttribute(String lbl, final Widget categories) { String id = DOM.createUniqueId(); categories.getElement().setAttribute("aria-labelledby", id); categories.getElement().setAttribute("aria-required", String.valueOf(true)); categories.getElement().setTabIndex(0); int row = currentTable.getRowCount(); Label label = new Label(lbl); label.getElement().setAttribute("id", id); currentTable.setWidget(row, 0, label); currentTable.setWidget(row, 1, categories); currentTable.getFlexCellFormatter().setHorizontalAlignment(row, 0, HasHorizontalAlignment.ALIGN_RIGHT); currentTable.getFlexCellFormatter().setVerticalAlignment(row, 0, HasVerticalAlignment.ALIGN_TOP); return row; }
2, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE); 3, HasHorizontalAlignment.ALIGN_LEFT); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP);
2, HasHorizontalAlignment.ALIGN_CENTER ); layout.getFlexCellFormatter().setVerticalAlignment( currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE ); 3, HasHorizontalAlignment.ALIGN_LEFT ); layout.getFlexCellFormatter().setVerticalAlignment( currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP );
2, HasHorizontalAlignment.ALIGN_CENTER ); layout.getFlexCellFormatter().setVerticalAlignment( currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE ); 3, HasHorizontalAlignment.ALIGN_LEFT ); layout.getFlexCellFormatter().setVerticalAlignment( currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP );
2, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE); 3, HasHorizontalAlignment.ALIGN_LEFT); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP);
2, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE); 3, HasHorizontalAlignment.ALIGN_LEFT); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP);
2, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 2, HasVerticalAlignment.ALIGN_MIDDLE); 3, HasHorizontalAlignment.ALIGN_LEFT); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 3, HasVerticalAlignment.ALIGN_TOP);
private void addActionsButtonsToLayout(String title, ClickHandler addBelowListener, ClickHandler moveDownListener, ClickHandler moveUpListener) { final DirtyableHorizontalPane hp = new DirtyableHorizontalPane(); Image addPattern = CommonAltedImages.INSTANCE.NewItemBelow(); addPattern.setTitle(title); addPattern.addClickHandler(addBelowListener); Image moveDown = CommonAltedImages.INSTANCE.MoveDown(); moveDown.setTitle(GuidedRuleEditorResources.CONSTANTS.MoveDown()); moveDown.addClickHandler(moveDownListener); Image moveUp = CommonAltedImages.INSTANCE.MoveUp(); moveUp.setTitle(GuidedRuleEditorResources.CONSTANTS.MoveUp()); moveUp.addClickHandler(moveUpListener); hp.add(addPattern); hp.add(moveDown); hp.add(moveUp); layout.setWidget(currentLayoutRow, 4, hp); layout.getFlexCellFormatter().setHorizontalAlignment(currentLayoutRow, 4, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 4, HasVerticalAlignment.ALIGN_MIDDLE); }
private void addActionsButtonsToLayout(String title, ClickHandler addBelowListener, ClickHandler moveDownListener, ClickHandler moveUpListener) { final DirtyableHorizontalPane hp = new DirtyableHorizontalPane(); Image addPattern = CommonAltedImages.INSTANCE.NewItemBelow(); addPattern.setTitle(title); addPattern.addClickHandler(addBelowListener); Image moveDown = CommonAltedImages.INSTANCE.MoveDown(); moveDown.setTitle(GuidedRuleEditorResources.CONSTANTS.MoveDown()); moveDown.addClickHandler(moveDownListener); Image moveUp = CommonAltedImages.INSTANCE.MoveUp(); moveUp.setTitle(GuidedRuleEditorResources.CONSTANTS.MoveUp()); moveUp.addClickHandler(moveUpListener); hp.add(addPattern); hp.add(moveDown); hp.add(moveUp); layout.setWidget(currentLayoutRow, 4, hp); layout.getFlexCellFormatter().setHorizontalAlignment(currentLayoutRow, 4, HasHorizontalAlignment.ALIGN_CENTER); layout.getFlexCellFormatter().setVerticalAlignment(currentLayoutRow, 4, HasVerticalAlignment.ALIGN_MIDDLE); }
private void addActionsButtonsToLayout( String title, ClickHandler addBelowListener, ClickHandler moveDownListener, ClickHandler moveUpListener ) { final DirtyableHorizontalPane hp = new DirtyableHorizontalPane(); Image addPattern = CommonAltedImages.INSTANCE.NewItemBelow(); addPattern.setTitle( title ); addPattern.addClickHandler( addBelowListener ); Image moveDown = CommonAltedImages.INSTANCE.MoveDown(); moveDown.setTitle( Constants.INSTANCE.MoveDown() ); moveDown.addClickHandler( moveDownListener ); Image moveUp = CommonAltedImages.INSTANCE.MoveUp(); moveUp.setTitle( Constants.INSTANCE.MoveUp() ); moveUp.addClickHandler( moveUpListener ); hp.add( addPattern ); hp.add( moveDown ); hp.add( moveUp ); layout.setWidget( currentLayoutRow, 4, hp ); layout.getFlexCellFormatter().setHorizontalAlignment( currentLayoutRow, 4, HasHorizontalAlignment.ALIGN_CENTER ); layout.getFlexCellFormatter().setVerticalAlignment( currentLayoutRow, 4, HasVerticalAlignment.ALIGN_MIDDLE ); }
getFlexCellFormatter().setStyleName(rowIndex,0, "sectionTitleRow"); getFlexCellFormatter().setColSpan(rowIndex, 0, 3); getFlexCellFormatter().setVerticalAlignment(rowIndex, 0, HasVerticalAlignment.ALIGN_BOTTOM); HorizontalPanel sectionTitlePanel = new HorizontalPanel(); Label sectionTitle = new Label(section.getTitle());
public int addAttribute(String lbl, final Widget categories) { String id = DOM.createUniqueId(); categories.getElement().setAttribute("aria-labelledby", id); categories.getElement().setAttribute("aria-required", String.valueOf(true)); categories.getElement().setTabIndex(0); int row = currentTable.getRowCount(); Label label = new Label(lbl); label.getElement().setAttribute("id", id); currentTable.setWidget(row, 0, label); currentTable.setWidget(row, 1, categories); currentTable.getFlexCellFormatter().setHorizontalAlignment(row, 0, HasHorizontalAlignment.ALIGN_RIGHT); currentTable.getFlexCellFormatter().setVerticalAlignment(row, 0, HasVerticalAlignment.ALIGN_TOP); return row; }
@Override public void addWidgetToLayout(Widget widget) { horizontalArea.setWidget(currentRow, currentColumn, widget); horizontalArea.getFlexCellFormatter().setVerticalAlignment(currentRow, currentColumn, HasVerticalAlignment.ALIGN_TOP); currentColumn++; }
@Override public void addLayoutToLayout(FieldLayout layout) { horizontalArea.setWidget(currentRow, currentColumn, layout); horizontalArea.getFlexCellFormatter().setVerticalAlignment(currentRow, currentColumn, HasVerticalAlignment.ALIGN_TOP); currentColumn++; }
@Override public void addFieldToLayout(FieldElement field) { horizontalArea.setWidget(currentRow, currentColumn, field); horizontalArea.getFlexCellFormatter().setVerticalAlignment(currentRow, currentColumn, HasVerticalAlignment.ALIGN_TOP); if(hasValidation){ field.setValidationPanel(validationPanel); } currentColumn++; }
ecfsTable.setWidget(0, 2, selectedEcfsPanel); ecfsTable.getFlexCellFormatter().setVerticalAlignment(0, 1, HasVerticalAlignment.ALIGN_MIDDLE);
uploadTable.setWidget(0, 2, uploadButton); uploadTable.getFlexCellFormatter() .setVerticalAlignment(0, 0, HasVerticalAlignment.ALIGN_MIDDLE); uploadTable.getFlexCellFormatter() .setVerticalAlignment(0, 2, HasVerticalAlignment.ALIGN_MIDDLE); table.setWidget(1, 0, uploadTable); setWidget(table);