summaryrefslogtreecommitdiff
path: root/src/main/python/shapes
diff options
context:
space:
mode:
authorsumit2020-05-30 16:58:46 +0530
committersumit2020-05-30 16:58:46 +0530
commit5e0015b53c72d59e34376f6a48597c1420f7dedf (patch)
treee1bab6dc59271ea7b1fd10a127fe10656ea544f0 /src/main/python/shapes
parent237a19e87df926c2d66be49a1aa5c26edaf9add4 (diff)
downloadChemical-PFD-5e0015b53c72d59e34376f6a48597c1420f7dedf.tar.gz
Chemical-PFD-5e0015b53c72d59e34376f6a48597c1420f7dedf.tar.bz2
Chemical-PFD-5e0015b53c72d59e34376f6a48597c1420f7dedf.zip
remove extra point of line
Diffstat (limited to 'src/main/python/shapes')
-rw-r--r--src/main/python/shapes/line.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/python/shapes/line.py b/src/main/python/shapes/line.py
index fa10936..8bba5be 100644
--- a/src/main/python/shapes/line.py
+++ b/src/main/python/shapes/line.py
@@ -2,6 +2,7 @@ from PyQt5.QtGui import QPen, QPainterPath, QBrush, QPainterPathStroker, QPainte
from PyQt5.QtWidgets import QGraphicsItem, QGraphicsPathItem
from PyQt5.QtCore import Qt, QPointF, QRectF
+
class Grabber(QGraphicsPathItem):
"""
Extends QGraphicsPathItem to create grabber for line for moving a particular segment
@@ -373,7 +374,7 @@ class Line(QGraphicsPathItem):
self.points = [start, ns, QPointF(ns.x() - swidth - offset, ns.y()),
QPointF(ns.x() - swidth - offset, pe.y()), end]
elif end.y() - eheight < start.y() - offset < end.y() + eheight:
- self.points = [start, ns, QPointF(start.x(), end.y() - eheight),
+ self.points = [start, QPointF(start.x(), end.y() - eheight),
QPointF(pe.x(), end.y() - eheight), pe, end]
elif self.startGripItem.m_location in ["bottom"]: