net.sf.commonclipse.preferences
Class LabelFieldEditor

java.lang.Object
  extended by org.eclipse.jface.preference.FieldEditor
      extended by net.sf.commonclipse.preferences.LabelFieldEditor
Direct Known Subclasses:
SpacerFieldEditor

 class LabelFieldEditor
extends org.eclipse.jface.preference.FieldEditor

A field editor for displaying labels not associated with other widgets.

Version:
$Revision: 1.3 $ ($Author: fgiust $)
Author:
fgiust

Field Summary
 
Fields inherited from class org.eclipse.jface.preference.FieldEditor
HORIZONTAL_GAP, IS_VALID, VALUE
 
Constructor Summary
LabelFieldEditor(java.lang.String labelText, org.eclipse.swt.widgets.Composite parent)
          All labels can use the same preference name since they don't store any preference.
 
Method Summary
protected  void adjustForNumColumns(int numColumns)
          Adjusts the field editor to be displayed correctly for the given number of columns.
protected  void doFillIntoGrid(org.eclipse.swt.widgets.Composite parent, int numColumns)
          Fills the field editor's controls into the given parent.
protected  void doLoad()
          Labels do not persist any preferences, so this method is empty.
protected  void doLoadDefault()
          Labels do not persist any preferences, so this method is empty.
protected  void doStore()
          Labels do not persist any preferences, so this method is empty.
 int getNumberOfControls()
          Returns the number of controls in the field editor.
 
Methods inherited from class org.eclipse.jface.preference.FieldEditor
applyFont, checkParent, clearErrorMessage, clearMessage, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, createControl, dispose, fillIntoGrid, fireStateChanged, fireValueChanged, getFieldEditorFontName, getLabelControl, getLabelControl, getLabelText, getPage, getPreferenceName, getPreferencePage, getPreferenceStore, init, isValid, load, loadDefault, presentsDefaultValue, refreshValidState, setButtonLayoutData, setEnabled, setFocus, setLabelText, setPage, setPreferenceName, setPreferencePage, setPreferenceStore, setPresentsDefaultValue, setPropertyChangeListener, showErrorMessage, showMessage, store
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LabelFieldEditor

public LabelFieldEditor(java.lang.String labelText,
                        org.eclipse.swt.widgets.Composite parent)
All labels can use the same preference name since they don't store any preference.

Parameters:
labelText - text for the label
parent - Composite
Method Detail

adjustForNumColumns

protected void adjustForNumColumns(int numColumns)
Adjusts the field editor to be displayed correctly for the given number of columns.

Specified by:
adjustForNumColumns in class org.eclipse.jface.preference.FieldEditor
Parameters:
numColumns - number of columns

doFillIntoGrid

protected void doFillIntoGrid(org.eclipse.swt.widgets.Composite parent,
                              int numColumns)
Fills the field editor's controls into the given parent.

Specified by:
doFillIntoGrid in class org.eclipse.jface.preference.FieldEditor
Parameters:
parent - Composite
numColumns - cumber of columns

getNumberOfControls

public int getNumberOfControls()
Returns the number of controls in the field editor.

Specified by:
getNumberOfControls in class org.eclipse.jface.preference.FieldEditor
Returns:
1

doLoad

protected void doLoad()
Labels do not persist any preferences, so this method is empty.

Specified by:
doLoad in class org.eclipse.jface.preference.FieldEditor

doLoadDefault

protected void doLoadDefault()
Labels do not persist any preferences, so this method is empty.

Specified by:
doLoadDefault in class org.eclipse.jface.preference.FieldEditor

doStore

protected void doStore()
Labels do not persist any preferences, so this method is empty.

Specified by:
doStore in class org.eclipse.jface.preference.FieldEditor


Copyright © 2003-2005 sourceforge. All Rights Reserved.