goocanvas.Ellipse
Prev | PyGooCanvas Standard Canvas Items Reference | Next

## goocanvas.Ellipse

goocanvas.Ellipse — An ellipse item.

## Synopsis

    class goocanvas.Ellipse(goocanvas.ItemSimple):
        goocanvas.Ellipse(properties=None)

## Ancestry

    +-- gobject.GObject
    	+-- goocanvas.ItemSimple
    		+-- goocanvas.Ellipse

## goocanvas.Ellipse Properties

"center_x" | Read/Write | The x coordinate of the center of the ellipse. Default value: 0.
"center_y" | Read/Write | The y coordinate of the center of the ellipse. Default value: 0.
"height" | Read/Write | The height of the ellipse. Allowed values: >= 0. Default value: 0.
"radius_x" | Read/Write | The horizontal radius of the ellipse. Allowed values: >= 0. Default value: 0.
"radius_y" | Read/Write | The vertical radius of the ellipse. Allowed values: >= 0. Default value: 0.
"width" | Read/Write | The width of the ellipse. Allowed values: >= 0. Default value: 0.
"x" | Read/Write | The x coordinate of the left side of the ellipse. Default value: 0.
"y" | Read/Write | The y coordinate of the top of the ellipse. Default value: 0.

## Implemented Interfaces

`goocanvas.Ellipse` implements `goocanvas.Item`

## Description

`goocanvas.Ellipse` represents an ellipse item. It is a subclass of `goocanvas.ItemSimple` and so inherits all of the style properties such as "stroke-color", "fill-color" and "line-width". It also implements the `goocanvas.Item` interface, so you can use the `goocanvas.Item` functions such as `goocanvas.Item.raise_()` and `goocanvas.Item.rotate()`

## Constructor

        goocanvas.Ellipse(properties=None)

`properties`: | A comma separated list of properties.
Returns: | A new `goocanvas.Ellipse`

Creates a new canvas ellipse item.

Here's an example showing how to create an ellipse centered at (100.0, 100.0), with a horizontal radius of 50.0 and a vertical radius of 30.0. It is drawn with a red outline with a width of 5.0 and filled with blue:

    ellipse = goocanvas.Ellipse(parent=root,
                                center_x=100,
                                center_y=100,
                                radius_x=50,
                                radius_y=30,
                                stroke_color="red",
                                fill_color="blue",
                                line_width=5.0)

Prev | Up | Next
PyGooCanvas Standard Canvas Items Reference | Home | goocanvas.Grid