widget_graphsVisual
¶
Module Contents¶
Classes¶
-
class
Widget_graphsVisualLite
(theGraphs, **kwargs)¶ Bases:
PyQt5.QtWidgets.QWidget
Widget element to draw a graph. The traces and graphs to draw are defined in
Graphs
taken as argument. This widget is linked to the excellent third-party library pyqtgraph, under MIT license-
signal_must_update
¶
-
signal_graph_changed
¶
-
set_graph_disposition
(indexGraph, row=1, col=1, rowspan=1, colspan=1)¶ Change the graphs disposition.
Parameters: - indexGraph – index of the graph to change
- row – row where to place the graph
- col – column where to place the graph
- rowspan – number of rows across which the graph spans
- colspan – number of columns across which the graph spans
Returns:
-
__create_graph
(idGraph)¶
-
__check_graphs
()¶
-
on_click
(plotDataItem, clicked_points)¶
-
update_graphs
(singleUpdate=True)¶ This method is used to update the graph. This is fast but NOT safe (especially when working with threads). To limit the risks, please use self.signal_must_update.emit() instead.
Parameters: singleUpdate – if set to False, the graph will periodically refres each self.refreshtime
-
fast_update
()¶ Use this method to update the graph in a fast way. NOT THREAD SAFE.
-
select_folder_and_export
()¶
-
exportGraphs
(filename)¶ Export the graphs
-
export_txt
(filename_txt)¶
-
export_svg
(filename)¶
-
export_tikz
(foldername_tikz)¶
-
link_axes
()¶
-
get_graph
(idGraph) → optimeed.visualize.graphs.graphVisual.GraphVisual¶ Get corresponding
GraphVisual
of the graph idGraph
-
get_trace
(idGraph, idTrace) → optimeed.visualize.graphs.traceVisual.TraceVisual¶ Get corresponding Tracevisual
-
keyPressEvent
(event)¶ What happens if a key is pressed. R: reset the axes to their default value
-
delete_graph
(idGraph)¶ Delete the graph idGraph
-
delete
()¶
-
get_all_graphsVisual
()¶ Return a dictionary {idGraph:
GraphVisual
}.
Get the QGraphicsLayout where it’s possible to add buttons, etc.
-
set_actionOnClick
(theActionOnClick)¶ Action to perform when the graph is clicked
Parameters: theActionOnClick – on_graph_click_interface
Returns:
-
set_title
(idGraph, titleName, **kwargs)¶ Set title of the graph
Parameters: - idGraph – id of the graph
- titleName – title to set
-
-
class
Widget_graphsVisual
(*args, **kwargs)¶ Bases:
Widget_graphsVisualLite
Create a gui for pyqtgraph with trace selection options, export and action on clic choices
-
refreshTraceList
()¶ Refresh all the traces
-
set_actions_on_click
(actions)¶
-