Image_Graph_Axis (Constructor) [line 266]
Image_Graph_Axis Image_Graph_Axis(
[int
$type = IMAGE_GRAPH_AXIS_X])
|
|
Image_Graph_Axis [Constructor].
Normally a manual creation should not be necessary, axis are created automatically by the Image_Graph_Plotarea constructor unless explicitly defined otherwise
Parameters:
addMark [line 958]
void addMark(
double
$value, [double
$value2 = false], [
$text = false])
|
|
Adds a mark to the axis at the specified value
Parameters:
forceMaximum [line 427]
void forceMaximum(
double
$maximum, [bool
$userEnforce = true])
|
|
Forces the maximum value of the axis
Overridden in child classes as:
- Image_Graph_Axis_Category::forceMaximum()
- Forces the maximum value of the axis
Parameters:
forceMinimum [line 412]
hideArrow [line 447]
Do not show an arrow head on the 'end' of the axis (default)
setAxisIntersection [line 1038]
void setAxisIntersection(
mixed
$intersection, [mixed
$axis = 'default'])
|
|
Set axis intersection.
Sets the value at which the axis intersects other axis, fx. at which Y- value the x-axis intersects the y-axis (normally at 0).
Possible values are 'default', 'min', 'max' or a number between axis min and max (the value will automatically be limited to this range).
For a coordinate system with 2 y-axis, the x-axis can either intersect the primary or the secondary y-axis. To make the x-axis intersect the secondary y-axis at a given value pass IMAGE_GRAPH_AXIS_Y_SECONDARY as second parameter.
Parameters:
setDataPreProcessor [line 349]
Sets a data preprocessor for formatting the axis labels
Parameters:
setFixedSize [line 585]
void setFixedSize(
int
$size)
|
|
Sets a fixed "size" for the axis.
If the axis is any type of y-axis the size relates to the width of the axis, if an x-axis is concerned the size is the height.
Parameters:
setInverted [line 1013]
void setInverted(
bool
$invert)
|
|
Invert the axis direction
If the minimum values are normally displayed fx. at the bottom setting axis inversion to true, will cause the minimum values to be displayed at the top and maximum at the bottom.
Parameters:
setLabelInterval [line 476]
void setLabelInterval(
[mixed
$labelInterval = 'auto'], [int
$level = 1])
|
|
Sets an interval for when labels are shown on the axis.
By default 'auto' is used, forcing the axis to calculate a approximate best label interval to be used. Specify an array to use user-defined values for labels.
Overridden in child classes as:
- Image_Graph_Axis_Category::setLabelInterval()
- Sets an interval for where labels are shown on the axis.
Parameters:
setLabelOption [line 520]
void setLabelOption(
string
$option, mixed
$value, [int
$level = 1])
|
|
Sets options for the label at a specific level.
Possible options are:
'showtext' true or false whether label text should be shown or not
'showoffset' should the label be shown at an offset, i.e. should the label be shown at a position so that it does not overlap with prior levels. Only applies to multilevel labels with text
'font' The font options as an associated array
'position' The position at which the labels are written ('inside' or 'outside' the axis). NB! This relative position only applies to the default location of the axis, i.e. if an x-axis is inverted then 'outside' still refers to the "left" side of a normal y-axis (since this is normally 'outside') but the actual output will be labels on the "inside"!
'format' To format the label text according to a sprintf statement
'dateformat' To format the label as a date, fx. j. M Y = 29. Jun 2005
Parameters:
setLabelOptions [line 538]
void setLabelOptions(
array
$options, [int
$level = 1])
|
|
Sets options for the label at a specific level.
The possible options are specified in Image_Graph_Axis::.
Parameters:
setTickOptions [line 991]
void setTickOptions(
int
$start, int
$end, [int
$level = 1])
|
|
Set the major tick appearance.
The positions are specified in pixels relative to the axis, meaning that a value of -1 for start will draw the major tick 'line' starting at 1 pixel outside (negative) value the axis (i.e. below an x-axis and to the left of a normal y-axis).
Parameters:
setTitle [line 564]
Sets the title of this axis.
This is used as an alternative (maybe better) method, than using layout's for axis-title generation.
To use the current propagated font, but just set it vertically, simply pass 'vertical' as second parameter for vertical alignment down-to-up or 'vertical2' for up-to-down alignment.
Parameters:
showArrow [line 439]
Show an arrow head on the 'end' of the axis
showLabel [line 336]
void showLabel(
int
$value)
|
|
Shows a label for the the specified values.
Allowed values are combinations of:
- IMAGE_GRAPH_LABEL_MINIMUM
- IMAGE_GRAPH_LABEL_ZERO
- IMAGE_GRAPH_LABEL_MAXIMUM
By default none of these are shows on the axis
Parameters: