File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -321,14 +321,9 @@ def update_curve_data(self, obj):
321321 sectx , secty = self .get_cross_section (obj )
322322 if secty .size == 0 or np .all (np .isnan (secty )):
323323 sectx , secty = np .array ([]), np .array ([])
324- elif self .param .curvestyle != "Steps" :
325- # Center the symbols at the middle of pixels
326- # Bugfix, we deactivate warnings only for numpy method call.
327- # (V1.0.10 => V1.0.11)
328- # Deactivate following warnings after 20210218 mail
329- # warnings.filterwarnings('ignore')
324+ elif self .param .curvestyle != "Steps" and sectx .size > 1 :
325+ # Center the symbols at the middle of pixels:
330326 sectx [:- 1 ] += np .mean (np .diff (sectx ) / 2 )
331- # warnings.filterwarnings('default')
332327 if self .orientation () == QC .Qt .Orientation .Vertical :
333328 self .process_curve_data (secty , sectx )
334329 else :
You can’t perform that action at this time.
0 commit comments