Example usage for com.vaadin.ui.themes ValoTheme TABLE_NO_STRIPES

List of usage examples for com.vaadin.ui.themes ValoTheme TABLE_NO_STRIPES

Introduction

In this page you can find the example usage for com.vaadin.ui.themes ValoTheme TABLE_NO_STRIPES.

Prototype

String TABLE_NO_STRIPES

To view the source code for com.vaadin.ui.themes ValoTheme TABLE_NO_STRIPES.

Click Source Link

Document

Remove the alternating row colors.

Usage

From source file:com.hybridbpm.ui.UsersMenu.java

License:Apache License

public UsersMenu() {
    textSearch.addStyleName(ValoTheme.TEXTFIELD_SMALL);
    textSearch.setWidth(100, Unit.PERCENTAGE);
    textSearch.setNullRepresentation("");
    textSearch.setWidth(100, Unit.PERCENTAGE);
    textSearch.setInputPrompt("type to search users");
    textSearch.addTextChangeListener(new FieldEvents.TextChangeListener() {

        @Override//from   ww  w.  ja  va2  s  . com
        public void textChange(FieldEvents.TextChangeEvent event) {
            search(event.getText());
        }
    });

    table.addStyleName(ValoTheme.TABLE_BORDERLESS);
    table.addStyleName(ValoTheme.TABLE_NO_HEADER);
    table.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    table.addStyleName(ValoTheme.TABLE_SMALL);
    table.addStyleName(ValoTheme.TABLE_COMPACT);
    table.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    table.addContainerProperty("user", User.class, null, "Username", null, Table.Align.LEFT);
    table.addContainerProperty("tasks", Label.class, null, "Tasks", null, Table.Align.LEFT);
    table.setColumnExpandRatio("user", 1f);
    table.setVisibleColumns("user", "tasks");
    table.setSizeFull();
    table.setColumnExpandRatio("user", 1f);
    table.setSelectable(false);
    table.addGeneratedColumn("user", new UserColumnGenerator());

    addComponents(textSearch, table);
    setExpandRatio(table, 1f);
    setHeight(100, Unit.PERCENTAGE);
    setWidth(300, Unit.PIXELS);
    addStyleName("users-list");
    setVisible(false);
}

From source file:org.eclipse.hawkbit.ui.common.detailslayout.AbstractMetadataDetailsLayout.java

License:Open Source License

private void createMetadataTable() {
    addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    addStyleName(ValoTheme.TABLE_NO_STRIPES);
    setSelectable(false);//from   www . j  a  va  2 s .c  o  m
    setImmediate(true);
    setContainerDataSource(getContainer());
    setColumnHeaderMode(ColumnHeaderMode.EXPLICIT);
    addTableHeader();
    setSizeFull();
    // same as height of other tabs in details tabsheet
    setHeight(116, Unit.PIXELS);
}

From source file:org.eclipse.hawkbit.ui.common.detailslayout.TargetFilterQueryDetailsTable.java

License:Open Source License

private void createTable() {
    addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    addStyleName(ValoTheme.TABLE_NO_STRIPES);
    addStyleName(SPUIStyleDefinitions.SW_MODULE_TABLE);
    addStyleName("details-layout");
    setSelectable(false);/*from  ww  w . j a  va2  s.  c o m*/
    setImmediate(true);
    setContainerDataSource(getDistSetContainer());
    setColumnHeaderMode(ColumnHeaderMode.EXPLICIT);
    addTableHeader();
    setSizeFull();
    // same as height of other tabs in details tabsheet
    setHeight(116, Unit.PIXELS);
}

From source file:org.eclipse.hawkbit.ui.common.filterlayout.AbstractFilterButtons.java

License:Open Source License

private void setStyle() {
    addStyleName(ValoTheme.TABLE_NO_STRIPES);
    addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    addStyleName(ValoTheme.TABLE_BORDERLESS);
    addStyleName(ValoTheme.TABLE_COMPACT);
}

From source file:org.eclipse.hawkbit.ui.distributions.disttype.CreateUpdateDistSetTypeLayout.java

License:Open Source License

