| edu.rice.cs.drjava.ui.config.ColorOptionComponent
ColorOptionComponent | public class ColorOptionComponent extends OptionComponent (Code) | | Graphical form of a ColorOption.
version: $Id: ColorOptionComponent.java 4255 2007-08-28 19:17:37Z mgricken $ |
Constructor Summary | |
public | ColorOptionComponent(ColorOption opt, String text, Frame parent) Main constructor for ColorOptionComponent. | public | ColorOptionComponent(ColorOption opt, String text, Frame parent, boolean isBackgroundColor) An alternate constructor, allowing the caller to specify whether this color is a background color. | public | ColorOptionComponent(ColorOption opt, String text, Frame parent, boolean isBackgroundColor, boolean isBoldText) | public | ColorOptionComponent(ColorOption opt, String text, Frame parent, String description) Constructor that allows for a tooltip description. | public | ColorOptionComponent(ColorOption opt, String text, Frame parent, String description, boolean isBackgroundColor) Constructor that allows for a tooltip description as well as whether or not this is a background color. | public | ColorOptionComponent(ColorOption opt, String text, Frame parent, String description, boolean isBackgroundColor, boolean isBoldText) Constructor that allows for a tooltip description as well as whether or not this is a background color. |
Method Summary | |
public void | chooseColor() Shows a color chooser dialog for picking a new color. | public JComponent | getComponent() Return's this OptionComponent's configurable component. | public void | setDescription(String description) Sets the tooltip description text for this option. | public void | setValue(Color value) Displays the given value. | public boolean | updateConfig() Updates the config object with the new setting. |
ColorOptionComponent | public ColorOptionComponent(ColorOption opt, String text, Frame parent)(Code) | | Main constructor for ColorOptionComponent.
Parameters: opt - The ColorOption to display Parameters: text - The text to display in the label of the component Parameters: parent - The Frame displaying this component |
ColorOptionComponent | public ColorOptionComponent(ColorOption opt, String text, Frame parent, boolean isBackgroundColor)(Code) | | An alternate constructor, allowing the caller to specify whether this color is a background color. If so,
the button will display the color as its background.
|
ColorOptionComponent | public ColorOptionComponent(ColorOption opt, String text, Frame parent, boolean isBackgroundColor, boolean isBoldText)(Code) | | |
ColorOptionComponent | public ColorOptionComponent(ColorOption opt, String text, Frame parent, String description, boolean isBackgroundColor)(Code) | | Constructor that allows for a tooltip description as well as whether or not this is a background color.
|
ColorOptionComponent | public ColorOptionComponent(ColorOption opt, String text, Frame parent, String description, boolean isBackgroundColor, boolean isBoldText)(Code) | | Constructor that allows for a tooltip description as well as whether or not this is a background color.
|
chooseColor | public void chooseColor()(Code) | | Shows a color chooser dialog for picking a new color.
|
getComponent | public JComponent getComponent()(Code) | | Return's this OptionComponent's configurable component.
|
setDescription | public void setDescription(String description)(Code) | | Sets the tooltip description text for this option.
Parameters: description - the tooltip text |
setValue | public void setValue(Color value)(Code) | | Displays the given value.
|
updateConfig | public boolean updateConfig()(Code) | | Updates the config object with the new setting.
true if the new value is set successfully |
|
|