Skip to content

Commit 28709e8

Browse files
committed
Fix legend still being visible after removed
Fix #96
1 parent 37e5797 commit 28709e8

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

qwt/plot.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1553,6 +1553,7 @@ def insertLegend(self, legend, pos=None, ratio=-1):
15531553
self.__data.layout.setLegendPosition(pos, ratio)
15541554
if legend != self.__data.legend:
15551555
if self.__data.legend and self.__data.legend.parent() is self:
1556+
self.__data.legend.setParent(None)
15561557
del self.__data.legend
15571558
self.__data.legend = legend
15581559
if self.__data.legend:

0 commit comments

Comments
 (0)