'Set the anchor\'s curve path as a :class:`QPainterPath`.'

def setAnchorPath(self, path):

    self.prepareGeometryChange()
    self.__boundingRect = None
    self.__anchorPath = path
    stroke_path = QPainterPathStroker()
    stroke_path.setCapStyle(Qt.RoundCap)
    stroke_path.setWidth(12)
    self.__shape = stroke_path.createStroke(path)
    stroke_path.setWidth(3)
    self.__fullStroke = stroke_path.createStroke(path)
    stroke_path.setDashPattern(Qt.DotLine)
    self.__dottedStroke = stroke_path.createStroke(path)
    if self.anchored:
        self.setPath(self.__fullStroke)
        self.setBrush(self.connectedBrush)
    else:
        self.setPath(self.__dottedStroke)
        self.setBrush(self.normalBrush)
