summaryrefslogtreecommitdiff
path: root/navit/layout.h
diff options
context:
space:
mode:
Diffstat (limited to 'navit/layout.h')
-rw-r--r--navit/layout.h144
1 files changed, 81 insertions, 63 deletions
diff --git a/navit/layout.h b/navit/layout.h
index ece5d0cc8..47b078ab1 100644
--- a/navit/layout.h
+++ b/navit/layout.h
@@ -22,88 +22,106 @@
#include "item.h"
#include "color.h"
+#include "coord.h"
#ifdef __cplusplus
extern "C" {
#endif
+struct poly_hole {
+ int coord_count;
+ struct coord coord[1];
+};
struct element {
- enum { element_point, element_polyline, element_polygon, element_circle, element_text, element_icon, element_image, element_arrows } type;
- struct color color;
- int text_size;
- union {
- struct element_point {
- char stub;
- } point;
- struct element_polyline {
- int width;
- int directed;
- int dash_num;
- int offset;
- unsigned char dash_table[4];
- } polyline;
- struct element_polygon {
- char stub;
- } polygon;
- struct element_circle {
- int width;
- int radius;
- struct color background_color;
- } circle;
- struct element_icon {
- char *src;
- int width;
- int height;
- int rotation;
- int x;
- int y;
- } icon;
- struct element_text {
- struct color background_color;
- } text;
- } u;
- int coord_count;
- struct coord *coord;
+ enum { element_point, element_polyline, element_polygon, element_circle, element_text, element_icon, element_image, element_arrows } type;
+ struct color color;
+ int text_size;
+ int oneway;
+ union {
+ struct element_point {
+ char stub;
+ } point;
+ struct element_polyline {
+ int width;
+ int directed;
+ int dash_num;
+ int offset;
+ unsigned char dash_table[4];
+ } polyline;
+ struct element_polygon {
+ /* for texture */
+ char *src;
+ int width;
+ int height;
+ int rotation;
+ int x;
+ int y;
+ } polygon;
+ struct element_circle {
+ int width;
+ int radius;
+ struct color background_color;
+ } circle;
+ struct element_icon {
+ char *src;
+ int width;
+ int height;
+ int rotation;
+ int x;
+ int y;
+ } icon;
+ struct element_text {
+ struct color background_color;
+ } text;
+ struct element_arrows {
+ int width;
+ } arrows;
+ } u;
+ int coord_count;
+ struct coord *coord;
};
struct itemgra {
- struct range order,sequence_range,speed_range,angle_range;
- GList *type;
- GList *elements;
+ struct range order,sequence_range,speed_range,angle_range;
+ GList *type;
+ GList *elements;
};
struct layer {
- NAVIT_OBJECT
- struct navit *navit;
- char *name;
- int details;
- GList *itemgras;
- int active;
- struct layer *ref;
+ NAVIT_OBJECT
+ struct navit *navit;
+ char *name;
+ int details;
+ GList *itemgras;
+ int active;
+ struct layer *ref;
};
struct cursor {
- struct attr **attrs;
- struct range *sequence_range;
- char *name;
- int w,h;
- int interval;
+ struct attr **attrs;
+ struct range *sequence_range;
+ char *name;
+ int w,h;
+ int interval;
};
struct layout {
- NAVIT_OBJECT
- struct navit *navit;
- char *name;
- char* dayname;
- char* nightname;
- char *font;
- struct color color;
- GList *layers;
- GList *cursors;
- int order_delta;
- int active;
+ NAVIT_OBJECT
+ struct navit *navit;
+ char *name;
+ char* dayname;
+ char* nightname;
+ char *font;
+ struct color color;
+ int underground_alpha;
+ int icon_w;
+ int icon_h;
+ GList *layers;
+ GList *cursors;
+ int order_delta;
+ int active;
};
/* prototypes */
@@ -123,7 +141,7 @@ struct polygon;
struct polyline;
struct text;
struct layout *layout_new(struct attr *parent, struct attr **attrs);
-struct attr_iter *layout_attr_iter_new(void);
+struct attr_iter *layout_attr_iter_new(void* unused);
void layout_attr_iter_destroy(struct attr_iter *iter);
int layout_get_attr(struct layout *layout, enum attr_type type, struct attr *attr, struct attr_iter *iter);
int layout_add_attr(struct layout *layout, struct attr *attr);