Examples of ConfigRegistry


Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

    public Control createExampleControl(Composite parent) {
        final String[] propertyNames = RowDataListFixture.getPropertyNames();
        final Map<String, String> propertyToLabelMap = RowDataListFixture
                .getPropertyToLabelMap();

        ConfigRegistry configRegistry = new ConfigRegistry();

        // Body
        LinkedList<BlinkingRowDataFixture> rowData = new LinkedList<BlinkingRowDataFixture>();
        EventList<BlinkingRowDataFixture> eventList = GlazedLists
                .eventList(rowData);
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        Composite buttonPanel = new Composite(panel, SWT.NONE);
        buttonPanel.setLayout(new GridLayout());
        GridDataFactory.fillDefaults().grab(true, true).applyTo(buttonPanel);

        ConfigRegistry configRegistry = new ConfigRegistry();

        final GlazedListsGridLayer<Map<String, String>> glazedListsGridLayer = new GlazedListsGridLayer<Map<String, String>>(
                values, new MyColumnPropertyAccessor(),
                new SimpleColumnHeaderDataProvider(), configRegistry, true);
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        rowObjectsGlazedList = GlazedLists.threadSafeList(eventList);
        Map<String, String> propertyToLabelMap = populateColHeaderPropertiesToLabelsMap();
        String[] propertyNames = propertyToLabelMap.keySet().toArray(
                ArrayUtil.STRING_TYPE_ARRAY);

        ConfigRegistry configRegistry = new ConfigRegistry();
        final ColumnStructureUpdatesExampleGridLayer<PricingDataBean> glazedListsGridLayer = new ColumnStructureUpdatesExampleGridLayer<PricingDataBean>(
                rowObjectsGlazedList, propertyNames, propertyToLabelMap,
                configRegistry, true);
        final NatTable natTable = new NatTable(parent, glazedListsGridLayer,
                false);
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        propertyToLabelMap.put("fromDate", "From");
        propertyToLabelMap.put("toDate", "To");

        valuesToShow.addAll(createEventData());

        ConfigRegistry configRegistry = new ConfigRegistry();
        DefaultGridLayer gridLayer = new DefaultGridLayer(valuesToShow,
                propertyNames, propertyToLabelMap);
        DataLayer bodyDataLayer = (DataLayer) gridLayer.getBodyDataLayer();

        IRowDataProvider<EventData> bodyDataProvider = (IRowDataProvider<EventData>) bodyDataLayer
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        StandaloneNatExampleRunner.run(new PersistentNatExampleWrapper(
                new FilterRowGridExample()));
    }

    public Control createExampleControl(Composite parent) {
        IConfigRegistry configRegistry = new ConfigRegistry();
        ILayer underlyingLayer = new FilterRowExampleGridLayer(configRegistry);

        NatTable natTable = new NatTable(parent, underlyingLayer, false);
        natTable.addConfiguration(new DefaultNatTableStyleConfiguration());
        natTable.addConfiguration(new HeaderMenuConfiguration(natTable));
        // natTable.addConfiguration(new DebugMenuConfiguration(natTable));
        natTable.addConfiguration(new FilterRowCustomConfiguration() {
            @Override
            public void configureRegistry(IConfigRegistry configRegistry) {
                super.configureRegistry(configRegistry);

                // Shade the row to be slightly darker than the blue background.
                final Style rowStyle = new Style();
                rowStyle.setAttributeValue(
                        CellStyleAttributes.BACKGROUND_COLOR,
                        GUIHelper.getColor(197, 212, 231));
                configRegistry.registerConfigAttribute(
                        CellConfigAttributes.CELL_STYLE, rowStyle,
                        DisplayMode.NORMAL, GridRegion.FILTER_ROW);
            }
        });
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

    public Control createExampleControl(Composite parent) {
        EventList<RowDataFixture> eventList = GlazedLists
                .eventList(RowDataListFixture.getList());
        rowObjectsGlazedList = GlazedLists.threadSafeList(eventList);

        ConfigRegistry configRegistry = new ConfigRegistry();
        GlazedListsGridLayer<RowDataFixture> glazedListsGridLayer = new GlazedListsGridLayer<RowDataFixture>(
                rowObjectsGlazedList, RowDataListFixture.getPropertyNames(),
                RowDataListFixture.getPropertyToLabelMap(), configRegistry);

        nattable = new NatTable(parent, glazedListsGridLayer, false);
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        cellLabelAccumulator.registerOverride("AAA", 2, CELL_LABEL);

        // Register your cell style, against the label applied to the cell
        // Other configuration which can be added (apart from style) include
        // CellConfigAttributes, EditConfigAttributes, SortConfigAttributes etc.
        IConfigRegistry configRegistry = new ConfigRegistry();
        addColumnHighlight(configRegistry);

        // Register label accumulator
        bodyDataLayer.setConfigLabelAccumulator(cellLabelAccumulator);
        gridLayer.getSelectionLayer().addConfiguration(
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

    public Control createExampleControl(Composite parent) {
        final String[] propertyNames = RowDataListFixture.getPropertyNames();
        final Map<String, String> propertyToLabelMap = RowDataListFixture
                .getPropertyToLabelMap();

        ConfigRegistry configRegistry = new ConfigRegistry();
        ColumnGroupModel columnGroupModel = new ColumnGroupModel();

        // Body

        LinkedList<BlinkingRowDataFixture> rowData = new LinkedList<BlinkingRowDataFixture>();
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

                + "It is also sortable and editable and has a filter row to show that the static filter\n"
                + "also works with some other features.";
    }

    public Control createExampleControl(Composite parent) {
        IConfigRegistry configRegistry = new ConfigRegistry();
        StaticFilterExampleGridLayer underlyingLayer = new StaticFilterExampleGridLayer(
                configRegistry);

        DataLayer bodyDataLayer = underlyingLayer.getBodyDataLayer();
        IDataProvider dataProvider = underlyingLayer.getBodyDataProvider();
View Full Code Here

Examples of org.eclipse.nebula.widgets.nattable.config.ConfigRegistry

        baseTupleList.add(new Tuple(headers, new Object[] { "Name 4",
                "Value 4", -4.5d, 4000 }, 3));
        baseTupleList.add(new Tuple(headers, new Object[] { "Name 5",
                "Value 5", 5.5d, -5000 }, 4));

        ConfigRegistry configRegistry = new ConfigRegistry();

        ObservableElementList<Tuple> observableTupleList = new ObservableElementList<Tuple>(
                baseTupleList, GlazedLists.beanConnector(Tuple.class));
        TupleColumnPropertyAccessor columnPropertyAccessor = new TupleColumnPropertyAccessor();
        ListDataProvider<Tuple> bodyDataProvider = new ListDataProvider<Tuple>(
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.