Hello, I am looking for create an IHM able to plotting many curves on each others (so far no problem) in order to give good/clear informations to users, i would like to add legend/items in a viewbox placed on the right of the plot (here again, no problem).
I am blocked concerning the position setting of the item in the viewbox... Indeed, I would like to fix the position of the legend in the viewbox here is two ways to create legend/items... but both present the an issue: self.column_legend = self.graph.addViewBox(border=QPen(QColor(255, 0, 0), 1, Qt.SolidLine), enableMouse=False) self.column_legend.setMaximumWidth(80) self.legend = pg.LegendItem(size=(10, 20), offset=(1,1)) self.legend.setParentItem(self.colonne_legende) self.column_legend.setMouseEnabled(x=False, y=False) here, i created wiewbox, legenditem... but despite the setting of enableMouse to False, items are movable! self.column_legend = self.graph.addViewBox(border=QPen(QColor(255, 0, 0), 1, Qt.SolidLine), enableMouse=False) self.column_legend.setMaximumWidth(80) self.legend = pg.LegendItem(size=(10, 20), offset=None) self.column_legend.addItem(self.legend) self.column_legend.setMouseEnabled(x=False, y=False) here, items are not movable!!! but offset need to set "None"... so the position is bad... is there a solution to do what i am looking for? thanks -- You received this message because you are subscribed to the Google Groups "pyqtgraph" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pyqtgraph/0401ff92-c8c4-4379-af86-68b255136133%40googlegroups.com.
