CartesianCoordinateSystem

A description for CartesianCoordinateSystem.

class CartesianCoordinateSystem : public AbstractCoordinateSystem

Cartesian coordinate system for plots.

Public Functions

void mapLogicalToScene(const Points &logicalPoints, Points &scenePoints, std::vector<bool> &visiblePoints, MappingFlags flags = MappingFlag::DefaultMapping) const

Maps the points in logical coordinates from points and fills the visiblePoints with the points in logical coordinates restricted to the current intervals.

Parameters:
  • logicalPoints – List of points in logical coordinates

  • scenePoints – List for the points in scene coordinates

  • visiblePoints – List for the logical coordinates restricted to the current region of the coordinate system

  • flags

void mapLogicalToScene(int startIndex, int endIndex, const Points &logicalPoints, Points &scenePoints, std::vector<bool> &visiblePoints, MappingFlags flags = MappingFlag::DefaultMapping) const

Maps the points in logical coordinates from points and fills the visiblePoints with the points in logical coordinates restricted to the current intervals. If there are points, that lie on another one they will not be added a second time.

Parameters:
  • logicalPoints – List of points in logical coordinates

  • scenePoints – List for the points in scene coordinates

  • visiblePoints – List for the logical coordinates restricted to the current region of the coordinate system

void mapLogicalToSceneDefaultMapping(Lines &lines) const

CartesianCoordinateSystem::mapLogicalToSceneDefaultMapping.

Optimized version of mapLogicalToScene(const Lines& lines, MappingFlags flags) It does not create a new line vector, but replaces the elements of the vector

Parameters:

lines

int direction(const Dimension) const

Determine the direction relative to the page in different directions.

This function is needed for untransformed lengths such as axis tick length.

Returns:

1 or -1