org.gudy.azureus2.ui.swt.components
Class Legend
java.lang.Object
org.gudy.azureus2.ui.swt.components.Legend
public class Legend
- extends Object
TODO: have a callback when color changes
Method Summary |
static org.eclipse.swt.widgets.Composite |
createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys)
Create a legend containing a modifyable color box and description |
static org.eclipse.swt.widgets.Composite |
createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
boolean horizontal)
|
static org.eclipse.swt.widgets.Composite |
createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
Object layoutData)
|
static org.eclipse.swt.widgets.Composite |
createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
String[] key_texts,
Object layoutData,
boolean horizontal)
Create a legend containing a modifyable color box and description |
static org.eclipse.swt.widgets.Composite |
createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
String[] key_texts,
Object layoutData,
boolean horizontal,
Legend.LegendListener listener)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Legend
public Legend()
createLegendComposite
public static org.eclipse.swt.widgets.Composite createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys)
- Create a legend containing a modifyable color box and description
- Parameters:
panel
- Where to add legend toblockColors
- array of colors for each legend entry. This
array WILL BE modified if the user changes the colorkeys
- array of keys for each legend entry
- Returns:
- The composite containing the legend
createLegendComposite
public static org.eclipse.swt.widgets.Composite createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
boolean horizontal)
createLegendComposite
public static org.eclipse.swt.widgets.Composite createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
Object layoutData)
createLegendComposite
public static org.eclipse.swt.widgets.Composite createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
String[] key_texts,
Object layoutData,
boolean horizontal)
- Create a legend containing a modifyable color box and description
- Parameters:
panel
- Where to add legend toblockColors
- array of colors for each legend entry. This
array WILL BE modified if the user changes the colorkeys
- array of keys for each legend entrylayoutData
- How to layout the legend (ie. GridData, LayoutData, etc)
- Returns:
- The composite containing the legend
createLegendComposite
public static org.eclipse.swt.widgets.Composite createLegendComposite(org.eclipse.swt.widgets.Composite panel,
org.eclipse.swt.graphics.Color[] blockColors,
String[] keys,
String[] key_texts,
Object layoutData,
boolean horizontal,
Legend.LegendListener listener)