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 
attr_type
Definition: attr.h:34
static struct command_table commands[]
Definition: binding_dbus.c:2211
static char * description(struct search_param *search, GtkTreeIter *iter)
Definition: destination.c:56
struct tcoord center
Definition: garmin_img.c:2
char type[3]
Definition: garmin_img.c:2
void navit_update_current_layout(struct navit *this_, struct layout *layout)
Set the current layout.
Definition: navit.c:3045
void navit_disable_suspend(void)
Definition: navit.c:3746
void navit_set_timeout(struct navit *this_)
Definition: navit.c:583
struct gui * main_loop_gui
Definition: navit.c:188
int navit_add_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:3108
void navit_ignore_graphics_events(struct navit *this_, int ignore)
Definition: navit.c:545
void navit_textfile_debug_log(struct navit *this_, const char *fmt,...)
Definition: navit.c:1891
void navit_set_center(struct navit *this_, struct pcoord *center, int set_timeout)
Definition: navit.c:2346
int navit_handle_button(struct navit *this_, int pressed, int button, struct point *p, struct callback *popup_callback)
Definition: navit.c:590
void navit_zoom_out_cursor(struct navit *this_, int factor)
Definition: navit.c:850
struct map * read_former_destinations_from_file(void)
Definition: navit.c:1820
struct transformation * navit_get_trans(struct navit *this_)
Definition: navit.c:3501
struct message * navit_get_messages(struct navit *this_)
Definition: navit.c:1561
int navit_get_height(struct navit *this_)
Definition: navit.c:512
struct attr_iter * navit_attr_iter_new(void *unused)
Definition: navit.c:3188
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:538
void navit_set_center_screen(struct navit *this_, struct point *p, int set_timeout)
Definition: navit.c:2543
int navit_init(struct navit *this_)
Definition: navit.c:2107
void navit_zoom_to_route(struct navit *this_, int orientation)
Definition: navit.c:2297
void navit_command_add_table(struct navit *this_, struct command_table *commands, int count)
Definition: navit.c:1472
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:2499
struct gui * navit_get_gui(struct navit *this_)
Definition: navit.c:3496
void navit_add_mapset(struct navit *this_, struct mapset *ms)
Definition: navit.c:214
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:304
struct mapset * navit_get_mapset(struct navit *this_)
Get the current mapset.
Definition: navit.c:226
void navit_attr_iter_destroy(struct attr_iter *iter)
Definition: navit.c:3192
void navit_destroy(struct navit *this_)
Definition: navit.c:3792
struct route * navit_get_route(struct navit *this_)
Definition: navit.c:3506
void navit_textfile_debug_log_at(struct navit *this_, struct pcoord *pc, const char *fmt,...)
Definition: navit.c:1906
int navit_get_destination_count(struct navit *this_)
Get the destinations count for the route.
Definition: navit.c:1752
struct navigation * navit_get_navigation(struct navit *this_)
Definition: navit.c:3511
void navit_handle_resize(struct navit *this_, int w, int h)
Definition: navit.c:460
int navit_set_vehicleprofile_name(struct navit *this_, char *name)
Definition: navit.c:3411
int navit_get_ready(struct navit *this_)
Definition: navit.c:405
void navit_zoom_to_rect(struct navit *this_, struct coord_rect *r)
Definition: navit.c:2268
void navit_zoom_in(struct navit *this_, int factor, struct point *p)
Definition: navit.c:815
void navit_zoom_out(struct navit *this_, int factor, struct point *p)
Definition: navit.c:833
int navit_check_route(struct navit *this_)
Checks if a route is calculated.
Definition: navit.c:1792
int navit_set_vehicle_by_name(struct navit *n, const char *name)
Definition: navit.c:3692
void navit_remove_waypoint(struct navit *this_)
Definition: navit.c:1774
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:242
void navit_set_destinations(struct navit *this_, struct pcoord *c, int count, const char *description, int async)
Definition: navit.c:1703
void navit_remove_nth_waypoint(struct navit *this_, int n)
Definition: navit.c:1764
void navit_remove_callback(struct navit *this_, struct callback *cb)
Definition: navit.c:3200
struct navit * navit_new(struct attr *parent, struct attr **attrs)
Definition: navit.c:1477
void navit_add_message(struct navit *this_, const char *message)
Definition: navit.c:1556
void navit_set_destination(struct navit *this_, struct pcoord *c, const char *description, int async)
Definition: navit.c:1627
void navit_window_roadbook_new(struct navit *this_)
Definition: navit.c:2095
struct graphics * navit_get_graphics(struct navit *this_)
Definition: navit.c:1581
int navit_get_blocked(struct navit *this_)
Returns whether redraw operations are currently blocked.
Definition: navit.c:3788
struct tracking * navit_get_tracking(struct navit *this_)
Definition: navit.c:361
void navit_add_callback(struct navit *this_, struct callback *cb)
Definition: navit.c:3196
void navit_speak(struct navit *this_)
Definition: navit.c:1960
GList * navit_get_vehicleprofiles(struct navit *this_)
Definition: navit.c:1590
char * navit_get_user_data_directory(int create)
Get the user data directory.
Definition: navit.c:375
void navit_zoom_in_cursor(struct navit *this_, int factor)
Definition: navit.c:841
void navit_handle_motion(struct navit *this_, struct point *p)
Definition: navit.c:695
void navit_draw_async(struct navit *this_, int async)
Definition: navit.c:389
int navit_set_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:2792
int navit_get_destinations(struct navit *this_, struct pcoord *pc, int count)
Retrieves destinations from the route.
Definition: navit.c:1739
int navit_get_width(struct navit *this_)
Definition: navit.c:507
int navit_set_layout_by_name(struct navit *n, const char *name)
Definition: navit.c:3714
struct displaylist * navit_get_displaylist(struct navit *this_)
Definition: navit.c:3516
int navit_get_attr(struct navit *this_, enum attr_type type, struct attr *attr, struct attr_iter *iter)
Definition: navit.c:2796
void navit_draw(struct navit *this_)
Definition: navit.c:400
struct vehicleprofile * navit_get_vehicleprofile(struct navit *this_)
Definition: navit.c:1586
void navit_add_destination_description(struct navit *this_, struct pcoord *c, const char *description)
Definition: navit.c:1683
void navit_draw_displaylist(struct navit *this_)
Definition: navit.c:411
int navit_block(struct navit *this_, int block)
Blocks or unblocks redraw operations.
Definition: navit.c:3769
char * navit_get_destination_description(struct navit *this_, int n)
Definition: navit.c:1758
void navit_say(struct navit *this_, const char *text)
Definition: navit.c:1920
void navit_layout_switch(struct navit *n)
Definition: navit.c:3520
void navit_set_position(struct navit *this_, struct pcoord *c)
Definition: navit.c:3393
void navit_window_roadbook_destroy(struct navit *this_)
Definition: navit.c:2088
int navit_remove_attr(struct navit *this_, struct attr *attr)
Definition: navit.c:3171
struct layout * navit_get_layout_by_name(struct navit *this_, const char *layout_name)
Select the default layout by name.
Definition: navit.c:3020
unsigned char p[5]
Definition: mg.h:2
void navit_unref(struct navit *this_)
int navit_speech_estimate(struct navit *this_, char *str)
struct _GList GList
Definition: navit.h:30
char * navit_get_coord_description(struct navit *this_, struct pcoord *c)
struct navit * navit_ref(struct navit *this_)
int orientation
Definition: pedestrian.c:71
static struct pcoord c
Definition: popup.c:375
char name[0]
Definition: street.c:3
Definition: config_.c:47
void * iter
Definition: config_.c:48
Definition: attr.h:157
Definition: mg.h:33
Definition: callback.c:27
Definition: command.h:27
Definition: coord.h:58
Definition: graphics.c:120
graphics object A graphics object serves as the target for drawing operations. It encapsulates variou...
Definition: graphics.c:75
Definition: gui.c:30
Represents an object on a map.
Definition: item.h:115
Definition: layout.h:114
Definition: map.c:55
Definition: mapset.c:39
Definition: messages.h:25
Definition: navigation.c:161
Definition: navit.c:112
Definition: gpx2navit_txt.h:51
Definition: coord.h:52
Definition: point.h:23
A complete route.
Definition: route.c:201
Definition: track.c:84
The parameters needed to transform a map for display.
Definition: transform.c:64
Definition: vehicleprofile.h:33