Method |
Description |
|
AddPlot ( QColor color ) : void |
Add a new line to the graph plotter, with the specified color. Note that the order you add the plots must be the same order that the same data is given in (unless you reorder the plots). name="color" the color to use for this plot |
|
AddSample ( List samples ) : void |
Add data to the graph, and advance the graph by one time period. The data must be given as a list in the same order that the plots were added (or consequently reordered). name="samples" a list with the new value for each plot |
|
Dispose ( ) : void |
|
|
GetSnapshotImage ( uint width, uint height ) : QPixmap |
Render the graph to the specified width and height, and return it as an image. This is useful, for example, if you draw a small version of the graph, but then want to show a large version in a tooltip etc name="width" the width of the snapshot name="height" the height of the snapshot |
|
LastValue ( uint i ) : double |
Return the last value that we have for plot i. Returns 0 if not known. name="i" the plot we like to have the last value from |
|
LastValueAsString ( uint i ) : string |
Return a translated string like: "34 %" or "100 KB" for plot i name="i" the plot we like to have the value as string from |
|
PlotColors ( ) : List |
Return the list of plot colors, in the order that the plots were added (or later reordered). |
|
RemovePlot ( uint pos ) : void |
Removes the plot at the specified index. name="pos" the index of the plot to be removed |
|
ReorderPlots ( List newOrder ) : void |
Reorder the plots into the order given. For example: KSignalPlotter s = KSignalPlotter(parent); s.AddPlot(Qt.Blue); s.AddPlot(Qt.Green); QList neworder; neworder << 1 << 0; reorderPlots(newOrder); //Now the order is Green then Blue name="newOrder" a list with the new position of each plot |
|
SetVerticalRange ( double min, double max ) : void |
Change the minimum and maximum values drawn on the graph. Note that these values are sanitised. For example, if you set the minimum as 3, and the maximum as 97, then the graph would be drawn between 0 and 100. The algorithm to determine this "nice range" attempts to minimize the number of non-zero digits. Use setAutoRange instead to determine the range automatically from the data. name="min" the minimum value to use for the vertical axis name="max" the maximum value to use for the vertical axis |
|
SignalPlotter ( ) : System |
|
|
SignalPlotter ( IQGraphicsItem parent ) : System |
|
|
VerticalMaxValue ( ) : double |
Get the max value of the vertical axis. @see changeRange |
|
VerticalMinValue ( ) : double |
Get the min value of the vertical axis. @see changeRange |
|