Exemple #1
0
 def ellipse(self, x, y, width, height, draw=True, **kwargs):
     '''Draw an ellipse starting from (x,y)'''
     path = self.BezierPath(**kwargs)
     path.ellipse(x, y, width, height, self.ellipsemode)
     if draw:
         path.draw()
     return path
Exemple #2
0
 def oval(self, x, y, width, height, draw=True, **kwargs):
     '''Draw an ellipse starting from (x,y) -  ovals and ellipses are not the same'''
     path = self.BezierPath(**kwargs)
     path.ellipse(x, y, width, height, self.ellipsemode)
     if draw:
         path.draw()
     return path
Exemple #3
0
 def oval(self, x, y, width, height, draw=True, **kwargs):
     '''Draw an ellipse starting from (x,y) -  ovals and ellipses are not the same'''
     path = self.BezierPath(**kwargs)
     path.ellipse(x, y, width, height)
     if draw:
         path.draw()
     return path
Exemple #4
0
 def ellipse(self, x, y, width, height, draw=True, **kwargs):
     '''Draw an ellipse starting from (x,y)'''
     path = self.BezierPath(**kwargs)
     path.ellipse(x,y,width,height)
     if draw:
         path.draw()
     return path
Exemple #5
0
    def ellipse(self, x, y, width, height, draw=True, **kwargs):
        """Draw an ellipse.

        :param x: top left x-coordinate
        :param y: top left y-coordinate
        :param width: ellipse width
        :param height: ellipse height
        :param boolean draw: whether to draw the shape on the canvas or not
        :return: BezierPath representing the ellipse
        """

        path = self.BezierPath(**kwargs)
        path.ellipse(x, y, width, height, self.ellipsemode)
        if draw:
            path.draw()
        return path