Engauge Digitizer  2
Public Member Functions | List of all members
CallbackAddPointsInCurvesGraphs Class Reference

Callback that is used when iterating through a read-only CurvesGraphs to add corresponding points in Document. More...

#include <CallbackAddPointsInCurvesGraphs.h>

Collaboration diagram for CallbackAddPointsInCurvesGraphs:
Collaboration graph

Public Member Functions

 CallbackAddPointsInCurvesGraphs (CoordSystem &coordSystem)
 Single constructor. More...
 
CallbackSearchReturn callback (const QString &curveName, const Point &point)
 Callback method. More...
 

Detailed Description

Callback that is used when iterating through a read-only CurvesGraphs to add corresponding points in Document.

Definition at line 17 of file CallbackAddPointsInCurvesGraphs.h.

Constructor & Destructor Documentation

◆ CallbackAddPointsInCurvesGraphs()

CallbackAddPointsInCurvesGraphs::CallbackAddPointsInCurvesGraphs ( CoordSystem coordSystem)

Single constructor.

Definition at line 12 of file CallbackAddPointsInCurvesGraphs.cpp.

12  :
13  m_coordSystem (coordSystem)
14 {
15 }

Member Function Documentation

◆ callback()

CallbackSearchReturn CallbackAddPointsInCurvesGraphs::callback ( const QString &  curveName,
const Point point 
)

Callback method.

Definition at line 17 of file CallbackAddPointsInCurvesGraphs.cpp.

19 {
20  const QString identifier = point.identifier ();
21 
22  if (curveName == AXIS_CURVE_NAME) {
23  m_coordSystem.addPointAxisWithSpecifiedIdentifier (point.posScreen (),
24  point.posGraph (),
25  identifier,
26  point.ordinal (),
27  point.isXOnly ());
28  } else {
29  m_coordSystem.addPointGraphWithSpecifiedIdentifier (curveName,
30  point.posScreen (),
31  identifier,
32  point.ordinal ());
33  }
34 
36 }
bool isXOnly() const
In DOCUMENT_AXES_POINTS_REQUIRED_4 modes, this is true/false if y/x coordinate is undefined.
Definition: Point.cpp:286
QPointF posScreen() const
Accessor for screen position.
Definition: Point.cpp:404
double ordinal(ApplyHasCheck applyHasCheck=KEEP_HAS_CHECK) const
Get method for ordinal. Skip check if copying one instance to another.
Definition: Point.cpp:386
Continue normal execution of the search.
QString identifier() const
Unique identifier for a specific Point.
Definition: Point.cpp:268
virtual void addPointAxisWithSpecifiedIdentifier(const QPointF &posScreen, const QPointF &posGraph, const QString &identifier, double ordinal, bool isXOnly)
Add a single axis point with the specified point identifier.
QPointF posGraph(ApplyHasCheck applyHasCheck=KEEP_HAS_CHECK) const
Accessor for graph position. Skip check if copying one instance to another.
Definition: Point.cpp:395
virtual void addPointGraphWithSpecifiedIdentifier(const QString &curveName, const QPointF &posScreen, const QString &identifier, double ordinal)
Add a single graph point with the specified point identifer. Note that PointStyle is not applied to t...
const QString AXIS_CURVE_NAME

The documentation for this class was generated from the following files: