navit  0.5.3-trunk
navit.h
Go to the documentation of this file.
1 
20 #ifndef NAVIT_NAVIT_H
21 #define NAVIT_NAVIT_H
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 extern struct gui *main_loop_gui;
27 // defined in glib.h.
28 #ifndef __G_LIST_H__
29 struct _GList;
30 typedef struct _GList GList;
31 #endif
32 
33 /* prototypes */
34 enum attr_type;
35 struct attr;
36 struct attr_iter;
37 struct callback;
38 struct coord_rect;
39 struct displaylist;
40 struct graphics;
41 struct gui;
42 struct layout;
43 struct mapset;
44 struct message;
45 struct navigation;
46 struct navit;
47 struct pcoord;
48 struct point;
49 struct route;
50 struct tracking;
51 struct transformation;
52 struct vehicleprofile;
53 struct command_table;
54 struct item;
55 void navit_add_mapset(struct navit *this_, struct mapset *ms);
56 struct mapset *navit_get_mapset(struct navit *this_);
57 struct map *navit_get_search_results_map(struct navit *this_);
58 int navit_populate_search_results_map(struct navit *navit, GList *search_results, struct coord_rect *r);
59 struct tracking *navit_get_tracking(struct navit *this_);
60 char *navit_get_user_data_directory(int create);
61 void navit_draw_async(struct navit *this_, int async);
62 void navit_draw(struct navit *this_);
63 int navit_get_ready(struct navit *this_);
64 void navit_draw_displaylist(struct navit *this_);
65 void navit_handle_resize(struct navit *this_, int w, int h);
66 int navit_get_width(struct navit *this_);
67 int navit_get_height(struct navit *this_);
68 int navit_ignore_button(struct navit *this_);
69 void navit_ignore_graphics_events(struct navit *this_, int ignore);
70 void navit_set_timeout(struct navit *this_);
71 int navit_handle_button(struct navit *this_, int pressed, int button, struct point *p, struct callback *popup_callback);
72 void navit_handle_motion(struct navit *this_, struct point *p);
73 void navit_zoom_in(struct navit *this_, int factor, struct point *p);
74 void navit_zoom_out(struct navit *this_, int factor, struct point *p);
75 void navit_zoom_in_cursor(struct navit *this_, int factor);
76 void navit_zoom_out_cursor(struct navit *this_, int factor);
77 struct navit *navit_new(struct attr *parent, struct attr **attrs);
78 void navit_add_message(struct navit *this_, const char *message);
79 struct message *navit_get_messages(struct navit *this_);
80 struct graphics *navit_get_graphics(struct navit *this_);
81 struct vehicleprofile *navit_get_vehicleprofile(struct navit *this_);
82 GList *navit_get_vehicleprofiles(struct navit *this_);
83 void navit_set_destination(struct navit *this_, struct pcoord *c, const char *description, int async);
84 void navit_set_destinations(struct navit *this_, struct pcoord *c, int count, const char *description, int async);
85 void navit_add_destination_description(struct navit *this_, struct pcoord *c, const char *description);
86 int navit_get_destinations(struct navit *this_, struct pcoord *pc, int count);
87 int navit_get_destination_count(struct navit *this_);
88 char* navit_get_destination_description(struct navit *this_, int n);
89 void navit_remove_nth_waypoint(struct navit *this_, int n);
90 void navit_remove_waypoint(struct navit *this_);
91 char* navit_get_coord_description(struct navit *this_, struct pcoord *c);
92 int navit_check_route(struct navit *this_);
94 void navit_textfile_debug_log(struct navit *this_, const char *fmt, ...);
95 void navit_textfile_debug_log_at(struct navit *this_, struct pcoord *pc, const char *fmt, ...);
96 int navit_speech_estimate(struct navit *this_, char *str);
97 void navit_say(struct navit *this_, const char *text);
98 void navit_speak(struct navit *this_);
99 void navit_window_roadbook_destroy(struct navit *this_);
100 void navit_window_roadbook_new(struct navit *this_);
101 int navit_init(struct navit *this_);
102 void navit_zoom_to_rect(struct navit *this_, struct coord_rect *r);
103 void navit_zoom_to_route(struct navit *this_, int orientation);
104 void navit_set_center(struct navit *this_, struct pcoord *center, int set_timeout);
105 void navit_set_center_cursor(struct navit *this_, int autozoom, int keep_orientation);
106 void navit_set_center_screen(struct navit *this_, struct point *p, int set_timeout);
107 int navit_set_attr(struct navit *this_, struct attr *attr);
108 int navit_get_attr(struct navit *this_, enum attr_type type, struct attr *attr, struct attr_iter *iter);
109 struct layout *navit_get_layout_by_name(struct navit *this_, const char *layout_name);
110 void navit_update_current_layout(struct navit *this_, struct layout *layout);
111 int navit_add_attr(struct navit *this_, struct attr *attr);
112 int navit_remove_attr(struct navit *this_, struct attr *attr);
113 struct attr_iter *navit_attr_iter_new(void * unused);
115 void navit_add_callback(struct navit *this_, struct callback *cb);
116 void navit_remove_callback(struct navit *this_, struct callback *cb);
117 void navit_set_position(struct navit *this_, struct pcoord *c);
118 struct gui *navit_get_gui(struct navit *this_);
119 struct transformation *navit_get_trans(struct navit *this_);
120 struct route *navit_get_route(struct navit *this_);
121 struct navigation *navit_get_navigation(struct navit *this_);
122 struct displaylist *navit_get_displaylist(struct navit *this_);
123 void navit_layout_switch(struct navit *n);
124 int navit_set_vehicle_by_name(struct navit *n, const char *name);
125 int navit_set_vehicleprofile_name(struct navit *this_, char *name);
126 int navit_set_layout_by_name(struct navit *n, const char *name);
127 void navit_disable_suspend(void);
128 int navit_block(struct navit *this_, int block);
129 int navit_get_blocked(struct navit *this_);
130 void navit_destroy(struct navit *this_);
131 void navit_command_add_table(struct navit*this_, struct command_table *commands, int count);
132 struct navit * navit_ref(struct navit *this_);
133 void navit_unref(struct navit *this_);
134 /* end of prototypes */
135 #ifdef __cplusplus
136 }
137 #endif
138 
139 #endif
140 
int orientation
Definition: pedestrian.c:71
Definition: navigation.c:161
attr_type
Definition: attr.h:34
void navit_handle_motion(struct navit *this_, struct point *p)
Definition: navit.c:669
void navit_command_add_table(struct navit *this_, struct command_table *commands, int count)
Definition: navit.c:1446
Definition: messages.h:25
unsigned char p[5]
Definition: mg.h:48
void navit_set_center_screen(struct navit *this_, struct point *p, int set_timeout)
Definition: navit.c:2488
void navit_update_current_layout(struct navit *this_, struct layout *layout)
Set the current layout.
Definition: navit.c:2969
struct attr_iter * navit_attr_iter_new(void *unused)
Definition: navit.c:3112
struct map * navit_get_search_results_map(struct navit *this_)
Get the search result map (and create it if it does not exist)
Definition: navit.c:239
Definition: gpx2navit_txt.h:51
static char * description(struct search_param *search, GtkTreeIter *iter)
Definition: destination.c:56
int navit_get_attr(struct navit *this_, enum attr_type type, struct attr *attr, struct attr_iter *iter)
Definition: navit.c:2729
void navit_add_destination_description(struct navit *this_, struct pcoord *c, const char *description)
Definition: navit.c:1654
struct route * navit_get_route(struct navit *this_)
Definition: navit.c:3430
int navit_get_width(struct navit *this_)
Definition: navit.c:481
struct graphics * navit_get_graphics(struct navit *this_)
Definition: navit.c:1552
Definition: item.h:100
void navit_attr_iter_destroy(struct attr_iter *iter)
Definition: navit.c:3116
void navit_draw_displaylist(struct navit *this_)
Definition: navit.c:408
A mapset.
Definition: mapset.c:44
int navit_add_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:3032
void navit_zoom_out(struct navit *this_, int factor, struct point *p)
Definition: navit.c:807
Definition: gui.c:30
void navit_speak(struct navit *this_)
Definition: navit.c:1908
int navit_populate_search_results_map(struct navit *navit, GList *search_results, struct coord_rect *r)
Populate a map containing one or more search result points.
Definition: navit.c:301
struct gui * navit_get_gui(struct navit *this_)
Definition: navit.c:3420
int navit_get_destinations(struct navit *this_, struct pcoord *pc, int count)
Definition: navit.c:1695
Definition: vehicleprofile.h:33
void navit_add_mapset(struct navit *this_, struct mapset *ms)
Definition: navit.c:211
int navit_get_height(struct navit *this_)
Definition: navit.c:486
Definition: track.c:84
int navit_set_layout_by_name(struct navit *n, const char *name)
Definition: navit.c:3608
int navit_set_vehicleprofile_name(struct navit *this_, char *name)
Definition: navit.c:3335
void navit_ignore_graphics_events(struct navit *this_, int ignore)
Definition: navit.c:519
struct tracking * navit_get_tracking(struct navit *this_)
Definition: navit.c:358
void navit_set_timeout(struct navit *this_)
Definition: navit.c:557
struct navit * navit_new(struct attr *parent, struct attr **attrs)
Definition: navit.c:1451
void navit_set_position(struct navit *this_, struct pcoord *c)
Definition: navit.c:3317
struct mapset * navit_get_mapset(struct navit *this_)
Get the current mapset.
Definition: navit.c:223
int navit_init(struct navit *this_)
Definition: navit.c:2055
void navit_zoom_out_cursor(struct navit *this_, int factor)
Definition: navit.c:824
GList * navit_get_vehicleprofiles(struct navit *this_)
Definition: navit.c:1561
void navit_disable_suspend(void)
Definition: navit.c:3640
void navit_set_center_cursor(struct navit *this_, int autozoom, int keep_orientation)
Recalculates the map view so that the vehicle cursor is visible.
Definition: navit.c:2444
A complete route.
Definition: route.c:201
int navit_check_route(struct navit *this_)
Checks if a route is calculated.
Definition: navit.c:1742
void navit_say(struct navit *this_, const char *text)
Definition: navit.c:1868
void navit_zoom_in(struct navit *this_, int factor, struct point *p)
Definition: navit.c:789
struct tcoord center
Definition: garmin_img.c:485
void navit_set_destination(struct navit *this_, struct pcoord *c, const char *description, int async)
Definition: navit.c:1598
graphics object A graphics object serves as the target for drawing operations. It encapsulates variou...
Definition: graphics.c:75
void navit_window_roadbook_new(struct navit *this_)
Definition: navit.c:2043
Definition: config_.c:47
int navit_get_destination_count(struct navit *this_)
Definition: navit.c:1702
int navit_handle_button(struct navit *this_, int pressed, int button, struct point *p, struct callback *popup_callback)
Definition: navit.c:564
void navit_handle_resize(struct navit *this_, int w, int h)
Definition: navit.c:457
void navit_draw_async(struct navit *this_, int async)
Definition: navit.c:386
void navit_window_roadbook_destroy(struct navit *this_)
Definition: navit.c:2036
struct map * read_former_destinations_from_file(void)
Definition: navit.c:1768
Definition: attr.h:157
void navit_zoom_in_cursor(struct navit *this_, int factor)
Definition: navit.c:815
int navit_ignore_button(struct navit *this_)
Sets a flag indicating that the current button event should be ignored by subsequent handlers...
Definition: navit.c:512
struct navigation * navit_get_navigation(struct navit *this_)
Definition: navit.c:3435
int navit_block(struct navit *this_, int block)
Blocks or unblocks redraw operations.
Definition: navit.c:3663
struct gui * main_loop_gui
Definition: navit.c:185
int navit_set_vehicle_by_name(struct navit *n, const char *name)
Definition: navit.c:3586
Definition: mg.h:33
void navit_add_message(struct navit *this_, const char *message)
Definition: navit.c:1527
Definition: callback.c:27
void navit_remove_callback(struct navit *this_, struct callback *cb)
Definition: navit.c:3124
void navit_remove_nth_waypoint(struct navit *this_, int n)
Definition: navit.c:1714
void navit_set_destinations(struct navit *this_, struct pcoord *c, int count, const char *description, int async)
Definition: navit.c:1674
void navit_destroy(struct navit *this_)
Definition: navit.c:3686
struct transformation * navit_get_trans(struct navit *this_)
Definition: navit.c:3425
Definition: point.h:23
Holds information about a map.
Definition: map.c:60
void navit_textfile_debug_log_at(struct navit *this_, struct pcoord *pc, const char *fmt,...)
Definition: navit.c:1854
int navit_set_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:2725
struct vehicleprofile * navit_get_vehicleprofile(struct navit *this_)
Definition: navit.c:1557
void navit_remove_waypoint(struct navit *this_)
Definition: navit.c:1724
int navit_get_blocked(struct navit *this_)
Returns whether redraw operations are currently blocked.
Definition: navit.c:3682
void navit_set_center(struct navit *this_, struct pcoord *center, int set_timeout)
Definition: navit.c:2291
Definition: graphics.c:120
char * navit_get_user_data_directory(int create)
Get the user data directory.
Definition: navit.c:372
struct message * navit_get_messages(struct navit *this_)
Definition: navit.c:1532
void navit_layout_switch(struct navit *n)
Definition: navit.c:3445
Definition: coord.h:58
char type[3]
Definition: garmin_img.c:123
void navit_draw(struct navit *this_)
Definition: navit.c:397
char name[0]
Definition: street.c:496
Definition: navit.c:112
Definition: coord.h:52
Definition: command.h:27
static struct command_table commands[]
Definition: binding_dbus.c:2211
struct displaylist * navit_get_displaylist(struct navit *this_)
Definition: navit.c:3440
void navit_add_callback(struct navit *this_, struct callback *cb)
Definition: navit.c:3120
int navit_remove_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:3095
void * iter
Definition: config_.c:48
void navit_zoom_to_route(struct navit *this_, int orientation)
Definition: navit.c:2242
The parameters needed to transform a map for display.
Definition: transform.c:64
struct layout * navit_get_layout_by_name(struct navit *this_, const char *layout_name)
Select the default layout by name.
Definition: navit.c:2944
void navit_textfile_debug_log(struct navit *this_, const char *fmt,...)
Definition: navit.c:1839
void navit_zoom_to_rect(struct navit *this_, struct coord_rect *r)
Definition: navit.c:2213
int navit_get_ready(struct navit *this_)
Definition: navit.c:402
char * navit_get_destination_description(struct navit *this_, int n)
Definition: navit.c:1708
Definition: layout.h:110