]> git.itanic.dy.fi Git - maemo-mapper/blob - src/display.h
76973af9a22135281c9690de8a334e32711f93ad
[maemo-mapper] / src / display.h
1 /*
2  * Copyright (C) 2006, 2007 John Costigan.
3  *
4  * POI and GPS-Info code originally written by Cezary Jackiewicz.
5  *
6  * Default map data provided by http://www.openstreetmap.org/
7  *
8  * This file is part of Maemo Mapper.
9  *
10  * Maemo Mapper is free software: you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation, either version 3 of the License, or
13  * (at your option) any later version.
14  *
15  * Maemo Mapper is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with Maemo Mapper.  If not, see <http://www.gnu.org/licenses/>.
22  */
23
24 #ifndef MAEMO_MAPPER_DISPLAY_H
25 #define MAEMO_MAPPER_DISPLAY_H
26
27 typedef struct {
28     gdouble glat, glon;
29     GtkWidget *fmt_combo;
30     GtkWidget *lat;
31     GtkWidget *lon;
32 } LatlonDialog;
33
34
35 gboolean gps_display_details(void);
36 void gps_display_data(void);
37 void gps_hide_text(void);
38 void gps_show_info(void);
39 void gps_details(void);
40
41 void map_render_segment(GdkGC *gc_norm, GdkGC *gc_alt,
42         gint unitx1, gint unity1, gint unitx2, gint unity2);
43 void map_render_paths(void);
44
45 void update_gcs(void);
46
47 gboolean window_present(void);
48
49 void map_pan(gint delta_unitx, gint delta_unity);
50 void map_move_mark(void);
51 void map_refresh_mark(gboolean force_redraw);
52 void map_force_redraw(void);
53
54
55 void map_center_unit_full(Point new_center, gint zoom, gint rotate_angle);
56 void map_center_unit(Point new_center);
57 void map_rotate(gint rotate_angle);
58 void map_center_zoom(gint zoom);
59 Point map_calc_new_center(gint zoom);
60
61 gboolean map_download_refresh_idle(MapUpdateTask *mut);
62 void map_set_zoom(gint new_zoom);
63
64 gboolean thread_render_map(MapRenderTask *mrt);
65
66 gboolean map_cb_configure(GtkWidget *widget, GdkEventConfigure *event);
67 gboolean map_cb_expose(GtkWidget *widget, GdkEventExpose *event);
68
69 gboolean latlon_dialog(gdouble lat, gdouble lon);
70
71 gboolean display_open_file(GtkWindow *parent, gchar **bytes_out,
72         GnomeVFSHandle **handle_out, gint *size_out, gchar **dir, gchar **file,
73         GtkFileChooserAction chooser_action);
74
75 void display_init(void);
76
77 #endif /* ifndef MAEMO_MAPPER_DISPLAY_H */