'Set the arrow base line (a `QLineF` in object coordinates).'

def setLine(self, line):

    if (self.__line != line):
        self.__line = line
        geom = self.geometry().translated((- self.pos()))
        if (geom.isNull() and (not line.isNull())):
            geom = QRectF(0, 0, 1, 1)
        arrow_shape = arrow_path_concave(line, self.lineWidth())
        arrow_rect = arrow_shape.boundingRect()
        if (not geom.contains(arrow_rect)):
            geom = geom.united(arrow_rect)
        if self.__autoAdjustGeometry:
            geom = geom.intersected(arrow_rect)
        diff = geom.topLeft()
        line = QLineF((line.p1() - diff), (line.p2() - diff))
        self.__arrowItem.setLine(line)
        self.__line = line
        geom.translate(self.pos())
        self.setGeometry(geom)
