GOffice.GraphAxisMap¶
Fields¶
None
Methods¶
| class | new(axis, offset, length) | 
| _(value) | |
| derivative_to_view(value) | |
| finite(value) | |
| free() | |
| from_view(value) | |
| get_baseline() | |
| get_bounds() | |
| get_extents() | |
| get_real_bounds() | |
| get_real_extents() | |
| is_discrete() | |
| is_inverted() | |
| is_valid() | |
| to_view(value) | 
Details¶
- 
class GOffice.GraphAxisMap¶
- 
classmethod new(axis, offset, length)¶
- Parameters: - axis (GOffice.GraphAxis) – aGOffice.GraphAxis
- offset (float) – start of plot area.
- length (float) – length of plot area.
 - Returns: - a newly allocated - GOffice.GraphAxisMap.- Return type: - Creates a - GOffice.GraphAxisMapfor data mapping to plot window. offset and length are optional parameters to be used with- GOffice.GraphAxisMap.to_viewin order to translates data coordinates into canvas space.
- axis (
 - 
_(value)¶
- Parameters: - value ( - float) –- GOffice.valueto map to plot space.- Returns: - mapped - GOffice.value.- Return type: - float- Converts value to plot coordinates. A - GOffice.valuein [0,1.0] range means a data within axis bounds.
 - 
derivative_to_view(value)¶
- Parameters: - value ( - float) –- GOffice.valueto map to canvas space- Returns: - the derivative of the mapping expression at - GOffice.value.- Return type: - float
 - 
finite(value)¶
- Parameters: - value ( - float) –- GOffice.valueto test- Returns: - Trueif- GOffice.valuemeans something- Return type: - bool- Tests whether value is valid for the given self. 
 - 
free()¶
- Frees - GOffice.GraphAxisMapobject.
 - 
from_view(value)¶
- Parameters: - value ( - float) –- GOffice.valueto unmap from canvas space.- Returns: - GOffice.valuein data coordinates- Return type: - float- Converts - GOffice.valuefrom canvas space to data space.
 - 
get_baseline()¶
- Returns: - the baseline for self, in view coordinates, clipped to offset and offset+length, where offset and length are the parameters of - GOffice.GraphAxisMap.new.- Return type: - float
 - 
get_bounds()¶
- Returns: - minimum: - location to store minimum for this axis - maximum: - location to store maximum for this axis - Return type: - (minimum: - float, maximum:- float)- Gets bounds for the whole chart relative to the given axis map in data coordinates. If axis is invalid, it’ll return arbitrary bounds. 
 - 
get_extents()¶
- Returns: - start: - location to store start for this axis - stop: - location to store stop for this axis - Return type: - (start: - float, stop:- float)- Gets start and stop for the whole chart relative to the given axis map in data coordinates. If axis is not inverted, start = minimum and stop = maximum. If axis is invalid, it’ll return arbitrary bounds. 
 - 
get_real_bounds()¶
- Returns: - minimum: - location to store minimum for this axis - maximum: - location to store maximum for this axis - Return type: - (minimum: - float, maximum:- float)- Gets bounds for the given axis map in data coordinates. If axis is invalid, it’ll return arbitrary bounds. 
 - 
get_real_extents()¶
- Returns: - start: - location to store start for this axis - stop: - location to store stop for this axis - Return type: - (start: - float, stop:- float)- Gets start and stop for the given axis map in data coordinates. If axis is not inverted, start = minimum and stop = maximum. If axis is invalid, it’ll return arbitrary bounds. 
 - 
is_valid()¶
- Returns: - Trueif map is valid- Return type: - bool- Tests if self was correctly initialized, i.e. if bounds are valid. 
 - 
to_view(value)¶
- Parameters: - value ( - float) –- GOffice.valueto map to canvas space- Returns: - a - GOffice.valuein canvas coordinates- Return type: - float- Converts - GOffice.valuefrom data space to canvas space, using offset and length parameters given to- GOffice.GraphAxisMap.new.
 
- 
classmethod