Engauge Digitizer 2
|
Container for one set of digitized Points. More...
#include <Curve.h>
Public Member Functions | |
Curve (const QString &curveName, const ColorFilterSettings &colorFilterSettings, const CurveStyle &curveStyle) | |
Constructor from scratch. | |
Curve (QDataStream &str) | |
Constructor from serialized binary pre-version 6 file. | |
Curve (QXmlStreamReader &reader) | |
Constructor for use when loading from serialized xml. | |
Curve (const Curve &curve) | |
Copy constructor. Copying a Curve only helps for making a copy, since access to any Points inside must be via functor. | |
Curve & | operator= (const Curve &curve) |
Assignment constructor. | |
void | addPoint (const Point &point) |
Add Point to this Curve. | |
ColorFilterSettings | colorFilterSettings () const |
Return the color filter. | |
QString | curveName () const |
Name of this Curve. | |
CurveStyle | curveStyle () const |
Return the curve style. | |
void | editPointAxis (const QPointF &posGraph, const QString &identifier) |
Edit the graph coordinates of an axis point. This method does not apply to a graph point. | |
void | editPointGraph (bool isX, bool isY, double x, double y, const QStringList &identifiers, const Transformation &transformation) |
Edit the graph coordinates of one or more graph points. This method does not apply to an axis point. | |
void | exportToClipboard (const QHash< QString, bool > &selectedHash, const Transformation &transformation, QTextStream &strCsv, QTextStream &strHtml, CurvesGraphs &curvesGraphs) const |
Export points in this Curve found in the specified point list. | |
bool | isXOnly (const QString &pointIdentifier) const |
Determine if specified point has just x coordinate. Otherwise has just y coordinate, or both x and y coordinates. | |
void | iterateThroughCurvePoints (const Functor2wRet< const QString &, const Point &, CallbackSearchReturn > &ftorWithCallback) const |
Apply functor to Points on Curve. | |
void | iterateThroughCurveSegments (const Functor2wRet< const Point &, const Point &, CallbackSearchReturn > &ftorWithCallback) const |
Apply functor to successive Points, as line segments, on Curve. This could be a bit slow. | |
void | movePoint (const QString &pointIdentifier, const QPointF &deltaScreen) |
Translate the position of a point by the specified distance vector. | |
int | numPoints () const |
Number of points. | |
const Points | points () const |
Return a shallow copy of the Points. | |
QPointF | positionGraph (const QString &pointIdentifier) const |
Return the position, in graph coordinates, of the specified Point. | |
QPointF | positionScreen (const QString &pointIdentifier) const |
Return the position, in screen coordinates, of the specified Point. | |
void | printStream (QString indentation, QTextStream &str) const |
Debugging method that supports print method of this class and printStream method of some other class(es) | |
void | removePoint (const QString &identifier) |
Perform the opposite of addPointAtEnd. | |
void | saveXml (QXmlStreamWriter &writer) const |
Serialize curve. | |
void | setColorFilterSettings (const ColorFilterSettings &colorFilterSettings) |
Set color filter. | |
void | setCurveName (const QString &curveName) |
Change the curve name. | |
void | setCurveStyle (const CurveStyle &curveStyle) |
Set curve style. | |
void | updatePointOrdinals (const Transformation &transformation) |
See CurveGraphs::updatePointOrdinals. | |
Curve::Curve | ( | const QString & | curveName, |
const ColorFilterSettings & | colorFilterSettings, | ||
const CurveStyle & | curveStyle ) |
Constructor from scratch.
Definition at line 36 of file Curve.cpp.
Curve::Curve | ( | QDataStream & | str | ) |
Constructor from serialized binary pre-version 6 file.
Definition at line 53 of file Curve.cpp.
Curve::Curve | ( | QXmlStreamReader & | reader | ) |
Copy constructor. Copying a Curve only helps for making a copy, since access to any Points inside must be via functor.
ColorFilterSettings Curve::colorFilterSettings | ( | ) | const |
QString Curve::curveName | ( | ) | const |
CurveStyle Curve::curveStyle | ( | ) | const |
Edit the graph coordinates of an axis point. This method does not apply to a graph point.
Definition at line 154 of file Curve.cpp.
void Curve::editPointGraph | ( | bool | isX, |
bool | isY, | ||
double | x, | ||
double | y, | ||
const QStringList & | identifiers, | ||
const Transformation & | transformation ) |
Edit the graph coordinates of one or more graph points. This method does not apply to an axis point.
Definition at line 171 of file Curve.cpp.
void Curve::exportToClipboard | ( | const QHash< QString, bool > & | selectedHash, |
const Transformation & | transformation, | ||
QTextStream & | strCsv, | ||
QTextStream & | strHtml, | ||
CurvesGraphs & | curvesGraphs ) const |
Export points in this Curve found in the specified point list.
Definition at line 220 of file Curve.cpp.
Determine if specified point has just x coordinate. Otherwise has just y coordinate, or both x and y coordinates.
Definition at line 285 of file Curve.cpp.
void Curve::iterateThroughCurvePoints | ( | const Functor2wRet< const QString &, const Point &, CallbackSearchReturn > & | ftorWithCallback | ) | const |
Apply functor to Points on Curve.
Definition at line 301 of file Curve.cpp.
void Curve::iterateThroughCurveSegments | ( | const Functor2wRet< const Point &, const Point &, CallbackSearchReturn > & | ftorWithCallback | ) | const |
Apply functor to successive Points, as line segments, on Curve. This could be a bit slow.
Definition at line 316 of file Curve.cpp.
Translate the position of a point by the specified distance vector.
int Curve::numPoints | ( | ) | const |
Return the position, in graph coordinates, of the specified Point.
Definition at line 456 of file Curve.cpp.
Return the position, in screen coordinates, of the specified Point.
void Curve::printStream | ( | QString | indentation, |
QTextStream & | str ) const |
Debugging method that supports print method of this class and printStream method of some other class(es)
Definition at line 490 of file Curve.cpp.
Perform the opposite of addPointAtEnd.
void Curve::saveXml | ( | QXmlStreamWriter & | writer | ) | const |
Serialize curve.
Definition at line 523 of file Curve.cpp.
void Curve::setColorFilterSettings | ( | const ColorFilterSettings & | colorFilterSettings | ) |
Set color filter.
Change the curve name.
Definition at line 551 of file Curve.cpp.
void Curve::setCurveStyle | ( | const CurveStyle & | curveStyle | ) |
void Curve::updatePointOrdinals | ( | const Transformation & | transformation | ) |
See CurveGraphs::updatePointOrdinals.
Same algorithm as GraphicsLinesForCurve::updatePointOrdinalsAfterDrag, although graph coordinates of points have been updated before this is called so the graph coordinates are not updated by this method
Definition at line 568 of file Curve.cpp.