src/eric7/Documentation/Source/eric7.MicroPython.MicroPythonGraphWidget.html

branch
eric7
changeset 10479
856476537696
parent 9209
b99e7fd55fd3
equal deleted inserted replaced
10478:de9106c55c3d 10479:856476537696
5 <link rel="stylesheet" href="styles.css"> 5 <link rel="stylesheet" href="styles.css">
6 </head> 6 </head>
7 <body> 7 <body>
8 <a NAME="top" ID="top"></a> 8 <a NAME="top" ID="top"></a>
9 <h1>eric7.MicroPython.MicroPythonGraphWidget</h1> 9 <h1>eric7.MicroPython.MicroPythonGraphWidget</h1>
10
11 <p> 10 <p>
12 Module implementing the MicroPython graph widget. 11 Module implementing the MicroPython graph widget.
13 </p> 12 </p>
13
14 <h3>Global Attributes</h3> 14 <h3>Global Attributes</h3>
15 15 <table>
16 <table> 16 <tr><td>None</td></tr>
17 <tr><td>None</td></tr> 17 </table>
18 </table> 18
19 <h3>Classes</h3> 19 <h3>Classes</h3>
20 20 <table>
21 <table>
22
23 <tr> 21 <tr>
24 <td><a href="#MicroPythonGraphWidget">MicroPythonGraphWidget</a></td> 22 <td><a href="#MicroPythonGraphWidget">MicroPythonGraphWidget</a></td>
25 <td>Class implementing the MicroPython graph widget.</td> 23 <td>Class implementing the MicroPython graph widget.</td>
26 </tr> 24 </tr>
27 </table> 25 </table>
26
28 <h3>Functions</h3> 27 <h3>Functions</h3>
29 28 <table>
30 <table> 29 <tr><td>None</td></tr>
31 <tr><td>None</td></tr> 30 </table>
32 </table> 31
33 <hr /> 32 <hr />
34 <hr /> 33 <hr />
35 <a NAME="MicroPythonGraphWidget" ID="MicroPythonGraphWidget"></a> 34 <a NAME="MicroPythonGraphWidget" ID="MicroPythonGraphWidget"></a>
36 <h2>MicroPythonGraphWidget</h2> 35 <h2>MicroPythonGraphWidget</h2>
37
38 <p> 36 <p>
39 Class implementing the MicroPython graph widget. 37 Class implementing the MicroPython graph widget.
40 </p> 38 </p>
39
41 <h3>Signals</h3> 40 <h3>Signals</h3>
42 <dl> 41 <dl>
43 42
44 <dt>dataFlood</dt> 43 <dt>dataFlood</dt>
45 <dd> 44 <dd>
47 </dd> 46 </dd>
48 </dl> 47 </dl>
49 <h3>Derived from</h3> 48 <h3>Derived from</h3>
50 QWidget 49 QWidget
51 <h3>Class Attributes</h3> 50 <h3>Class Attributes</h3>
52 51 <table>
53 <table> 52 <tr><td>None</td></tr>
54 <tr><td>None</td></tr> 53 </table>
55 </table> 54
56 <h3>Class Methods</h3> 55 <h3>Class Methods</h3>
57 56 <table>
58 <table> 57 <tr><td>None</td></tr>
59 <tr><td>None</td></tr> 58 </table>
60 </table> 59
61 <h3>Methods</h3> 60 <h3>Methods</h3>
62 61 <table>
63 <table>
64
65 <tr> 62 <tr>
66 <td><a href="#MicroPythonGraphWidget.__init__">MicroPythonGraphWidget</a></td> 63 <td><a href="#MicroPythonGraphWidget.__init__">MicroPythonGraphWidget</a></td>
67 <td>Constructor</td> 64 <td>Constructor</td>
68 </tr> 65 </tr>
69 <tr> 66 <tr>
97 <tr> 94 <tr>
98 <td><a href="#MicroPythonGraphWidget.saveData">saveData</a></td> 95 <td><a href="#MicroPythonGraphWidget.saveData">saveData</a></td>
99 <td>Public method to save the dialog's raw data.</td> 96 <td>Public method to save the dialog's raw data.</td>
100 </tr> 97 </tr>
101 </table> 98 </table>
99
102 <h3>Static Methods</h3> 100 <h3>Static Methods</h3>
103 101 <table>
104 <table> 102 <tr><td>None</td></tr>
105 <tr><td>None</td></tr> 103 </table>
106 </table> 104
107 105
108 <a NAME="MicroPythonGraphWidget.__init__" ID="MicroPythonGraphWidget.__init__"></a> 106 <a NAME="MicroPythonGraphWidget.__init__" ID="MicroPythonGraphWidget.__init__"></a>
109 <h4>MicroPythonGraphWidget (Constructor)</h4> 107 <h4>MicroPythonGraphWidget (Constructor)</h4>
110 <b>MicroPythonGraphWidget</b>(<i>parent=None</i>) 108 <b>MicroPythonGraphWidget</b>(<i>parent=None</i>)
111
112 <p> 109 <p>
113 Constructor 110 Constructor
114 </p> 111 </p>
112
115 <dl> 113 <dl>
116 114
117 <dt><i>parent</i> (QWidget)</dt> 115 <dt><i>parent</i> (QWidget)</dt>
118 <dd> 116 <dd>
119 reference to the parent widget 117 reference to the parent widget
120 </dd> 118 </dd>
121 </dl> 119 </dl>
122 <a NAME="MicroPythonGraphWidget.__addData" ID="MicroPythonGraphWidget.__addData"></a> 120 <a NAME="MicroPythonGraphWidget.__addData" ID="MicroPythonGraphWidget.__addData"></a>
123 <h4>MicroPythonGraphWidget.__addData</h4> 121 <h4>MicroPythonGraphWidget.__addData</h4>
124 <b>__addData</b>(<i>values</i>) 122 <b>__addData</b>(<i>values</i>)
125
126 <p> 123 <p>
127 Private method to add a tuple of values to the graph. 124 Private method to add a tuple of values to the graph.
128 </p> 125 </p>
129 <p> 126 <p>
130 It ensures there are the required number of line series, adds the data 127 It ensures there are the required number of line series, adds the data
131 to the line series and updates the range of the chart so the chart 128 to the line series and updates the range of the chart so the chart
132 displays nicely. 129 displays nicely.
133 </p> 130 </p>
131
134 <dl> 132 <dl>
135 133
136 <dt><i>values</i> (tuple of int or float)</dt> 134 <dt><i>values</i> (tuple of int or float)</dt>
137 <dd> 135 <dd>
138 tuple containing the data to be added 136 tuple containing the data to be added
139 </dd> 137 </dd>
140 </dl> 138 </dl>
141 <a NAME="MicroPythonGraphWidget.__handleMaxXChanged" ID="MicroPythonGraphWidget.__handleMaxXChanged"></a> 139 <a NAME="MicroPythonGraphWidget.__handleMaxXChanged" ID="MicroPythonGraphWidget.__handleMaxXChanged"></a>
142 <h4>MicroPythonGraphWidget.__handleMaxXChanged</h4> 140 <h4>MicroPythonGraphWidget.__handleMaxXChanged</h4>
143 <b>__handleMaxXChanged</b>(<i>value</i>) 141 <b>__handleMaxXChanged</b>(<i>value</i>)
144
145 <p> 142 <p>
146 Private slot handling a change of the max. X spin box. 143 Private slot handling a change of the max. X spin box.
147 </p> 144 </p>
145
148 <dl> 146 <dl>
149 147
150 <dt><i>value</i> (int)</dt> 148 <dt><i>value</i> (int)</dt>
151 <dd> 149 <dd>
152 value of the spin box 150 value of the spin box
153 </dd> 151 </dd>
154 </dl> 152 </dl>
155 <a NAME="MicroPythonGraphWidget.hasData" ID="MicroPythonGraphWidget.hasData"></a> 153 <a NAME="MicroPythonGraphWidget.hasData" ID="MicroPythonGraphWidget.hasData"></a>
156 <h4>MicroPythonGraphWidget.hasData</h4> 154 <h4>MicroPythonGraphWidget.hasData</h4>
157 <b>hasData</b>(<i></i>) 155 <b>hasData</b>(<i></i>)
158
159 <p> 156 <p>
160 Public method to check, if the chart contains some valid data. 157 Public method to check, if the chart contains some valid data.
161 </p> 158 </p>
159
162 <dl> 160 <dl>
163 <dt>Return:</dt> 161 <dt>Return:</dt>
164 <dd> 162 <dd>
165 flag indicating valid data 163 flag indicating valid data
166 </dd> 164 </dd>
172 </dd> 170 </dd>
173 </dl> 171 </dl>
174 <a NAME="MicroPythonGraphWidget.isDirty" ID="MicroPythonGraphWidget.isDirty"></a> 172 <a NAME="MicroPythonGraphWidget.isDirty" ID="MicroPythonGraphWidget.isDirty"></a>
175 <h4>MicroPythonGraphWidget.isDirty</h4> 173 <h4>MicroPythonGraphWidget.isDirty</h4>
176 <b>isDirty</b>(<i></i>) 174 <b>isDirty</b>(<i></i>)
177
178 <p> 175 <p>
179 Public method to check, if the chart contains unsaved data. 176 Public method to check, if the chart contains unsaved data.
180 </p> 177 </p>
178
181 <dl> 179 <dl>
182 <dt>Return:</dt> 180 <dt>Return:</dt>
183 <dd> 181 <dd>
184 flag indicating unsaved data 182 flag indicating unsaved data
185 </dd> 183 </dd>
191 </dd> 189 </dd>
192 </dl> 190 </dl>
193 <a NAME="MicroPythonGraphWidget.on_saveButton_clicked" ID="MicroPythonGraphWidget.on_saveButton_clicked"></a> 191 <a NAME="MicroPythonGraphWidget.on_saveButton_clicked" ID="MicroPythonGraphWidget.on_saveButton_clicked"></a>
194 <h4>MicroPythonGraphWidget.on_saveButton_clicked</h4> 192 <h4>MicroPythonGraphWidget.on_saveButton_clicked</h4>
195 <b>on_saveButton_clicked</b>(<i></i>) 193 <b>on_saveButton_clicked</b>(<i></i>)
196
197 <p> 194 <p>
198 Private slot to save the raw data to a CSV file. 195 Private slot to save the raw data to a CSV file.
199 </p> 196 </p>
197
200 <a NAME="MicroPythonGraphWidget.preferencesChanged" ID="MicroPythonGraphWidget.preferencesChanged"></a> 198 <a NAME="MicroPythonGraphWidget.preferencesChanged" ID="MicroPythonGraphWidget.preferencesChanged"></a>
201 <h4>MicroPythonGraphWidget.preferencesChanged</h4> 199 <h4>MicroPythonGraphWidget.preferencesChanged</h4>
202 <b>preferencesChanged</b>(<i></i>) 200 <b>preferencesChanged</b>(<i></i>)
203
204 <p> 201 <p>
205 Public slot to apply changed preferences. 202 Public slot to apply changed preferences.
206 </p> 203 </p>
204
207 <a NAME="MicroPythonGraphWidget.processData" ID="MicroPythonGraphWidget.processData"></a> 205 <a NAME="MicroPythonGraphWidget.processData" ID="MicroPythonGraphWidget.processData"></a>
208 <h4>MicroPythonGraphWidget.processData</h4> 206 <h4>MicroPythonGraphWidget.processData</h4>
209 <b>processData</b>(<i>data</i>) 207 <b>processData</b>(<i>data</i>)
210
211 <p> 208 <p>
212 Public slot to process the raw data. 209 Public slot to process the raw data.
213 </p> 210 </p>
214 <p> 211 <p>
215 It takes raw bytes, checks the data for a valid tuple of ints or 212 It takes raw bytes, checks the data for a valid tuple of ints or
216 floats and adds the data to the graph. If the the length of the bytes 213 floats and adds the data to the graph. If the the length of the bytes
217 data is greater than 1024 then a dataFlood signal is emitted to ensure 214 data is greater than 1024 then a dataFlood signal is emitted to ensure
218 eric can take action to remain responsive. 215 eric can take action to remain responsive.
219 </p> 216 </p>
217
220 <dl> 218 <dl>
221 219
222 <dt><i>data</i> (bytes)</dt> 220 <dt><i>data</i> (bytes)</dt>
223 <dd> 221 <dd>
224 raw data received from the connected device via the main 222 raw data received from the connected device via the main
226 </dd> 224 </dd>
227 </dl> 225 </dl>
228 <a NAME="MicroPythonGraphWidget.saveData" ID="MicroPythonGraphWidget.saveData"></a> 226 <a NAME="MicroPythonGraphWidget.saveData" ID="MicroPythonGraphWidget.saveData"></a>
229 <h4>MicroPythonGraphWidget.saveData</h4> 227 <h4>MicroPythonGraphWidget.saveData</h4>
230 <b>saveData</b>(<i></i>) 228 <b>saveData</b>(<i></i>)
231
232 <p> 229 <p>
233 Public method to save the dialog's raw data. 230 Public method to save the dialog's raw data.
234 </p> 231 </p>
232
235 <dl> 233 <dl>
236 <dt>Return:</dt> 234 <dt>Return:</dt>
237 <dd> 235 <dd>
238 flag indicating success 236 flag indicating success
239 </dd> 237 </dd>

eric ide

mercurial