Fix:map_csv:Disable default notification of each deleted item.
[profile/ivi/navit.git] / navit / navit / navit.h
1 /**
2  * Navit, a modular navigation system.
3  * Copyright (C) 2005-2008 Navit Team
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public License
7  * version 2 as published by the Free Software Foundation.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU Library General Public License for more details.
13  *
14  * You should have received a copy of the GNU Library General Public
15  * License along with this program; if not, write to the
16  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  * Boston, MA  02110-1301, USA.
18  */
19
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 mapset;
43 struct message;
44 struct navigation;
45 struct navit;
46 struct pcoord;
47 struct point;
48 struct route;
49 struct tracking;
50 struct transformation;
51 struct vehicleprofile;
52 struct command_table;
53 struct item;
54 void navit_add_mapset(struct navit *this_, struct mapset *ms);
55 struct mapset *navit_get_mapset(struct navit *this_);
56 struct tracking *navit_get_tracking(struct navit *this_);
57 char *navit_get_user_data_directory(int create);
58 void navit_draw_async(struct navit *this_, int async);
59 void navit_draw(struct navit *this_);
60 int navit_get_ready(struct navit *this_);
61 void navit_draw_displaylist(struct navit *this_);
62 void navit_handle_resize(struct navit *this_, int w, int h);
63 int navit_get_width(struct navit *this_);
64 int navit_get_height(struct navit *this_);
65 int navit_ignore_button(struct navit *this_);
66 void navit_ignore_graphics_events(struct navit *this_, int ignore);
67 void navit_set_timeout(struct navit *this_);
68 int navit_handle_button(struct navit *this_, int pressed, int button, struct point *p, struct callback *popup_callback);
69 void navit_handle_motion(struct navit *this_, struct point *p);
70 void navit_zoom_in(struct navit *this_, int factor, struct point *p);
71 void navit_zoom_out(struct navit *this_, int factor, struct point *p);
72 void navit_zoom_in_cursor(struct navit *this_, int factor);
73 void navit_zoom_out_cursor(struct navit *this_, int factor);
74 struct navit *navit_new(struct attr *parent, struct attr **attrs);
75 void navit_add_message(struct navit *this_, char *message);
76 struct message *navit_get_messages(struct navit *this_);
77 struct graphics *navit_get_graphics(struct navit *this_);
78 struct vehicleprofile *navit_get_vehicleprofile(struct navit *this_);
79 GList *navit_get_vehicleprofiles(struct navit *this_);
80 void navit_set_destination(struct navit *this_, struct pcoord *c, const char *description, int async);
81 void navit_set_destinations(struct navit *this_, struct pcoord *c, int count, const char *description, int async);
82 int navit_get_destinations(struct navit *this_, struct pcoord *pc, int count);
83 int navit_get_destination_count(struct navit *this_);
84 char* navit_get_destination_description(struct navit *this_, int n);
85 void navit_remove_nth_waypoint(struct navit *this_, int n);
86 void navit_remove_waypoint(struct navit *this_);
87 char* navit_get_coord_description(struct navit *this_, struct pcoord *c);
88 int navit_check_route(struct navit *this_);
89 struct map* read_former_destinations_from_file(void);
90 void navit_textfile_debug_log(struct navit *this_, const char *fmt, ...);
91 void navit_textfile_debug_log_at(struct navit *this_, struct pcoord *pc, const char *fmt, ...);
92 int navit_speech_estimate(struct navit *this_, char *str);
93 void navit_say(struct navit *this_, char *text);
94 void navit_speak(struct navit *this_);
95 void navit_window_roadbook_destroy(struct navit *this_);
96 void navit_window_roadbook_new(struct navit *this_);
97 void navit_init(struct navit *this_);
98 void navit_zoom_to_rect(struct navit *this_, struct coord_rect *r);
99 void navit_zoom_to_route(struct navit *this_, int orientation);
100 void navit_set_center(struct navit *this_, struct pcoord *center, int set_timeout);
101 void navit_set_center_cursor(struct navit *this_, int autozoom, int keep_orientation);
102 void navit_set_center_screen(struct navit *this_, struct point *p, int set_timeout);
103 int navit_set_attr(struct navit *this_, struct attr *attr);
104 int navit_get_attr(struct navit *this_, enum attr_type type, struct attr *attr, struct attr_iter *iter);
105 int navit_add_attr(struct navit *this_, struct attr *attr);
106 int navit_remove_attr(struct navit *this_, struct attr *attr);
107 struct attr_iter *navit_attr_iter_new(void);
108 void navit_attr_iter_destroy(struct attr_iter *iter);
109 void navit_add_callback(struct navit *this_, struct callback *cb);
110 void navit_remove_callback(struct navit *this_, struct callback *cb);
111 void navit_set_position(struct navit *this_, struct pcoord *c);
112 struct gui *navit_get_gui(struct navit *this_);
113 struct transformation *navit_get_trans(struct navit *this_);
114 struct route *navit_get_route(struct navit *this_);
115 struct navigation *navit_get_navigation(struct navit *this_);
116 struct displaylist *navit_get_displaylist(struct navit *this_);
117 void navit_layout_switch(struct navit *n);
118 int navit_set_vehicle_by_name(struct navit *n, const char *name);
119 int navit_set_layout_by_name(struct navit *n, const char *name);
120 void navit_disable_suspend(void);
121 int navit_block(struct navit *this_, int block);
122 void navit_destroy(struct navit *this_);
123 void navit_command_add_table(struct navit*this_, struct command_table *commands, int count);
124 struct navit * navit_ref(struct navit *this_);
125 void navit_unref(struct navit *this_);
126 /* end of prototypes */
127 #ifdef __cplusplus
128 }
129 #endif
130
131 #endif
132