traceVisual
¶
Module Contents¶
-
class
TraceVisual
(theColor, theData, theWGPlot, highlight_last)¶ Bases:
PyQt5.QtCore.QObject
Defines a trace in a graph.
-
class
_ModifiedPaintElem
¶ Hidden class to manage brushes or pens
-
add_modified_paintElem
(self, index, newPaintElem)¶
-
modify_paintElems
(self, paintElemsIn_List)¶ Apply transformation to paintElemsIn_List
Parameters: paintElemsIn_List – list of brushes or pens to modify Returns: False if nothing has been modified, True is something has been modified
-
reset_paintElem
(self, index)¶ Remove transformation of point index
-
reset
(self)¶
-
-
signal_must_update
¶
-
hide_points
(self)¶ Hide all the points
-
get_color
(self)¶ Get colour of the trace, return tuple (r,g,b)
-
set_color
(self, color)¶ Set colour of the trace, argument as tuple (r,g,b)
-
get_base_symbol_brush
(self)¶ Get symbol brush configured for this trace, return
pg.QBrush
-
get_base_pen
(self)¶ Get pen configured for this trace, return
pg.QPen
-
get_base_symbol_pen
(self)¶ Get symbol pen configured for this trace, return
pg.QPen
-
get_base_symbol
(self)¶ Get base symbol configured for this trace, return str of the symbol (e.g. ‘o’)
-
get_symbol
(self, size)¶ Get actual symbols for the trace. If the symbols have been modified: return a list which maps each points to a symbol. Otherwise: return :meth:TraceVisual.get_base_symbol()
-
updateTrace
(self)¶ Forces the trace to refresh.
-
get_length
(self)¶ Return number of data to plot
-
hide
(self)¶ Hides the trace
-
show
(self)¶ Shows the trace
-
toggle
(self, boolean)¶ Toggle the trace (hide/show)
-
get_data
(self)¶ Get data to plot
Data
-
get_brushes
(self, size)¶ Get actual brushes for the trace (=symbol filling). return a list which maps each points to a symbol brush
-
set_brush
(self, indexPoint, newbrush, update=True)¶ Set the symbol brush for a specific point:
Parameters: - indexPoint – Index of the point (in the graph) to modify
- newbrush – either QBrush or tuple (r, g, b) of the new brush
- update – if True, update the trace afterwards. This is slow operation.
-
set_symbol
(self, indexPoint, newSymbol, update=True)¶ Set the symbol shape for a specific point:
Parameters: - indexPoint – Index of the point (in the graph) to modify
- newSymbol – string of the new symbol (e.g.: ‘o’)
- update – if True, update the trace afterwards. This is slow operation.
-
set_brushes
(self, list_indexPoint, list_newbrush)¶ Same as
set_brush()
but by taking a list as input
-
reset_brush
(self, indexPoint, update=True)¶ Reset the brush of the point indexpoint
-
reset_all_brushes
(self)¶ Reset all the brushes
-
reset_symbol
(self, indexPoint, update=True)¶ Reset the symbol shape of the point indexpoint
-
get_symbolPens
(self, size)¶ Get actual symbol pens for the trace (=symbol outline). return a list which maps each points to a symbol pen
-
set_symbolPen
(self, indexPoint, newPen, update=True)¶ Set the symbol shape for a specific point:
Parameters: - indexPoint – Index of the point (in the graph) to modify
- newPen – QPen item or tuple of the color (r,g,b)
- update – if True, update the trace afterwards. This is slow operation.
-
set_symbolPens
(self, list_indexPoint, list_newpens)¶ Same as
set_symbolPen()
but by taking a list as input
-
reset_symbolPen
(self, indexPoint)¶ Reset the symbol pen of the point indexpoint
-
reset_all_symbolPens
(self)¶ Reset all the symbol pens
-
class