GooCanvas.CanvasPolylineModel

g GObject.GInterface GObject.GInterface GooCanvas.CanvasItemModel GooCanvas.CanvasItemModel GObject.GInterface->GooCanvas.CanvasItemModel GObject.Object GObject.Object GooCanvas.CanvasItemModelSimple GooCanvas.CanvasItemModelSimple GObject.Object->GooCanvas.CanvasItemModelSimple GooCanvas.CanvasItemModel->GooCanvas.CanvasItemModelSimple GooCanvas.CanvasPolylineModel GooCanvas.CanvasPolylineModel GooCanvas.CanvasItemModelSimple->GooCanvas.CanvasPolylineModel

Subclasses:

None

Methods

Inherited:

GObject.Object (37), GooCanvas.CanvasItemModel (30)

Structs:

GObject.ObjectClass (5)

Virtual Methods

Inherited:

GObject.Object (7), GooCanvas.CanvasItemModel (19)

Properties

Inherited:

GooCanvas.CanvasItemModelSimple (23), GooCanvas.CanvasItemModel (9)

Name

Type

Flags

Short Description

arrow-length

float

r/w

The length of the arrows, as a multiple of the line width

arrow-tip-length

float

r/w

The length of the arrow tip, as a multiple of the line width

arrow-width

float

r/w

The width of the arrows, as a multiple of the line width

close-path

bool

r/w

If the last point should be connected to the first

end-arrow

bool

r/w

If an arrow should be displayed at the end of the polyline

height

float

r/w

The height of the polyline

points

GooCanvas.CanvasPoints

r/w

The array of points

start-arrow

bool

r/w

If an arrow should be displayed at the start of the polyline

width

float

r/w

The width of the polyline

x

float

r/w

The x coordinate of the left-most point of the polyline

y

float

r/w

The y coordinate of the top-most point of the polyline

Signals

Inherited:

GObject.Object (1), GooCanvas.CanvasItemModel (6)

Fields

Inherited:

GObject.Object (1), GooCanvas.CanvasItemModel (6)

Name

Type

Access

Description

parent_object

GooCanvas.CanvasItemModelSimple

r

polyline_data

GooCanvas.CanvasPolylineData

r

Class Details

class GooCanvas.CanvasPolylineModel(**kwargs)
Bases:

GooCanvas.CanvasItemModelSimple

Abstract:

No

Structure:

GooCanvas.CanvasPolylineModelClass

GooCanvas.CanvasPolylineModel represents a model for polyline items, which are a series of one or more lines, with optional arrows at either end.

It is a subclass of GooCanvas.CanvasItemModelSimple and so inherits all of the style properties such as “stroke-color”, “fill-color” and “line-width”.

It also implements the GooCanvas.CanvasItemModel interface, so you can use the GooCanvas.CanvasItemModel functions such as GooCanvas.CanvasItemModel.raise_() and GooCanvas.CanvasItemModel.rotate().

To create a GooCanvas.CanvasPolylineModel use goo_canvas_polyline_model_new(), or goo_canvas_polyline_model_new_line() for a GooCanvas.simple line between two points.

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

To respond to events such as mouse clicks on the polyline you must connect to the signal handlers of the corresponding GooCanvas.CanvasPolyline objects. (See GooCanvas.Canvas.get_item() and GooCanvas.Canvas ::item-created.)

Property Details

GooCanvas.CanvasPolylineModel.props.arrow_length
Name:

arrow-length

Type:

float

Default Value:

5.0

Flags:

READABLE, WRITABLE

The length of the arrows, as a multiple of the line width

GooCanvas.CanvasPolylineModel.props.arrow_tip_length
Name:

arrow-tip-length

Type:

float

Default Value:

4.0

Flags:

READABLE, WRITABLE

The length of the arrow tip, as a multiple of the line width

GooCanvas.CanvasPolylineModel.props.arrow_width
Name:

arrow-width

Type:

float

Default Value:

4.0

Flags:

READABLE, WRITABLE

The width of the arrows, as a multiple of the line width

GooCanvas.CanvasPolylineModel.props.close_path
Name:

close-path

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE

If the last point should be connected to the first

GooCanvas.CanvasPolylineModel.props.end_arrow
Name:

end-arrow

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE

If an arrow should be displayed at the end of the polyline

GooCanvas.CanvasPolylineModel.props.height
Name:

height

Type:

float

Default Value:

0.0

Flags:

READABLE, WRITABLE

The height of the polyline

GooCanvas.CanvasPolylineModel.props.points
Name:

points

Type:

GooCanvas.CanvasPoints

Default Value:

None

Flags:

READABLE, WRITABLE

The array of points

GooCanvas.CanvasPolylineModel.props.start_arrow
Name:

start-arrow

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE

If an arrow should be displayed at the start of the polyline

GooCanvas.CanvasPolylineModel.props.width
Name:

width

Type:

float

Default Value:

0.0

Flags:

READABLE, WRITABLE

The width of the polyline

GooCanvas.CanvasPolylineModel.props.x
Name:

x

Type:

float

Default Value:

0.0

Flags:

READABLE, WRITABLE

The x coordinate of the left-most point of the polyline

GooCanvas.CanvasPolylineModel.props.y
Name:

y

Type:

float

Default Value:

0.0

Flags:

READABLE, WRITABLE

The y coordinate of the top-most point of the polyline