While making subclasses for TimePlot and WaveformPlot for my application, I noticed this little inconvenience with non-TimePlot plots. I think it's a good thing to have a factory method such as this in every plot! :slightly_smiling_face:
I kept it as close as possible to the one in TimePlot, so as to not change more stuff than needed, though I figured it may be even better to pass a generic *args, **kwargs to the createCurveItem functions, so as to not constrain the signature of the CurveItem custom implementations. What do you think?
While making subclasses for TimePlot and WaveformPlot for my application, I noticed this little inconvenience with non-TimePlot plots. I think it's a good thing to have a factory method such as this in every plot! :slightly_smiling_face:
I kept it as close as possible to the one in TimePlot, so as to not change more stuff than needed, though I figured it may be even better to pass a generic
*args, **kwargs
to thecreateCurveItem
functions, so as to not constrain the signature of the CurveItem custom implementations. What do you think?