## GOMarker

GOMarker

## Synopsis

                        GOMarker;
    enum                GOMarkerShape;
    void                go_marker_assign                    (GOMarker *dst,
                                                             GOMarker const *src);
    cairo_surface_t *   go_marker_create_cairo_surface      (GOMarker const *marker,
                                                             cairo_t *cr,
                                                             double scale,
                                                             double *width,
                                                             double *height);
    GOMarker *          go_marker_dup                       (GOMarker const *src);
    GOColor             go_marker_get_fill_color            (GOMarker const *m);
    GOColor             go_marker_get_outline_color         (GOMarker const *m);
    double              go_marker_get_outline_width         (GOMarker const *m);
    GOMarkerShape       go_marker_get_shape                 (GOMarker const *m);
    int                 go_marker_get_size                  (GOMarker const *m);
    GOMarker *          go_marker_new                       (void);
    void                go_marker_render                    (GOMarker const *marker,
                                                             cairo_t *cr,
                                                             double x,
                                                             double y,
                                                             double scale);
    void                go_marker_set_fill_color            (GOMarker *m,
                                                             GOColor color);
    void                go_marker_set_outline_color         (GOMarker *m,
                                                             GOColor color);
    void                go_marker_set_shape                 (GOMarker *m,
                                                             GOMarkerShape shape);
    void                go_marker_set_size                  (GOMarker *m,
                                                             int size);
    char const      *   go_marker_shape_as_str              (GOMarkerShape shape);
    GOMarkerShape       go_marker_shape_from_str            (char const *name);

## Object Hierarchy

      GObject
       +----GOMarker

## Description

## Details

### GOMarker

    typedef struct _GOMarker GOMarker;

### enum GOMarkerShape

    typedef enum {
    	GO_MARKER_NONE,
    	GO_MARKER_SQUARE,
    	GO_MARKER_DIAMOND,
    	GO_MARKER_TRIANGLE_DOWN,
    	GO_MARKER_TRIANGLE_UP,
    	GO_MARKER_TRIANGLE_RIGHT,
    	GO_MARKER_TRIANGLE_LEFT,
    	GO_MARKER_CIRCLE,
    	GO_MARKER_X,
    	GO_MARKER_CROSS,
    	GO_MARKER_ASTERISK,
    	GO_MARKER_BAR,
    	GO_MARKER_HALF_BAR,
    	GO_MARKER_BUTTERFLY,
    	GO_MARKER_HOURGLASS,
    	GO_MARKER_LEFT_HALF_BAR,
    	GO_MARKER_MAX
    } GOMarkerShape;

`GO_MARKER_NONE` | no mark.
`GO_MARKER_SQUARE` | square.
`GO_MARKER_DIAMOND` | diamond.
`GO_MARKER_TRIANGLE_DOWN` | triangle down.
`GO_MARKER_TRIANGLE_UP` | triangle up.
`GO_MARKER_TRIANGLE_RIGHT` | triangle right.
`GO_MARKER_TRIANGLE_LEFT` | triangle left.
`GO_MARKER_CIRCLE` | circle.
`GO_MARKER_X` | X.
`GO_MARKER_CROSS` | cross.
`GO_MARKER_ASTERISK` | asterisk.
`GO_MARKER_BAR` | horizontal bar.
`GO_MARKER_HALF_BAR` | right half bar.
`GO_MARKER_BUTTERFLY` | butterfly.
`GO_MARKER_HOURGLASS` | hourglass.
`GO_MARKER_LEFT_HALF_BAR` | left half bar.
`GO_MARKER_MAX` | maximum value, should not occur.

### go_marker_assign ()

    void                go_marker_assign                    (GOMarker *dst,
                                                             GOMarker const *src);

### go_marker_create_cairo_surface ()

    cairo_surface_t *   go_marker_create_cairo_surface      (GOMarker const *marker,
                                                             cairo_t *cr,
                                                             double scale,
                                                             double *width,
                                                             double *height);

Creates a new cairo surface similar to the current target of `cr`, and render `marker` on it. `center` will contain the coordinate of the center of the surface.

`marker` : | a GOMarker
`cr` : | a cairo context
`scale` : | current context scale
`width` : | a placeholder for the surface width
`height` : | a placeholder for the surface height
Returns : | a newly created cairo_surface_t. This surface should be destroyed using cairo_surface_destroy after use.

### go_marker_dup ()

    GOMarker *          go_marker_dup                       (GOMarker const *src);

Duplicates `src`.

`src` : | the GOMarker to duplicate
Returns : | the duplicated marker. [transfer full]

### go_marker_get_fill_color ()

    GOColor             go_marker_get_fill_color            (GOMarker const *m);

### go_marker_get_outline_color ()

    GOColor             go_marker_get_outline_color         (GOMarker const *m);

### go_marker_get_outline_width ()

    double              go_marker_get_outline_width         (GOMarker const *m);

### go_marker_get_shape ()

    GOMarkerShape       go_marker_get_shape                 (GOMarker const *m);

### go_marker_get_size ()

    int                 go_marker_get_size                  (GOMarker const *m);

### go_marker_new ()

    GOMarker *          go_marker_new                       (void);

### go_marker_render ()

    void                go_marker_render                    (GOMarker const *marker,
                                                             cairo_t *cr,
                                                             double x,
                                                             double y,
                                                             double scale);

Renders `marker` onto the `cairo` target, using `x` and `y` for the position.

`marker` : | a GOMarker
`cr` : | a cairo context
`x` : | x position
`y` : | y position
`scale` : | current scale

### go_marker_set_fill_color ()

    void                go_marker_set_fill_color            (GOMarker *m,
                                                             GOColor color);

### go_marker_set_outline_color ()

    void                go_marker_set_outline_color         (GOMarker *m,
                                                             GOColor color);

### go_marker_set_shape ()

    void                go_marker_set_shape                 (GOMarker *m,
                                                             GOMarkerShape shape);

### go_marker_set_size ()

    void                go_marker_set_size                  (GOMarker *m,
                                                             int size);

### go_marker_shape_as_str ()

    char const      *   go_marker_shape_as_str              (GOMarkerShape shape);

### go_marker_shape_from_str ()

    GOMarkerShape       go_marker_shape_from_str            (char const *name);