GOffice.Marker¶
| Subclasses: | None | 
|---|
Methods¶
| Inherited: | GObject.Object (37) | 
|---|---|
| Structs: | GObject.ObjectClass (5) | 
| class | new() | 
| class | selector_new(initial_shape, default_shape) | 
| class | selector_set_auto_fill(selector, auto_fill) | 
| class | selector_set_colors(selector, outline, fill) | 
| class | selector_set_shape(selector, shape) | 
| class | shape_as_str(shape) | 
| class | shape_from_str(name) | 
| assign(src) | |
| create_cairo_surface(cr, scale, width, height) | |
| dup() | |
| get_fill_color() | |
| get_outline_color() | |
| get_outline_width() | |
| get_shape() | |
| get_size() | |
| is_closed_shape() | |
| render(cr, x, y, scale) | |
| set_fill_color(color) | |
| set_outline_color(color) | |
| set_shape(shape) | |
| set_size(size) | 
Virtual Methods¶
| Inherited: | GObject.Object (7) | 
|---|
Properties¶
None
Signals¶
| Inherited: | GObject.Object (1) | 
|---|
Fields¶
| Inherited: | GObject.Object (1) | 
|---|
Class Details¶
- 
class GOffice.Marker(**kwargs)¶
- Bases: - GObject.Object- Abstract: - No - 
classmethod new()¶
- Return type: - GOffice.Marker
 - 
classmethod selector_new(initial_shape, default_shape)¶
- Parameters: - initial_shape (GOffice.MarkerShape) – marker shape intially selected
- default_shape (GOffice.MarkerShape) – automatic marker shape
 - Returns: - a new - Gtk.Widget.- Return type: - Creates a new marker selector. 
- initial_shape (
 - 
classmethod selector_set_auto_fill(selector, auto_fill)¶
- Parameters: - selector (GOffice.Selector) – aGOffice.Selector
- auto_fill (bool) – whether to use a transparent color for opened markers such as cross, x, or asterisk.
 
- selector (
 - 
classmethod selector_set_colors(selector, outline, fill)¶
- Parameters: - selector (GOffice.Selector) – aGOffice.Selector
- outline (int) – outline color
- fill (int) –GOffice.fillcolor
 - Updates swatch colors of selector. 
- selector (
 - 
classmethod selector_set_shape(selector, shape)¶
- Parameters: - selector (GOffice.Selector) – aGOffice.Selector
- shape (GOffice.MarkerShape) – new marker shape
 - Updates marker shape of selector. 
- selector (
 - 
classmethod shape_as_str(shape)¶
- Parameters: - shape ( - GOffice.MarkerShape) –- Return type: - str
 - 
classmethod shape_from_str(name)¶
- Parameters: - name ( - str) –- Return type: - GOffice.MarkerShape
 - 
assign(src)¶
- Parameters: - src ( - GOffice.Marker) –
 - 
create_cairo_surface(cr, scale, width, height)¶
- Parameters: - cr (cairo.Context) – a cairo context
- scale (float) – current context scale
- width (float) – a placeholder for the surface width
- height (float) – a placeholder for the surface height
 - Returns: - a newly created - cairo.Surface. This surface should be destroyed using cairo_surface_destroy after use.- Return type: - Creates a new cairo surface similar to the current target of cr, and render self on it. center will contain the coordinate of the center of the surface. 
- cr (
 - 
dup()¶
- Returns: - the duplicated marker. - Return type: - GOffice.Marker- Duplicates self. 
 - 
get_shape()¶
- Return type: - GOffice.MarkerShape
 - 
render(cr, x, y, scale)¶
- Parameters: - cr (cairo.Context) – a cairo context
- x (float) – x position
- y (float) – y position
- scale (float) – current scale
 - Renders self onto the cairo target, using x and y for the position. 
- cr (
 - 
set_shape(shape)¶
- Parameters: - shape ( - GOffice.MarkerShape) –
 
- 
classmethod