From 7b8519f50ec842cd2ece4058259fc034ea3da0c9 Mon Sep 17 00:00:00 2001 From: Jaewoo Choi Date: Tue, 22 Aug 2017 14:59:40 +0900 Subject: [PATCH] fix a bug to select a small bounding box --- libs/canvas.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libs/canvas.py b/libs/canvas.py index cc681605..bee70368 100644 --- a/libs/canvas.py +++ b/libs/canvas.py @@ -283,14 +283,12 @@ class Canvas(QWidget): if self.selectedVertex(): # A vertex is marked for selection. index, shape = self.hVertex, self.hShape shape.highlightVertex(index, shape.MOVE_VERTEX) + self.selectShape(shape) return for shape in reversed(self.shapes): if self.isVisible(shape) and shape.containsPoint(point): - shape.selected = True - self.selectedShape = shape + self.selectShape(shape) self.calculateOffsets(shape, point) - self.setHiding() - self.selectionChanged.emit(True) return def calculateOffsets(self, shape, point):