GooCanvas.CanvasGridModel¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
---|---|---|---|
w |
The color to use for the border |
||
r/w |
The color to use for the border, specified as a |
||
r/w |
The color to use for the border, specified as a 32-bit integer value |
||
r/w |
The cairo pattern to paint the border with |
||
w |
The pixbuf to use to draw the border |
||
r/w |
The width of the border around the grid |
||
r/w |
The height of the grid |
||
w |
The color to use for the horizontal grid lines |
||
r/w |
The color to use for the horizontal grid lines, specified as a |
||
r/w |
The color to use for the horizontal grid lines, specified as a 32-bit integer value |
||
r/w |
The cairo pattern to paint the horizontal grid lines with |
||
w |
The pixbuf to use to draw the horizontal grid lines |
||
r/w |
The width of the horizontal grid lines |
||
r/w |
If the horizontal grid lines are shown |
||
r/w |
If the vertical grid lines are shown |
||
w |
The color to use for the vertical grid lines |
||
r/w |
The color to use for the vertical grid lines, specified as a |
||
r/w |
The color to use for the vertical grid lines, specified as a 32-bit integer value |
||
r/w |
The cairo pattern to paint the vertical grid lines with |
||
w |
The pixbuf to use to draw the vertical grid lines |
||
r/w |
The width of the vertical grid lines |
||
r/w |
If the vertical grid lines are painted above the horizontal grid lines |
||
r/w |
The width of the grid |
||
r/w |
The x coordinate of the grid |
||
r/w |
The distance before the first vertical grid line |
||
r/w |
The distance between the vertical grid lines |
||
r/w |
The y coordinate of the grid |
||
r/w |
The distance before the first horizontal grid line |
||
r/w |
The distance between the horizontal grid lines |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
grid_data |
r |
||
parent_object |
r |
Class Details¶
- class GooCanvas.CanvasGridModel(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
GooCanvas.CanvasGridModel
represents a model for grid items. A grid consists of a number of equally-spaced horizontal and vertical grid lines, plus an optional border.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 theGooCanvas.CanvasItemModel
functions such asGooCanvas.CanvasItemModel.raise_
() andGooCanvas.CanvasItemModel.rotate
().To create a
GooCanvas.CanvasGridModel
use goo_canvas_grid_model_new().To get or set the properties of an existing
GooCanvas.CanvasGridModel
, use g_object_get() and g_object_set().To respond to events such as mouse clicks on the grid you must connect to the signal handlers of the corresponding
GooCanvas.CanvasGrid
objects. (SeeGooCanvas.Canvas.get_item
() andGooCanvas.Canvas
::item-created
.)The grid’s position and size is specified with the
GooCanvas.CanvasGridModel
:x
,GooCanvas.CanvasGridModel
:y
,GooCanvas.CanvasGridModel
:width
andGooCanvas.CanvasGridModel
:height
properties.The
GooCanvas.CanvasGridModel
:x-step
andGooCanvas.CanvasGridModel
:y-step
properties specify the distance between grid lines. TheGooCanvas.CanvasGridModel
:x-offset
andGooCanvas.CanvasGridModel
:y-offset
properties specify the distance before the first grid lines.The horizontal or vertical grid lines can be hidden using the
GooCanvas.CanvasGridModel
:show-horz-grid-lines
andGooCanvas.CanvasGridModel
:show-vert-grid-lines
properties.The width of the border can be set using the
GooCanvas.CanvasGridModel
:border-width
property. The border is drawn outside the area specified with theGooCanvas.CanvasGridModel
:x
,GooCanvas.CanvasGridModel
:y
,GooCanvas.CanvasGridModel
:width
andGooCanvas.CanvasGridModel
:height
properties.Other properties allow the colors and widths of the grid lines to be set. The grid line color and width properties override the standard
GooCanvas.CanvasItemModelSimple
:stroke-color
andGooCanvas.CanvasItemModelSimple
:line-width
properties, enabling different styles for horizontal and vertical grid lines.
Property Details¶
- GooCanvas.CanvasGridModel.props.border_color¶
-
The color to use for the border
- GooCanvas.CanvasGridModel.props.border_color_gdk_rgba¶
-
The color to use for the border, specified as a
Gdk.RGBA
- GooCanvas.CanvasGridModel.props.border_color_rgba¶
-
The color to use for the border, specified as a 32-bit integer value
- GooCanvas.CanvasGridModel.props.border_pattern¶
-
The cairo pattern to paint the border with
- GooCanvas.CanvasGridModel.props.border_pixbuf¶
- Name:
border-pixbuf
- Type:
- Default Value:
- Flags:
The pixbuf to use to draw the border
- GooCanvas.CanvasGridModel.props.border_width¶
-
The width of the border around the grid
- GooCanvas.CanvasGridModel.props.height¶
-
The height of the grid
- GooCanvas.CanvasGridModel.props.horz_grid_line_color¶
-
The color to use for the horizontal grid lines
- GooCanvas.CanvasGridModel.props.horz_grid_line_color_gdk_rgba¶
-
The color to use for the horizontal grid lines, specified as a
Gdk.RGBA
- GooCanvas.CanvasGridModel.props.horz_grid_line_color_rgba¶
-
The color to use for the horizontal grid lines, specified as a 32-bit integer value
- GooCanvas.CanvasGridModel.props.horz_grid_line_pattern¶
-
The cairo pattern to paint the horizontal grid lines with
- GooCanvas.CanvasGridModel.props.horz_grid_line_pixbuf¶
- Name:
horz-grid-line-pixbuf
- Type:
- Default Value:
- Flags:
The pixbuf to use to draw the horizontal grid lines
- GooCanvas.CanvasGridModel.props.horz_grid_line_width¶
-
The width of the horizontal grid lines
- GooCanvas.CanvasGridModel.props.show_horz_grid_lines¶
-
If the horizontal grid lines are shown
- GooCanvas.CanvasGridModel.props.show_vert_grid_lines¶
-
If the vertical grid lines are shown
- GooCanvas.CanvasGridModel.props.vert_grid_line_color¶
-
The color to use for the vertical grid lines
- GooCanvas.CanvasGridModel.props.vert_grid_line_color_gdk_rgba¶
-
The color to use for the vertical grid lines, specified as a
Gdk.RGBA
- GooCanvas.CanvasGridModel.props.vert_grid_line_color_rgba¶
-
The color to use for the vertical grid lines, specified as a 32-bit integer value
- GooCanvas.CanvasGridModel.props.vert_grid_line_pattern¶
-
The cairo pattern to paint the vertical grid lines with
- GooCanvas.CanvasGridModel.props.vert_grid_line_pixbuf¶
- Name:
vert-grid-line-pixbuf
- Type:
- Default Value:
- Flags:
The pixbuf to use to draw the vertical grid lines
- GooCanvas.CanvasGridModel.props.vert_grid_line_width¶
-
The width of the vertical grid lines
- GooCanvas.CanvasGridModel.props.vert_grid_lines_on_top¶
-
If the vertical grid lines are painted above the horizontal grid lines
- GooCanvas.CanvasGridModel.props.width¶
-
The width of the grid
- GooCanvas.CanvasGridModel.props.x¶
-
The x coordinate of the grid
- GooCanvas.CanvasGridModel.props.x_offset¶
-
The distance before the first vertical grid line
- GooCanvas.CanvasGridModel.props.x_step¶
-
The distance between the vertical grid lines
- GooCanvas.CanvasGridModel.props.y¶
-
The y coordinate of the grid
- GooCanvas.CanvasGridModel.props.y_offset¶
-
The distance before the first horizontal grid line