Skip to content
Snippets Groups Projects
Commit c7881399 authored by Kien Le's avatar Kien Le
Browse files

Remove ruler texts in all plot on ESC pressed

parent 07881151
No related branches found
No related tags found
No related merge requests found
Pipeline #2482 passed with stage
in 2 minutes and 37 seconds
This commit is part of merge request !96. Comments created here will be created in the context of that merge request.
......@@ -471,12 +471,17 @@ class PlottingWidget(QtWidgets.QScrollArea):
:param event: QKeyEvent - event to know what key is pressed
"""
if event.key() == QtCore.Qt.Key_Escape:
try:
self.ruler_text.remove()
self.ruler_text = None
except AttributeError:
pass
for w in self.peer_plotting_widgets:
w.set_rulers_invisible()
w.zoom_marker1_shown = False
try:
self.ruler_text.remove()
self.ruler_text = None
w.ruler_text.remove()
w.ruler_text = None
except AttributeError:
pass
w.draw()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment