|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectetomica.graphics.Device
etomica.graphics.DeviceTernarySelector
public class DeviceTernarySelector
Selector for fractions in a ternary system. Presents a triangle that can be clicked upon to select (for example) the three mole fractions of a ternary mixture.
| Nested Class Summary | |
|---|---|
static interface |
DeviceTernarySelector.Listener
|
protected static class |
DeviceTernarySelector.MyEventManager
|
| Nested classes/interfaces inherited from class etomica.graphics.Device |
|---|
Device.ActionSet |
| Field Summary |
|---|
| Fields inherited from class etomica.graphics.Device |
|---|
controller, unit |
| Constructor Summary | |
|---|---|
DeviceTernarySelector()
|
|
DeviceTernarySelector(String[] labels)
Creates a new devices using the given labels for the diagram. |
|
| Method Summary | |
|---|---|
void |
addListener(DeviceTernarySelector.Listener listener)
|
static EtomicaInfo |
getEtomicaInfo()
|
String[] |
getLabels()
Accessor method for the labels. |
int |
getPrecision()
Accessor method for the precision of the mole fractions. |
int |
getSideLength()
Accessor method for the length of each side of the triangle, in pixels. |
String[] |
getSymbols()
Accessor method for the symbols. |
Component |
graphic(Object obj)
Graphical display given by this device. |
boolean |
isShowValues()
Accessor method for flag indicating if values are shown in accompanying text boxes. |
void |
removeListener(DeviceTernarySelector.Listener listener)
|
void |
setLabels(String[] newLabels)
Labels used to indicate the three component fractions. |
void |
setPrecision(int n)
Mutatator method for the precision of the mole fractions. |
void |
setShowValues(boolean b)
Mutator method for flag indicating whether a set of boxes is displayed with labels and fraction values as text. |
void |
setSideLength(int L)
Mutator method for the length of each side of the triangle, in pixels. |
void |
setSymbols(String[] newSymbols)
Symbols used to label each vertex of the triangle. |
| Methods inherited from class etomica.graphics.Device |
|---|
doAction, getController, getDimension, getPostAction, getPreAction, getUnit, graphic, setController, setPostAction, setPreAction, setUnit |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DeviceTernarySelector()
public DeviceTernarySelector(String[] labels)
| Method Detail |
|---|
public static EtomicaInfo getEtomicaInfo()
public void addListener(DeviceTernarySelector.Listener listener)
public void removeListener(DeviceTernarySelector.Listener listener)
public void setPrecision(int n)
public int getPrecision()
public void setShowValues(boolean b)
public boolean isShowValues()
public void setSideLength(int L)
public int getSideLength()
public void setLabels(String[] newLabels)
public String[] getLabels()
public void setSymbols(String[] newSymbols)
public String[] getSymbols()
public Component graphic(Object obj)
graphic in interface GraphicalElementgraphic in class Deviceobj - An object that might be used to specify the graphic that the GraphicalElement is to return.
In most cases the GraphicalElement ignores this parameter, and it can be set to null.
Device,
Display
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||