private void buildSelectedTable() {

    selectedTable = new Table();
    selectedTable.setId(SPUIDefinitions.TWIN_TABLE_SELECTED_ID);
    selectedTable.setSelectable(true);//ww w . jav a  2  s  .c  om
    selectedTable.setMultiSelect(true);
    selectedTable.setSortEnabled(false);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    selectedTable.addStyleName(ValoTheme.TABLE_SMALL);
    selectedTable.addStyleName("dist_type_twin-table");
    selectedTable.setSizeFull();
    createSelectedTableContainer();
    selectedTable.setContainerDataSource(selectedTableContainer);
    addTooltTipToSelectedTable();
    selectedTable.setImmediate(true);
    selectedTable.setVisibleColumns(DIST_TYPE_NAME, DIST_TYPE_MANDATORY);
    selectedTable.setColumnHeaders(i18n.getMessage("header.dist.twintable.selected"), STAR);
    selectedTable.setColumnExpandRatio(DIST_TYPE_NAME, 0.75F);
    selectedTable.setColumnExpandRatio(DIST_TYPE_MANDATORY, 0.25F);
    selectedTable.setRequired(true);
}

From source file:org.eclipse.hawkbit.ui.distributions.disttype.CreateUpdateDistSetTypeLayout.java

License:Open Source License

/**
*
*//*from   ww w.j a va2  s. c o  m*/
private void buildSourceTable() {

    sourceTable = new Table();
    sourceTable.setId(SPUIDefinitions.TWIN_TABLE_SOURCE_ID);
    sourceTable.setSelectable(true);
    sourceTable.setMultiSelect(true);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    sourceTable.addStyleName(ValoTheme.TABLE_SMALL);
    sourceTable.setImmediate(true);
    sourceTable.setSizeFull();
    sourceTable.addStyleName("dist_type_twin-table");
    sourceTable.setSortEnabled(false);
    sourceTableContainer = new IndexedContainer();
    sourceTableContainer.addContainerProperty(DIST_TYPE_NAME, String.class, "");
    sourceTableContainer.addContainerProperty(DIST_TYPE_DESCRIPTION, String.class, "");
    sourceTable.setContainerDataSource(sourceTableContainer);

    sourceTable.setVisibleColumns(DIST_TYPE_NAME);
    sourceTable.setColumnHeaders(i18n.getMessage("header.dist.twintable.available"));
    sourceTable.setColumnExpandRatio(DIST_TYPE_NAME, 1.0F);
    getSourceTableData();
    addTooltip();
    sourceTable.select(sourceTable.firstItemId());
}

From source file:org.eclipse.hawkbit.ui.distributions.disttype.DistributionSetTypeSoftwareModuleSelectLayout.java

License:Open Source License

private void buildSelectedTable() {
    selectedTable = new Table();
    selectedTable.setId(SPUIDefinitions.TWIN_TABLE_SELECTED_ID);
    selectedTable.setSelectable(true);//from   www .  j  av  a2 s  .  co  m
    selectedTable.setMultiSelect(true);
    selectedTable.setSortEnabled(false);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    selectedTable.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    selectedTable.addStyleName(ValoTheme.TABLE_SMALL);
    selectedTable.addStyleName("dist_type_twin-table");
    selectedTable.setSizeFull();
    createSelectedTableContainer();
    selectedTable.setContainerDataSource(selectedTableContainer);
    addTooltTipToSelectedTable();
    selectedTable.setImmediate(true);
    selectedTable.setVisibleColumns(DIST_TYPE_NAME, DIST_TYPE_MANDATORY);
    selectedTable.setColumnHeaders(i18n.getMessage("header.dist.twintable.selected"), STAR);
    selectedTable.setColumnExpandRatio(DIST_TYPE_NAME, 0.75F);
    selectedTable.setColumnExpandRatio(DIST_TYPE_MANDATORY, 0.25F);
    selectedTable.setRequired(true);
}

From source file:org.eclipse.hawkbit.ui.distributions.disttype.DistributionSetTypeSoftwareModuleSelectLayout.java

License:Open Source License

private void buildSourceTable() {
    sourceTable = new Table();
    sourceTable.setId(SPUIDefinitions.TWIN_TABLE_SOURCE_ID);
    sourceTable.setSelectable(true);//from ww  w.  j a v  a 2s .  c  o m
    sourceTable.setMultiSelect(true);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_HORIZONTAL_LINES);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    sourceTable.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    sourceTable.addStyleName(ValoTheme.TABLE_SMALL);
    sourceTable.setImmediate(true);
    sourceTable.setSizeFull();
    sourceTable.addStyleName("dist_type_twin-table");
    sourceTable.setSortEnabled(false);
    sourceTableContainer = new IndexedContainer();
    sourceTableContainer.addContainerProperty(DIST_TYPE_NAME, String.class, "");
    sourceTableContainer.addContainerProperty(DIST_TYPE_DESCRIPTION, String.class, "");
    sourceTable.setContainerDataSource(sourceTableContainer);

    sourceTable.setVisibleColumns(DIST_TYPE_NAME);
    sourceTable.setColumnHeaders(i18n.getMessage("header.dist.twintable.available"));
    sourceTable.setColumnExpandRatio(DIST_TYPE_NAME, 1.0F);
    createSourceTableData();
    addTooltip();
    sourceTable.select(sourceTable.firstItemId());
}

From source file:org.ikasan.dashboard.ui.framework.component.DashboardTable.java

License:BSD License

public DashboardTable(String caption) {
    setCaption(caption);/*from   ww w  .jav  a2 s . co m*/

    addStyleName(ValoTheme.TABLE_BORDERLESS);
    addStyleName(ValoTheme.TABLE_NO_STRIPES);
    addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    addStyleName(ValoTheme.TABLE_SMALL);

    setSortEnabled(false);

    setRowHeaderMode(RowHeaderMode.INDEX);
    setSizeFull();
}

From source file:org.ikasan.dashboard.ui.monitor.component.MonitorPanel.java

License:BSD License

protected FilterTable buildFilterTable() {
    this.filterTable = new FilterTable(this.server.getName() + " Flow States");
    filterTable.setSizeFull();/* w  w  w . ja  v  a 2s  .co  m*/
    filterTable.setContainerDataSource(buildContainer());
    filterTable.setFilterBarVisible(true);

    filterTable.addStyleName(ValoTheme.TABLE_BORDERLESS);
    filterTable.addStyleName(ValoTheme.TABLE_NO_STRIPES);
    filterTable.addStyleName(ValoTheme.TABLE_NO_VERTICAL_LINES);
    filterTable.addStyleName(ValoTheme.TABLE_SMALL);

    filterTable.setSizeFull();
    filterTable.setImmediate(true);

    filterTable.addActionHandler(this);

    filterTable.setCellStyleGenerator(new CustomTable.CellStyleGenerator() {
        @Override
        public String getStyle(CustomTable source, Object itemId, Object propertyId) {

            Flow flow = (Flow) itemId;

            String state = stateMap.get(flow.getModule().getName() + "-" + flow.getName());

            if (propertyId == null) {
                // Styling for row         
                if (state != null && state.equals(RUNNING)) {
                    return "ikasan-green-small";
                } else if (state != null && state.equals(RECOVERING)) {
                    return "ikasan-orange-small";
                } else if (state != null && state.equals(STOPPED)) {
                    return "ikasan-red-small";
                } else if (state != null && state.equals(STOPPED_IN_ERROR)) {
                    return "ikasan-red-small";
                } else if (state != null && state.equals(PAUSED)) {
                    return "ikasan-indigo-small";
                }
            }

            if (state != null && state.equals(RUNNING)) {
                return "ikasan-green-small";
            } else if (state != null && state.equals(RECOVERING)) {
                return "ikasan-orange-small";
            } else if (state != null && state.equals(STOPPED)) {
                return "ikasan-red-small";
            } else if (state != null && state.equals(STOPPED_IN_ERROR)) {
                return "ikasan-red-small";
            } else if (state != null && state.equals(PAUSED)) {
                return "ikasan-indigo-small";
            }

            return "ikasan-small";
        }
    });

    return filterTable;
}