| Geoc (geocanvas) Reference Manual | ||||
|---|---|---|---|---|
GeocGridsGeocGrids — A GeocItem that draws lat/lon graticules to the canvas |
GeocGrids;
void geoc_grids_connect_auto_to_fixed (GeocGrids *autogrid,
GeocGrids *fixed);
GeocItem* geoc_grids_new (GeocItem *parent,
GeocCanvas *canvas,
const gchar *first_arg_name,
...);
"auto" gboolean : Read / Write "autoavail" gboolean : Read "canvas" GeocCanvas* : Read / Write "dash" CrDash* : Read / Write "fill-color" gchar* : Read / Write "fill-color-rgba" guint : Read / Write "font" gchar* : Read / Write "line-width" gdouble : Read / Write "outline-color" gchar* : Read / Write "outline-color-rgba" guint : Read / Write "spacing" gdouble : Read / Write
The GeocGrids canvas group provides a graticule or set of gridlines that is sometimes more useful than the cursor when trying to associate objects on the map to geographic coordinates. It operates in one of two modes. In 'automatic' mode it figures out how to best label the map and does the right thing. In 'fixed' mode it draws a fixed spaced set of grids regardless of the zoom scale or projection setting of the map.
Automatic mode only works on some cylindrical projections and only gets activated when the map is zoomed in. At the moment it is best to chain the automatic and fixed mode grids together.
void geoc_grids_connect_auto_to_fixed (GeocGrids *autogrid, GeocGrids *fixed);
A convenience routine that connects the "autoavail" property from the auto grid to the hide and show routines in the fixed canvas item. i.e., When the auto grid has a grid available, the fixed grid is hidden. When the auto grid does not have a grid available the fixed grid is shown.
|
A Grid with auto property aet to TRUE. |
|
A Grid with auto property set to FALSE. |
GeocItem* geoc_grids_new (GeocItem *parent, GeocCanvas *canvas, const gchar *first_arg_name, ...);
A factory that creates a new grids item with parent as its parent item in
one step. Any properties may be passed into the variable argument list.
|
The parent item for the new item. |
|
The canvas to put the grids on. |
|
A list of object argument name/value pairs, NULL-terminated, used to configure the item. |
|
|
Returns : |
The newly-created grids item. |
"auto" property"auto" gboolean : Read / Write
Whether to fix grid size or auto.
Default value: FALSE
"autoavail" property"autoavail" gboolean : Read
True if auto grids could be made for the current canvas viewport.
Default value: FALSE
"canvas" property"canvas" GeocCanvas* : Read / Write
Reference to GeocCanvas widget. This is needed to determine how many grids to draw when in auto mode. .
"dash" property"dash" CrDash* : Read / Write
a boxed array indicating the dash pattern to be used by Cairo. See #cairo_set_dash for more information.
"fill-color" property"fill-color" gchar* : Read / Write
A string color such as 'red', or '#123456'.
Default value: NULL
"fill-color-rgba" property"fill-color-rgba" guint : Read / Write
Text color, red,grn,blue,alpha.
Default value: 0
"font" property"font" gchar* : Read / Write
A pango font description string of the form [FAMILY-LIST] [STYLE-OPTIONS] [SIZE].
Default value: NULL
"line-width" property"line-width" gdouble : Read / Write
Path line width in user units when #CrPath:line-scaleable is TRUE. When #CrPath:line-scaleable is FALSE this is in device units.
Default value: 2
"outline-color" property"outline-color" gchar* : Read / Write
A string color such as 'red', or '#123456' to be used to sroke the path.
Default value: NULL
"outline-color-rgba" property"outline-color-rgba" guint : Read / Write
Path color, red,grn,blue,alpha.
Default value: 0
"spacing" property"spacing" gdouble : Read / Write
How far apart to draw fixed grids.
Allowed values: [1,30]
Default value: 15