public class GSliderRealWithLabel extends GSliderAbstractWithLabel implements GListener, GReadWrite, GClear
| Index | Class | Item | Constraint |
| 0 | GLabelWithIndicator | label | 0, 0 => "newline , split 2" 0, 1 => (null) |
| 1 | GRealField | setValueEntry | (null) |
| 2 | GPopupList | units | (null) |
| 3 | GSliderReal | slider | "newline" |
GComponent.CopyPasteOperation, GComponent.DisplayIndicatorStatus, GComponent.ItemType, GComponent.OperationNAME_ATTRIBUTE| Constructor and Description |
|---|
GSliderRealWithLabel(String label,
String orientation,
double minVal,
double maxVal,
double initVal,
double spacing,
int fracDigits)
Constructor.
|
GSliderRealWithLabel(String label,
String orientation,
double minVal,
double maxVal,
double initVal,
double spacing,
int fracDigits,
GUnit[] units)
Constructor.
|
GSliderRealWithLabel(String widgetId,
String label,
String orientation,
double minVal,
double maxVal,
double initVal,
double spacing,
int fracDigits)
Constructor.
|
GSliderRealWithLabel(String widgetId,
String label,
String orientation,
double minVal,
double maxVal,
double initVal,
double spacing,
int fracDigits,
GUnit[] units)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
after(GEvent e)
Called after the event is processed.
|
void |
before(GEvent e)
Called before the event is processed.
|
void |
clear()
Called when the element is to be cleared, so it can perform the actions required to return to the last
saved/loaded values.
|
String |
getFormattedValue(Number value)
Return the value of the slider in the SCIENTIFIC format that shall be used to read/write from/to file.
|
int |
getFracDigits()
Get the number of fractional digits.
|
double |
getSavedValue()
Get the saved value.
|
double |
getValue()
Get the value of the slider.
|
boolean |
isModified()
Gets the modification status of the component against the last set of values loaded or saved.
|
void |
read()
Implementaion of the routines that allow the component to be loaded from a configuration file.
|
void |
setDefaultValue(double memoryValue)
Set the default value.
|
void |
setFracDigits(int fracDigits)
Set the number of fractional digits.
|
void |
setSavedValue(double memoryValue)
Set the saved value.
|
void |
setValue(double value)
Set the value of the slider.
|
protected void |
updateIsModifiedIndicator()
Updates the is modified indicator.
|
void |
write()
Implementaion of the routines that allow the component to be saved to a configuration file.
|
addGInterval, attachCopyPasteMenu, display, generic, getGLabelWithIndicator, getGSlider, getNumber, getSetValueEntry, getSubComponent, isCopyPasteEvent, isEnabled, removeGInterval, setDefaultConstraints, setEnabled, setStringConstraint, setToolTipText, setUnitPoupList, updateGInterval, updateStatusputactivateConstraintsByType, attachCopyPasteMenu, beginOfElement, beginOfElement, beginOfElement, beginOfElement, clearAllInnerDescendantConstraint, clearConstraint, clearInnerDescendantContraint, composeWidgetId, doDisplay, endOfElement, getCommentInConfigFile, getComponent, getConstraint, getCurrentOperation, getDisplayIndicatorStatus, getDisplayIsModifiedIndicator, getElement, getGClassName, getGPanel, getGParent, getGUnitInConfigFile, getInnerDescendantConstraint, getName, getNameInConfigFile, getOperationSaveValue, getPathInConfigFile, getSimpleWidgetId, getStatus, getStringConstraint, getWidgetId, handleCopyPasteEvent, handleCopyPasteEvent, handleProcessEventException, isForcedStatus, launchInvalidPositionException, mouseWheelMoved, parseSimpleConstraint, processGEvent, processMouseWheelEvent, setBusyCursor, setCommentInConfigFile, setConstraint, setCopyPasteMenuEnabled, setCurrentOperation, setDataForConstraintsByType, setDisplayIsModifiedIndicator, setElement, setForcedStatus, setGPanel, setGParent, setGUnitInConfigFile, setInnerDescendantConstraint, setName, setNameAndCommentInConfigFile, setNameInConfigFile, setPathInConfigFile, setStatus, setWidgetId, setWidth, setWindowBusyCursor, writeCollection, writeCollection, writeCollection, writeCollection, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItempublic GSliderRealWithLabel(String label, String orientation, double minVal, double maxVal, double initVal, double spacing, int fracDigits, GUnit[] units)
label - of the widget.orientation - of the slider; can have the value "VERTICAL" or "HORIZONTAL", default is "HORIZONTAL".minVal - minimum value.maxVal - maximum value.initVal - initial value.spacing - spacing between the ticks.fracDigits - number of significant digits after the decimal point in the labels.units - list of units to display in the unit menu.public GSliderRealWithLabel(String label, String orientation, double minVal, double maxVal, double initVal, double spacing, int fracDigits)
label - of the widget.orientation - of the slider; can have the value "VERTICAL" or "HORIZONTAL", default is "HORIZONTAL".minVal - minimum value.maxVal - maximum value.initVal - initial value.spacing - spacing between the ticks.fracDigits - number of significant digits after the decimal point in the labels.public GSliderRealWithLabel(String widgetId, String label, String orientation, double minVal, double maxVal, double initVal, double spacing, int fracDigits)
widgetId - widget identifier.label - of the widget.orientation - of the slider; can have the value "VERTICAL" or "HORIZONTAL", default is "HORIZONTAL".minVal - minimum value.maxVal - maximum value.initVal - initial value.spacing - spacing between the ticks.fracDigits - number of significant digits after the decimal point in the labels.public GSliderRealWithLabel(String widgetId, String label, String orientation, double minVal, double maxVal, double initVal, double spacing, int fracDigits, GUnit[] units)
widgetId - widget identifier.label - of the widget.orientation - of the slider; can have the value "VERTICAL" or "HORIZONTAL", default is "HORIZONTAL".minVal - minimum value.maxVal - maximum value.initVal - initial value.spacing - spacing between the ticks.fracDigits - number of significant digits after the decimal point in the labels.units - list of units to display in the unit menu.public double getValue()
public void setValue(double value)
throws GArithmeticException
value - to set.GArithmeticException - if value is NaNpublic void setDefaultValue(double memoryValue)
throws GArithmeticException
memoryValue - new default value.GArithmeticException - if memoryValue is NaN.public void setSavedValue(double memoryValue)
throws GArithmeticException
memoryValue - new saved value.GArithmeticException - if memoryValue is NaN.public double getSavedValue()
public void setFracDigits(int fracDigits)
throws GEntryRealException
fracDigits - number of fractional digits.GEntryRealException - launched when the number of fractional digits is greater than MAX_FRAC_DIGITS.public int getFracDigits()
public String getFormattedValue(Number value)
value - to format.public void before(GEvent e) throws GException
before in interface GListenere - event to processed.GException - in case there is a problem managing the event.public void after(GEvent e) throws GException, GFileManipulatorException
after in interface GListenere - processed event.GException - in case there is a problem managing the event.GFileManipulatorExceptionpublic void read()
throws GException
read in interface GReadWriteGException - in case of problem while reading the value from file.public void write()
throws GException
write in interface GReadWriteGException - in case of problem while writing the value to file.public boolean isModified()
isModified in class GSliderAbstractWithLabelpublic void clear()
throws GException
clear in interface GClearGException - in case of problem while clearing the values.protected void updateIsModifiedIndicator()
updateIsModifiedIndicator in class GComponentCopyright © 2024. All rights reserved.