Constructor and Description |
---|
Axis()
Creates an axis using no converters for the coordinates.
|
Axis(DoubleUnaryOperator chartXConverter,
DoubleUnaryOperator chartYConverter)
Creates an axis using converters for the coordinates.
|
Modifier and Type | Method and Description |
---|---|
void |
addRefreshListener(RefreshListener listener)
Adds a refresh listener that is called whenever this
Drawable needs to be
redrawn by the GUI. |
Axis |
arrowSize(double newArrowSize)
Sets the size of the arrow at the end of the graph.
|
Axis |
bigTickSize(int newBigTickSize)
Sets the size of the big ticks in pixels.
|
Axis |
bigTickSteps(int newBigTickSteps)
Sets the range after which a big tick is painted on the graph.
|
double |
getArrowSize()
Returns the size of the arrow at the end of the graph.
|
int |
getBigTickSize()
Returns the size of the big ticks in pixels.
|
int |
getBigTickSteps()
Returns the range after which a big tick is painted on the graph.
|
int |
getTickSize()
Returns the size of the ticks in pixels.
|
int |
getTickSteps()
Returns the range after which a tick is painted on the graph.
|
void |
removeRefreshListener(RefreshListener listener)
Removes a refresh listener that was called whenever this
Drawable needed to
be redrawn by the GUI. |
void |
setArrowSize(double arrowSize)
Sets the size of the arrow at the end of the graph.
|
void |
setBigTickSize(int bigTickSize)
Sets the size of the big ticks in pixels.
|
void |
setBigTickSteps(int bigTickSteps)
Sets the range after which a big tick is painted on the graph.
|
void |
setTickSize(int tickSize)
Sets the size of the ticks in pixels.
|
void |
setTickSteps(int tickSteps)
Sets the range after which a tick is painted on the graph.
|
Axis |
tickSize(int newTickSize)
Sets the size of the ticks in pixels.
|
Axis |
tickSteps(int newTickSteps)
Sets the range after which a tick is painted on the graph.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
paintOn, snipNecessarySpace
public Axis()
public Axis(DoubleUnaryOperator chartXConverter, DoubleUnaryOperator chartYConverter)
chartXConverter
- converter for graph x to chart xchartYConverter
- converter for graph y to chart ypublic void addRefreshListener(RefreshListener listener)
Drawable
Drawable
needs to be
redrawn by the GUI.addRefreshListener
in interface Drawable
listener
- a listenerpublic void removeRefreshListener(RefreshListener listener)
Drawable
Drawable
needed to
be redrawn by the GUI. Does nothing if the listener was never added.removeRefreshListener
in interface Drawable
listener
- a listenerpublic int getTickSize()
public Axis tickSize(int newTickSize)
newTickSize
- the tick sizepublic void setTickSize(int tickSize)
tickSize
- the tick sizepublic int getBigTickSize()
public Axis bigTickSize(int newBigTickSize)
newBigTickSize
- the big tick sizepublic void setBigTickSize(int bigTickSize)
bigTickSize
- the big tick sizepublic int getBigTickSteps()
public Axis bigTickSteps(int newBigTickSteps)
newBigTickSteps
- the big tick step lengthpublic void setBigTickSteps(int bigTickSteps)
bigTickSteps
- the big tick step lengthpublic int getTickSteps()
public Axis tickSteps(int newTickSteps)
newTickSteps
- the tick step lengthpublic void setTickSteps(int tickSteps)
tickSteps
- the tick step lengthpublic double getArrowSize()
public Axis arrowSize(double newArrowSize)
newArrowSize
- the arrow size in pixelspublic void setArrowSize(double arrowSize)
arrowSize
- the arrow size in pixelsCopyright © 2020. All rights reserved.