GooCanvasEllipseModel: GooCanvas Reference Manual

## GooCanvasEllipseModel GooCanvasEllipseModel — a model for ellipse items. |

## Functions

GooCanvasItemModel * | goo_canvas_ellipse_model_new ()

## Properties

gdouble | center-x | Read / Write
gdouble | center-y | Read / Write
gdouble | height | Read / Write
gdouble | radius-x | Read / Write
gdouble | radius-y | Read / Write
gdouble | width | Read / Write
gdouble | x | Read / Write
gdouble | y | Read / Write

## Types and Values

struct | GooCanvasEllipseModel

## Object Hierarchy

        GObject
        ╰── GooCanvasItemModelSimple
            ╰── GooCanvasEllipseModel

## Implemented Interfaces

GooCanvasEllipseModel implements GooCanvasItemModel.

## Description

GooCanvasEllipseModel represents a model for ellipse items.

It is a subclass of GooCanvasItemModelSimple and so inherits all of the style properties such as "stroke-color", "fill-color" and "line-width".

It also implements the GooCanvasItemModel interface, so you can use the GooCanvasItemModel functions such as `goo_canvas_item_model_raise()` and `goo_canvas_item_model_rotate()`.

To create a GooCanvasEllipseModel use `goo_canvas_ellipse_model_new()`.

To get or set the properties of an existing GooCanvasEllipseModel, use `g_object_get()` and `g_object_set()`.

The ellipse can be specified either with the "center-x", "center-y", "radius-x" and "radius-y" properties, or with the "x", "y", "width" and "height" properties.

To respond to events such as mouse clicks on the ellipse you must connect to the signal handlers of the corresponding GooCanvasEllipse objects. (See `goo_canvas_get_item()` and “item-created”.)

## Functions

### goo_canvas_ellipse_model_new ()

    GooCanvasItemModel *
    goo_canvas_ellipse_model_new (GooCanvasItemModel *parent,
                                  gdouble center_x,
                                  gdouble center_y,
                                  gdouble radius_x,
                                  gdouble radius_y,
                                  ...);

Creates a new ellipse model.

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:

    1
    2
    3
    4
    5
    GooCanvasItemModel *ellipse = goo_canvas_ellipse_model_new (mygroup, 100.0, 100.0, 50.0, 30.0,
                                                                "stroke-color", "red",
                                                                "line-width", 5.0,
                                                                "fill-color", "blue",
                                                                NULL);

#### Parameters

parent | the parent model, or `NULL`. If a parent is specified, it will assume ownership of the item, and the item will automatically be freed when it is removed from the parent. Otherwise call `g_object_unref()` to free it. | [skip]
center_x | the x coordinate of the center of the ellipse. |
center_y | the y coordinate of the center of the ellipse. |
radius_x | the horizontal radius of the ellipse. |
radius_y | the vertical radius of the ellipse. |
... | optional pairs of property names and values, and a terminating `NULL`. |

#### Returns

a new ellipse model.

[transfer full]

## Types and Values

### struct GooCanvasEllipseModel

    struct GooCanvasEllipseModel;

The GooCanvasEllipseModel struct contains private data only.

## Property Details

### The `“center-x”` property

      “center-x”                 gdouble

The x coordinate of the center of the ellipse.

Flags: Read / Write

Default value: 0

### The `“center-y”` property

      “center-y”                 gdouble

The y coordinate of the center of the ellipse.

Flags: Read / Write

Default value: 0

### The `“height”` property

      “height”                   gdouble

The height of the ellipse.

Flags: Read / Write

Allowed values: >= 0

Default value: 0

### The `“radius-x”` property

      “radius-x”                 gdouble

The horizontal radius of the ellipse.

Flags: Read / Write

Allowed values: >= 0

Default value: 0

### The `“radius-y”` property

      “radius-y”                 gdouble

The vertical radius of the ellipse.

Flags: Read / Write

Allowed values: >= 0

Default value: 0

### The `“width”` property

      “width”                    gdouble

The width of the ellipse.

Flags: Read / Write

Allowed values: >= 0

Default value: 0

### The `“x”` property

      “x”                        gdouble

The x coordinate of the left side of the ellipse.

Flags: Read / Write

Default value: 0

### The `“y”` property

      “y”                        gdouble

The y coordinate of the top of the ellipse.

Flags: Read / Write

Default value: 0