]>
Commit | Line | Data |
---|---|---|
a796957a RR |
1 | % |
2 | % automatically generated by HelpGen from | |
3 | % plot.h at 11/Feb/00 18:00:57 | |
4 | % | |
5 | ||
6 | \section{\class{wxPlotCurve}}\label{wxplotcurve} | |
7 | ||
8 | The wxPlotCurve class represents a curve displayed in a \helpref{wxPlotWindow}{wxplotwindow}. It | |
9 | is a virtual curve, i.e. is acts only as an interface, leaving it to the programmer to care for | |
10 | how the values pairs are matched. wxPlotWindow and wxPlotCurve are designed to display large | |
11 | amounts of data, i.e. most typically data measured by some sort of machine. | |
12 | ||
13 | This class is abstract, i.e. you have to derive your own class and implement the pure | |
14 | virtual functions (\helpref{GetStartX()}{wxplotcurvegetstartx}, \helpref{GetEndX()}{wxplotcurvegetendx} | |
15 | and \helpref{GetY()}{wxplotcurvegety}). | |
16 | ||
17 | \wxheading{Derived from} | |
18 | ||
19 | \helpref{wxObject}{wxobject} | |
20 | ||
21 | \latexignore{\rtfignore{\wxheading{Members}}} | |
22 | ||
23 | \membersection{wxPlotCurve::wxPlotCurve}\label{wxplotcurvewxplotcurve} | |
24 | ||
25 | \func{}{wxPlotCurve}{\param{int }{offsetY}, \param{double }{startY}, \param{double }{endY}} | |
26 | ||
27 | Constructor assigning start values. See below for interpretation. | |
28 | ||
a796957a RR |
29 | \membersection{wxPlotCurve::GetEndX}\label{wxplotcurvegetendx} |
30 | ||
31 | \func{wxInt32}{GetEndX}{\void} | |
32 | ||
33 | Must be overridden. This function should return the index of the last value | |
34 | of this curve, typically 99 if 100 values have been measured. | |
35 | ||
2fa7c206 JS |
36 | \membersection{wxPlotCurve::GetEndY}\label{wxplotcurvegetendy} |
37 | ||
38 | \func{double}{GetEndY}{\void} | |
39 | ||
40 | See \helpref{SetStartY}{wxplotcurvesetendy}. | |
41 | ||
42 | \membersection{wxPlotCurve::GetOffsetY}\label{wxplotcurvegetoffsety} | |
43 | ||
44 | \func{int}{GetOffsetY}{\void} | |
45 | ||
46 | Returns the vertical offset. | |
a796957a RR |
47 | \membersection{wxPlotCurve::GetY}\label{wxplotcurvegety} |
48 | ||
49 | \func{double}{GetY}{\param{wxInt32 }{x}} | |
50 | ||
51 | Must be overridden. This function will return the actual Y value corresponding | |
52 | to the given X value. The x value is of an integer type because it is considered | |
53 | to be an index in row of measured values. | |
54 | ||
2fa7c206 | 55 | \membersection{wxPlotCurve::GetStartX}\label{wxplotcurvegetstartx} |
a796957a | 56 | |
2fa7c206 | 57 | \func{wxInt32}{GetStartX}{\void} |
a796957a | 58 | |
2fa7c206 JS |
59 | Must be overridden. This function should return the index of the first value |
60 | of this curve, typically zero. | |
a796957a RR |
61 | |
62 | \membersection{wxPlotCurve::GetStartY}\label{wxplotcurvegetstarty} | |
63 | ||
64 | \func{double}{GetStartY}{\void} | |
65 | ||
66 | See \helpref{SetStartY}{wxplotcurvesetstarty}. | |
67 | ||
68 | \membersection{wxPlotCurve::SetEndY}\label{wxplotcurvesetendy} | |
69 | ||
70 | \func{void}{SetEndY}{\param{double }{endY}} | |
71 | ||
72 | The value returned by this function tells the plot window what the highest values | |
2fa7c206 | 73 | in the curve will be so that a suitable scale can be found for the display. If |
a796957a | 74 | the Y values in this curve are in the range of -1.5 to 0.5, this function should |
2fa7c206 | 75 | return 0.5 or maybe 1.0 for nicer aesthetics. |
a796957a RR |
76 | |
77 | \membersection{wxPlotCurve::SetOffsetY}\label{wxplotcurvesetoffsety} | |
78 | ||
79 | \func{void}{SetOffsetY}{\param{int }{offsetY}} | |
80 | ||
81 | When displaying several curves in one window, it is often useful to assign | |
fa482912 | 82 | different offsets to the curves. You should call \helpref{wxPlotWindow::Move}{wxplotwindowmove} |
a796957a RR |
83 | to set this value after you have added the curve to the window. |
84 | ||
2fa7c206 | 85 | \membersection{wxPlotCurve::SetStartY}\label{wxplotcurvesetstarty} |
a796957a | 86 | |
2fa7c206 JS |
87 | \func{void}{SetStartY}{\param{double }{startY}} |
88 | ||
89 | The value returned by this function tells the plot window what the lowest values | |
90 | in the curve will be so that a suitable scale can be found for the display. If | |
91 | the Y values in this curve are in the range of -1.5 to 0.5, this function should | |
92 | return -1.5 or maybe -2.0 for nicer aesthetics. | |
a796957a | 93 |