|
Numworks Epsilon
1.4.1
Graphing Calculator Operating System
|
#include <curve_view.h>
Public Types | |
| enum | Axis { Axis::Horizontal = 0, Axis::Vertical = 1 } |
| typedef float(* | EvaluateModelWithParameter) (float t, void *model, void *context) |
Public Member Functions | |
| CurveView (CurveViewRange *curveViewRange=nullptr, CurveViewCursor *curveViewCursor=nullptr, BannerView *bannerView=nullptr, View *cursorView=nullptr, View *okView=nullptr) | |
| virtual void | reload () |
| bool | isMainViewSelected () const |
| void | selectMainView (bool mainViewSelected) |
| void | setCursorView (View *cursorView) |
| void | setBannerView (View *bannerView) |
| void | setOkView (View *okView) |
| float | resolution () const |
Public Member Functions inherited from View | |
| View () | |
| virtual | ~View () |
| View (const View &other)=delete | |
| View (View &&other)=delete | |
| View & | operator= (const View &other)=delete |
| View & | operator= (View &&other)=delete |
| void | resetSuperview () |
| virtual void | drawRect (KDContext *ctx, KDRect rect) const |
| void | setSize (KDSize size) |
| void | setFrame (KDRect frame) |
| KDPoint | pointFromPointInView (View *view, KDPoint point) |
| KDRect | bounds () const |
| View * | subview (int index) |
| virtual KDSize | minimalSizeForOptimalDisplay () const |
Protected Member Functions | |
| void | setCurveViewRange (CurveViewRange *curveViewRange) |
| virtual float | samplingRatio () const |
| float | pixelToFloat (Axis axis, KDCoordinate p) const |
| float | floatToPixel (Axis axis, float f) const |
| void | drawLine (KDContext *ctx, KDRect rect, Axis axis, float coordinate, KDColor color, KDCoordinate thickness=1) const |
| void | drawSegment (KDContext *ctx, KDRect rect, Axis axis, float coordinate, float lowerBound, float upperBound, KDColor color, KDCoordinate thickness=1) const |
| void | drawDot (KDContext *ctx, KDRect rect, float x, float y, KDColor color, bool oversize=false) const |
| void | drawGridLines (KDContext *ctx, KDRect rect, Axis axis, float step, KDColor color) const |
| void | drawGrid (KDContext *ctx, KDRect rect) const |
| void | drawAxes (KDContext *ctx, KDRect rect, Axis axis) const |
| void | drawCurve (KDContext *ctx, KDRect rect, EvaluateModelWithParameter evaluation, void *model, void *context, KDColor color, bool colorUnderCurve=false, float colorLowerBound=0.0f, float colorUpperBound=0.0f, bool continuously=false) const |
| void | drawHistogram (KDContext *ctx, KDRect rect, EvaluateModelWithParameter evaluation, void *model, void *context, float firstBarAbscissa, float barWidth, bool fillBar, KDColor defaultColor, KDColor highlightColor, float highlightLowerBound=INFINITY, float highlightUpperBound=-INFINITY) const |
| void | computeLabels (Axis axis) |
| void | drawLabels (KDContext *ctx, KDRect rect, Axis axis, bool shiftOrigin) const |
Protected Member Functions inherited from View | |
| void | markRectAsDirty (KDRect rect) |
Protected Attributes | |
| View * | m_bannerView |
| CurveViewCursor * | m_curveViewCursor |
Protected Attributes inherited from View | |
| KDRect | m_frame |
Static Protected Attributes | |
| static constexpr KDCoordinate | k_labelMargin = 4 |
| static constexpr KDCoordinate | k_okMargin = 10 |
| static constexpr KDCoordinate | k_labelGraduationLength = 6 |
| static constexpr int | k_maxNumberOfXLabels = CurveViewRange::k_maxNumberOfXGridUnits |
| static constexpr int | k_maxNumberOfYLabels = CurveViewRange::k_maxNumberOfYGridUnits |
| static constexpr int | k_externRectMargin = 2 |
Definition at line 13 of file curve_view.h.
| typedef float(* Shared::CurveView::EvaluateModelWithParameter) (float t, void *model, void *context) |
Definition at line 15 of file curve_view.h.
|
strong |
| Enumerator | |
|---|---|
| Horizontal | |
| Vertical | |
Definition at line 16 of file curve_view.h.
| Shared::CurveView::CurveView | ( | CurveViewRange * | curveViewRange = nullptr, |
| CurveViewCursor * | curveViewCursor = nullptr, |
||
| BannerView * | bannerView = nullptr, |
||
| View * | cursorView = nullptr, |
||
| View * | okView = nullptr |
||
| ) |
Definition at line 12 of file curve_view.cpp.
|
protected |
Definition at line 130 of file curve_view.cpp.
Definition at line 282 of file curve_view.cpp.
|
protected |
Definition at line 339 of file curve_view.cpp.
|
protected |
Definition at line 241 of file curve_view.cpp.
Definition at line 277 of file curve_view.cpp.
|
protected |
Definition at line 256 of file curve_view.cpp.
|
protected |
Definition at line 382 of file curve_view.cpp.
|
protected |
Definition at line 146 of file curve_view.cpp.
|
protected |
Definition at line 175 of file curve_view.cpp.
|
protected |
Definition at line 196 of file curve_view.cpp.
|
protected |
Definition at line 115 of file curve_view.cpp.
| bool Shared::CurveView::isMainViewSelected | ( | ) | const |
Definition at line 42 of file curve_view.cpp.
|
protected |
Definition at line 110 of file curve_view.cpp.
|
virtual |
Reimplemented in Statistics::BoxView, Probability::LawCurveView, Graph::GraphView, and Statistics::HistogramView.
Definition at line 25 of file curve_view.cpp.
| float Shared::CurveView::resolution | ( | ) | const |
Definition at line 83 of file curve_view.cpp.
|
protectedvirtual |
Definition at line 87 of file curve_view.cpp.
| void Shared::CurveView::selectMainView | ( | bool | mainViewSelected | ) |
Definition at line 46 of file curve_view.cpp.
| void Shared::CurveView::setBannerView | ( | View * | bannerView | ) |
Definition at line 71 of file curve_view.cpp.
| void Shared::CurveView::setCursorView | ( | View * | cursorView | ) |
Definition at line 64 of file curve_view.cpp.
|
protected |
Definition at line 53 of file curve_view.cpp.
| void Shared::CurveView::setOkView | ( | View * | okView | ) |
Definition at line 77 of file curve_view.cpp.
|
staticprotected |
Definition at line 39 of file curve_view.h.
|
staticprotected |
Definition at line 36 of file curve_view.h.
|
staticprotected |
Definition at line 34 of file curve_view.h.
|
staticprotected |
Definition at line 37 of file curve_view.h.
|
staticprotected |
Definition at line 38 of file curve_view.h.
|
staticprotected |
Definition at line 35 of file curve_view.h.
|
protected |
Definition at line 56 of file curve_view.h.
|
protected |
Definition at line 57 of file curve_view.h.