]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
replacing set_picker(float) method to use a bool instead and the set_pickradius(float...
authorjh777916 <juba.hamma@cea.fr>
Thu, 23 May 2024 10:09:16 +0000 (12:09 +0200)
committerjh777916 <juba.hamma@cea.fr>
Thu, 23 May 2024 12:06:15 +0000 (14:06 +0200)
tools/CurvePlot/src/python/views/CurveView.py
tools/CurvePlot/src/python/views/StemView.py

index e14d4f26a946dde24ca908b659df34c130bd7d42..0c1a5527009bc8f0bba0446dc674edcf58bb9f8c 100644 (file)
@@ -38,8 +38,9 @@ class CurveView(PlotView):
     x_idx, y_idx = m.getXAxisIndex(), m.getYAxisIndex()
     d = self._model.getTable().getData()
     plots = self._mplAxes.plot(d[:, x_idx], d[:, y_idx], label=m._title, alpha = 1.,
-                                        picker=self._PICKER_PRECISION)
+                                        picker=True)
     self._mplArtist = plots[0]
+    self._mplArtist.set_pickradius(self._PICKER_PRECISION)
     self._initialLineWidth = self._mplArtist.get_linewidth()
     self._initialOpacity = self._mplArtist.get_alpha()
     self._initialZOrder = self._mplArtist.get_zorder()
index 995eaa4bf7179a83f4e752efaff44061f9f2e4c8..556baac9094fd96b3d8bc8a7ef98cb60f3bf1263 100644 (file)
@@ -56,7 +56,8 @@ class StemView(PlotView):
 
     # picker for the stemlines
     for lin in self._mplArtist[1]:
-      lin.set_picker(self._PICKER_PRECISION)
+      lin.set_picker(True)
+      lin.set_pickradius(self._PICKER_PRECISION)
   
   def update(self):
     Logger.Debug("StemView::udpate")