GritsMarker

GritsMarker — Single point markers

Synopsis

#define             GRITS_MARKER_DMASK_ALL
#define             GRITS_MARKER_DMASK_DIRECTIONAL
#define             GRITS_MARKER_DMASK_ICON
#define             GRITS_MARKER_DMASK_LABEL
#define             GRITS_MARKER_DMASK_NONE
#define             GRITS_MARKER_DMASK_POINT
struct              GritsMarker;
struct              GritsMarkerClass;
GritsMarker *       grits_marker_icon_new               (const gchar *label,
                                                         const gchar *filename,
                                                         guint angle,
                                                         gboolean flip,
                                                         guint display_mask);
GritsMarker *       grits_marker_new                    (const gchar *label);

Object Hierarchy

  GObject
   +----GritsObject
         +----GritsMarker

Description

Each GritsMarker represents some point on the earth with some form of content. Commonly this is used to mark geographic features such as cities or states.

While markers represent a place in three dimensions somewhere on, below, or above the surface of the earth, they are drawn in 2 dimensions so that they look normal and readable by the user. Due to this, GritsObjects should almost always be added to the GRITS_LEVEL_OVERLAY level so they are drawn "above" the actual earth.

Details

GRITS_MARKER_DMASK_ALL

#define GRITS_MARKER_DMASK_ALL          (0xffff)


GRITS_MARKER_DMASK_DIRECTIONAL

#define GRITS_MARKER_DMASK_DIRECTIONAL  (0x0010)


GRITS_MARKER_DMASK_ICON

#define GRITS_MARKER_DMASK_ICON         (0x0008)


GRITS_MARKER_DMASK_LABEL

#define GRITS_MARKER_DMASK_LABEL        (0x0002)


GRITS_MARKER_DMASK_NONE

#define GRITS_MARKER_DMASK_NONE         (0x0001)


GRITS_MARKER_DMASK_POINT

#define GRITS_MARKER_DMASK_POINT        (0x0004)


struct GritsMarker

struct GritsMarker;


struct GritsMarkerClass

struct GritsMarkerClass {
	GritsObjectClass parent_class;
};


grits_marker_icon_new ()

GritsMarker *       grits_marker_icon_new               (const gchar *label,
                                                         const gchar *filename,
                                                         guint angle,
                                                         gboolean flip,
                                                         guint display_mask);

Create a new marker with a label, point, icon (png), or any combination of the above.

label :

The label to display if GRITS_MARKER_DMASK_LABEL is set

filename :

The filename of the icon

angle :

The angle to rotate the icon (0 is north)

flip :

Whether to flip the image so that it's never upside down. Useful for non-symmetric icons which have an "up".

display_mask :

A bitmask which specifies which items to display.

Returns :

the new GritsMarker

grits_marker_new ()

GritsMarker *       grits_marker_new                    (const gchar *label);

Create a new GritsMarker which shows the given label when drawn.

label :

a short description of the marker

Returns :

the new GritsMarker.