|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel org.proteinshader.gui.components.controlpanel.ColorPanel org.proteinshader.gui.components.controlpanel.AtomColorPanel
public class AtomColorPanel
This control panel allows the user to modify the color of Atoms.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
static String |
MENU_NAME
The menu name "Color" will be returned by toString(). |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
AtomColorPanel(Mediator mediator,
Frame dialogOwner,
RadioPanel radioPanel)
Constructs a ColorPanel. |
Method Summary | |
---|---|
void |
modifyGlobal(float red,
float green,
float blue)
Prepares the AtomModifier to modify the RGB color of Atoms, and then calls on the modifyGlobal() method of the RadioPanel. |
void |
modifyGlobalToDefault1()
Default 1 sets the RGB color of Atoms based on Atom type. |
void |
modifyGlobalToDefault2()
Default 2 sets the RGB color of Atoms based on AminoAcid type. |
void |
modifyHelices(float red,
float green,
float blue)
Prepares the the AtomModifier to modify the RGB color of Atoms, and then calls on the modifyHelices() method of the RadioPanel. |
void |
modifyHelicesToDefault1()
Default 1 sets the RGB color of Atoms based on Atom type. |
void |
modifyHelicesToDefault2()
Default 2 sets the RGB color of Atoms based on AminoAcid type. |
void |
modifyLoops(float red,
float green,
float blue)
Prepares the AtomModifier to modify the RGB color of Atoms, and then calls on the modifyLoops() method of the RadioPanel. |
void |
modifyLoopsToDefault1()
Default 1 sets the RGB color of Atoms based on Atom type. |
void |
modifyLoopsToDefault2()
Default 2 sets the RGB color of Atoms based on AminoAcid type. |
void |
modifySelected(float red,
float green,
float blue)
Prepares the AtomModifier to modify the RGB color of Atoms, and then calls on the modifySelected() method of the RadioPanel. |
void |
modifySelectedToDefault1()
Default 1 sets the RGB color of Atoms based on Atom type. |
void |
modifySelectedToDefault2()
Default 2 sets the RGB color of Atoms based on AminoAcid type. |
void |
modifyStrands(float red,
float green,
float blue)
Prepares the AtomModifier to modify the RGB color of Atoms, and then calls on the modifyStrands() method of the RadioPanel. |
void |
modifyStrandsToDefault1()
Default 1 sets the RGB color of Atoms based on Atom type. |
void |
modifyStrandsToDefault2()
Default 2 sets the RGB color of Atoms based on AminoAcid type. |
void |
setColor(float red,
float green,
float blue)
Clears the Atom modifier and sets the RGB colors. |
String |
toString()
Returns a name suitable for use in a menu. |
Methods inherited from class org.proteinshader.gui.components.controlpanel.ColorPanel |
---|
applyColors, applyDefaultColors1, applyDefaultColors2, modifyGlobal, modifyHelices, modifyLoops, modifySelected, modifyStrands, openColorChooser |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String MENU_NAME
Constructor Detail |
---|
public AtomColorPanel(Mediator mediator, Frame dialogOwner, RadioPanel radioPanel)
mediator
- the centralized Mediator that most listeners
need to call on to accomplish their task.dialogOwner
- the owner of any Dialogs opened from the
SelectorPanel (or null if there is no
requested owner).radioPanel
- the common RadioPanel used by subpanels.Method Detail |
---|
public void modifySelected(float red, float green, float blue) throws ColorOutOfRangeException
modifySelected
in class ColorPanel
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.public void modifyHelices(float red, float green, float blue) throws ColorOutOfRangeException
modifyHelices
in class ColorPanel
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.public void modifyStrands(float red, float green, float blue) throws ColorOutOfRangeException
modifyStrands
in class ColorPanel
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.public void modifyLoops(float red, float green, float blue) throws ColorOutOfRangeException
modifyLoops
in class ColorPanel
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.public void modifyGlobal(float red, float green, float blue) throws ColorOutOfRangeException
modifyGlobal
in class ColorPanel
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.public void modifySelectedToDefault1()
modifySelectedToDefault1
in class ColorPanel
public void modifyHelicesToDefault1()
modifyHelicesToDefault1
in class ColorPanel
public void modifyStrandsToDefault1()
modifyStrandsToDefault1
in class ColorPanel
public void modifyLoopsToDefault1()
modifyLoopsToDefault1
in class ColorPanel
public void modifyGlobalToDefault1()
modifyGlobalToDefault1
in class ColorPanel
public void modifySelectedToDefault2()
modifySelectedToDefault2
in class ColorPanel
public void modifyHelicesToDefault2()
modifyHelicesToDefault2
in class ColorPanel
public void modifyStrandsToDefault2()
modifyStrandsToDefault2
in class ColorPanel
public void modifyLoopsToDefault2()
modifyLoopsToDefault2
in class ColorPanel
public void modifyGlobalToDefault2()
modifyGlobalToDefault2
in class ColorPanel
public String toString()
toString
in class Component
public void setColor(float red, float green, float blue) throws ColorOutOfRangeException
red
- the red component of the RGB color to set.green
- the green component of the RGB color to set.blue
- the blue component of the RGB color to set.
ColorOutOfRangeException
- if a color is less than 0.0 or
greater than 1.0.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |