Class AdaptedDataVisualizer

java.lang.Object
org.eclipse.nebula.widgets.grid.AdaptedDataVisualizer
All Implemented Interfaces:
DataVisualizer

public class AdaptedDataVisualizer
extends java.lang.Object
implements DataVisualizer
A basic implementation of the DataVisualizer interface. This class can be used to provide general visualization values for various aspects of the GridItem like background, font and text. Scope of this implementation: reduce memory usage by avoid duplication of visualization data like string, fonts, and others. In this example, DataVisualizer is customized on Object named MyModel: LabelProvider is not required.
 class MyOwnDataVisualizer extends AdaptedDataVisualizer {
                FontRegistry registry = new FontRegistry();
                
                private final MyModel models[];
                
                public MyOwnDataVisualizer(MyModel models[]) {
                        this.models = models;
                }
  • Constructor Summary

    Constructors 
    Constructor Description
    AdaptedDataVisualizer()  
  • Method Summary

    Modifier and Type Method Description
    void addColumn​(int column)
    (non-Javadoc)
    void clearAll()
    Clear all data on DataVisualizer
    void clearColumn​(int column)
    Clear column dataVisualizer values
    void clearRow​(GridItem gridItem)
    Clear rows dataVisualizer values
    org.eclipse.swt.graphics.Color getBackground​(GridItem gridItem, int index)
    Method substitute GridItem method
    boolean getCheckable​(GridItem gridItem, int index)
    Method substitute GridItem method
    boolean getChecked​(GridItem gridItem, int i)
    Method substitute GridItem method
    int getColumnSpan​(GridItem gridItem, int index)
    Method substitute GridItem method
    org.eclipse.swt.graphics.Color getDefaultBackground()  
    org.eclipse.swt.graphics.Font getDefaultFont()  
    org.eclipse.swt.graphics.Color getDefaultForeground()  
    org.eclipse.swt.graphics.Font getFont​(GridItem gridItem, int index)
    Method substitute GridItem method
    org.eclipse.swt.graphics.Color getForeground​(GridItem gridItem, int index)
    Method substitute GridItem method
    boolean getGrayed​(GridItem gridItem, int index)
    Method substitute GridItem method
    org.eclipse.swt.graphics.Image getImage​(GridItem gridItem, int i)
    Method substitute GridItem method
    int getRowSpan​(GridItem gridItem, int index)
    Method substitute GridItem method
    java.lang.String getText​(GridItem gridItem, int i)
    Method substitute GridItem method
    java.lang.String getToolTipText​(GridItem gridItem, int index)
    Method substitute GridItem method
    void setBackground​(GridItem gridItem, int index, org.eclipse.swt.graphics.Color color)
    Method substitute GridItem method
    void setCheckable​(GridItem gridItem, int index, boolean checked)
    Method substitute GridItem method
    void setChecked​(GridItem gridItem, int i, boolean checked)
    Method substitute GridItem method
    void setColumnSpan​(GridItem gridItem, int index, int span)
    Method substitute GridItem method
    void setDefaultBackground​(org.eclipse.swt.graphics.Color defaultBackground)
    set default background
    void setDefaultFont​(org.eclipse.swt.graphics.Font defaultFont)
    set default font
    void setDefaultForeground​(org.eclipse.swt.graphics.Color defaultForeground)
    set default foreground
    void setFont​(GridItem gridItem, int index, org.eclipse.swt.graphics.Font font)
    Method substitute GridItem method
    void setForeground​(GridItem gridItem, int index, org.eclipse.swt.graphics.Color foreground)
    Method substitute GridItem method
    void setGrayed​(GridItem gridItem, int i, boolean grayed)
    Method substitute GridItem method
    void setImage​(GridItem gridItem, int i, org.eclipse.swt.graphics.Image image)
    Method substitute GridItem method
    void setRowSpan​(GridItem gridItem, int index, int span)
    Method substitute GridItem method
    void setText​(GridItem gridItem, int i, java.lang.String text)
    Method substitute GridItem method
    void setToolTipText​(GridItem gridItem, int index, java.lang.String tooltip)
    Method substitute GridItem method

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait