navit
0.5.3-trunk
|
#include "config.h"
#include <stdlib.h>
#include <signal.h>
#include <sys/time.h>
#include <math.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include <cairo.h>
#include <locale.h>
#include <X11/XF86keysym.h>
#include <gdk/gdkx.h>
#include "event.h"
#include "debug.h"
#include "point.h"
#include "graphics.h"
#include "color.h"
#include "item.h"
#include "window.h"
#include "callback.h"
#include "keys.h"
#include "plugin.h"
#include "navit/font/freetype/font_freetype.h"
#include "navit.h"
#include <errno.h>
Data Structures | |
struct | graphics_priv |
struct | graphics_gc_priv |
struct | graphics_image_priv |
Macros | |
#define | GDK_ENABLE_BROKEN |
#define | GDK_KEY_Book XF86XK_Book |
#define | GDK_KEY_Calendar XF86XK_Calendar |
Functions | |
static void | set_drawing_color (cairo_t *cairo, struct color c) |
static void | graphics_destroy (struct graphics_priv *gr) |
static void | gc_destroy (struct graphics_gc_priv *gc) |
static void | gc_set_linewidth (struct graphics_gc_priv *gc, int w) |
static void | gc_set_dashes (struct graphics_gc_priv *gc, int w, int offset, unsigned char *dash_list, int n) |
static void | gc_set_foreground (struct graphics_gc_priv *gc, struct color *c) |
static void | gc_set_background (struct graphics_gc_priv *gc, struct color *c) |
static void | gc_set_texture (struct graphics_gc_priv *gc, struct graphics_image_priv *img) |
static struct graphics_gc_priv * | gc_new (struct graphics_priv *gr, struct graphics_gc_methods *meth) |
static struct graphics_image_priv * | image_new (struct graphics_priv *gr, struct graphics_image_methods *meth, char *name, int *w, int *h, struct point *hot, int rotation) |
static void | image_free (struct graphics_priv *gr, struct graphics_image_priv *priv) |
static void | set_stroke_params_from_gc (cairo_t *cairo, struct graphics_gc_priv *gc) |
static void | draw_lines (struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int count) |
static void | draw_polygon (struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int count) |
static void | draw_polygon_with_holes (struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int count, int hole_count, int *ccount, struct point **holes) |
static void | draw_rectangle (struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int w, int h) |
static void | draw_circle (struct graphics_priv *gr, struct graphics_gc_priv *gc, struct point *p, int r) |
static void | draw_rgb_image_buffer (cairo_t *cairo, int buffer_width, int buffer_height, int draw_pos_x, int draw_pos_y, int stride, unsigned char *buffer) |
static void | display_text_draw (struct font_freetype_text *text, struct graphics_priv *gr, struct graphics_gc_priv *fg, struct graphics_gc_priv *bg, struct point *p) |
static void | draw_text (struct graphics_priv *gr, struct graphics_gc_priv *fg, struct graphics_gc_priv *bg, struct graphics_font_priv *font, char *text, struct point *p, int dx, int dy) |
static void | draw_image (struct graphics_priv *gr, struct graphics_gc_priv *fg, struct point *p, struct graphics_image_priv *img) |
static void | overlay_rect (struct graphics_priv *parent, struct graphics_priv *overlay, GdkRectangle *r) |
static void | overlay_draw (struct graphics_priv *parent, struct graphics_priv *overlay, GdkRectangle *re, cairo_t *cairo) |
static void | draw_drag (struct graphics_priv *gr, struct point *p) |
static void | background_gc (struct graphics_priv *gr, struct graphics_gc_priv *gc) |
static void | draw_mode (struct graphics_priv *gr, enum draw_mode_num mode) |
static gint | configure (GtkWidget *widget, GdkEventConfigure *event, gpointer user_data) |
static gint | expose (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) |
static int | tv_delta (struct timeval *old, struct timeval *new) |
static gint | button_press (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
static gint | button_release (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
static gint | scroll (GtkWidget *widget, GdkEventScroll *event, gpointer user_data) |
static gint | motion_notify (GtkWidget *widget, GdkEventMotion *event, gpointer user_data) |
static gint | delete (GtkWidget *widget, GdkEventKey *event, gpointer user_data) |
static gint | keypress (GtkWidget *widget, GdkEventKey *event, gpointer user_data) |
static struct graphics_priv * | graphics_gtk_drawing_area_new_helper (struct graphics_methods *meth) |
static void | overlay_disable (struct graphics_priv *gr, int disabled) |
static void | overlay_resize (struct graphics_priv *this, struct point *p, int w, int h, int wraparound) |
static void | get_data_window (struct graphics_priv *this, unsigned int xid) |
static int | set_attr (struct graphics_priv *gr, struct attr *attr) |
static struct graphics_priv * | overlay_new (struct graphics_priv *gr, struct graphics_methods *meth, struct point *p, int w, int h, int wraparound) |
static int | graphics_gtk_drawing_area_fullscreen (struct window *w, int on) |
static void | graphics_gtk_drawing_area_disable_suspend (struct window *w) |
static void * | get_data (struct graphics_priv *this, char const *type) |
static navit_float | get_dpi (struct graphics_priv *gr) |
Return number of dots per inch. More... | |
static struct graphics_priv * | graphics_gtk_drawing_area_new (struct navit *nav, struct graphics_methods *meth, struct attr **attrs, struct callback_list *cbl) |
void | plugin_init (void) |
Variables | |
static struct graphics_gc_methods | gc_methods |
static int | gtk_argc |
static char ** | gtk_argv = {NULL} |
static struct graphics_methods | graphics_methods |
#define GDK_ENABLE_BROKEN |
Navit, a modular navigation system. Copyright (C) 2005-2008 Navit Team
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#define GDK_KEY_Book XF86XK_Book |
#define GDK_KEY_Calendar XF86XK_Calendar |
|
static |
References graphics_priv::background_gc.
Referenced by expose().
|
static |
References button_release(), callback_list_call_attr_3, cbl, p, tv_delta(), and point::x.
Referenced by button_release(), and graphics_gtk_drawing_area_new().
|
static |
References button_press(), callback_list_call_attr_3, cbl, p, tv_delta(), and point::x.
Referenced by button_press(), and graphics_gtk_drawing_area_new().
|
static |
References graphics_priv::cairo, callback_list_call_attr_2, graphics_priv::cbl, dbg, graphics_priv::height, lvl_debug, graphics_priv::visible, and graphics_priv::width.
Referenced by expose(), and graphics_gtk_drawing_area_new().
|
static |
References callback_list_call_attr_0, cbl, dbg, graphics_priv::delay, lvl_debug, and graphics_priv::win.
|
static |
|
static |
References graphics_priv::cairo, M_PI, p, and set_stroke_params_from_gc().
|
static |
References graphics_priv::p, p, point::x, and point::y.
|
static |
References graphics_priv::cairo, p, and graphics_image_priv::pixbuf.
|
static |
References graphics_priv::cairo, p, and set_stroke_params_from_gc().
|
static |
References draw_mode_end, and graphics_priv::widget.
|
static |
References graphics_gc_priv::c, graphics_priv::cairo, p, set_drawing_color(), and graphics_gc_priv::texture.
|
static |
References graphics_gc_priv::c, graphics_priv::cairo, p, set_drawing_color(), graphics_gc_priv::texture, point::x, and point::y.
|
static |
References graphics_gc_priv::c, graphics_priv::cairo, graphics_image_priv::h, p, set_drawing_color(), and graphics_image_priv::w.
|
static |
Referenced by display_text_draw().
|
static |
|
static |
References graphics_priv::background_gc, background_gc(), graphics_priv::cairo, configure(), graphics_gc_priv::gra, graphics_priv::overlay, overlay_draw(), graphics_priv::overlays, graphics_priv::p, set_drawing_color(), graphics_priv::visible, point::x, and point::y.
Referenced by graphics_gtk_drawing_area_new(), and NPP_HandleEvent().
|
static |
References graphics_gc_priv::texture.
|
static |
|
static |
|
static |
References graphics_gc_priv::dashes, graphics_gc_priv::ndashes, graphics_gc_priv::offset, and offset.
|
static |
References graphics_gc_priv::c, and c.
|
static |
References graphics_gc_priv::linewidth.
|
static |
|
static |
References dbg, graphics_priv::delay, window::disable_suspend, window::fullscreen, get_data_window(), graphics_gtk_drawing_area_disable_suspend(), graphics_gtk_drawing_area_fullscreen(), lvl_debug, lvl_warning, graphics_priv::pid, window::priv, type, graphics_priv::widget, graphics_priv::win, and graphics_priv::window.
|
static |
References dbg, keypress(), lvl_debug, graphics_priv::win, graphics_priv::win_h, graphics_priv::win_w, and graphics_priv::window_title.
Referenced by get_data(), and set_attr().
|
static |
Return number of dots per inch.
gr | self handle |
References graphics_priv::screen, and graphics_priv::widget.
|
static |
|
static |
References dbg, lvl_warning, graphics_priv::pid, and graphics_priv::w.
Referenced by get_data().
|
static |
References graphics_priv::w, and graphics_priv::win.
Referenced by get_data().
|
static |
References attr_search(), button_press(), button_release(), cbl, configure(), graphics_priv::delay, event_request_system(), expose(), graphics_gtk_drawing_area_new_helper(), motion_notify(), graphics_priv::nav, attr::num, scroll(), attr::str, graphics_priv::timeout, attr::u, graphics_priv::win_h, graphics_priv::win_w, and graphics_priv::window_title.
Referenced by plugin_init().
|
static |
References font_freetype_new(), graphics_methods::font_new, graphics_priv::freetype_methods, graphics_methods::get_text_bbox, and graphics_methods.
Referenced by graphics_gtk_drawing_area_new(), and overlay_new().
|
static |
References graphics_image_priv::pixbuf.
|
static |
|
static |
References callback_list_call_attr_1, cbl, dbg, GDK_KEY_Book, GDK_KEY_Calendar, key, lvl_debug, NAVIT_KEY_BACK, NAVIT_KEY_BACKSPACE, NAVIT_KEY_DELETE, NAVIT_KEY_DOWN, NAVIT_KEY_LEFT, NAVIT_KEY_PAGE_DOWN, NAVIT_KEY_PAGE_UP, NAVIT_KEY_RETURN, NAVIT_KEY_RIGHT, NAVIT_KEY_UP, NAVIT_KEY_ZOOM_IN, and NAVIT_KEY_ZOOM_OUT.
Referenced by get_data_window(), and graphics_opengl_set_callbacks().
|
static |
References callback_list_call_attr_1, cbl, and p.
Referenced by graphics_gtk_drawing_area_new().
|
static |
|
static |
References graphics_priv::cairo, graphics_priv::overlay_autodisabled, graphics_priv::overlay_disabled, and overlay_rect().
Referenced by expose().
|
static |
|
static |
References graphics_priv::height, graphics_priv::p, graphics_priv::width, graphics_priv::wraparound, point::x, and point::y.
Referenced by overlay_disable(), and overlay_draw().
|
static |
void plugin_init | ( | void | ) |
References graphics_gtk_drawing_area_new(), gtk_argc, and gtk_argv.
|
static |
References callback_list_call_attr_3, cbl, and p.
Referenced by graphics_gtk_drawing_area_new().
|
static |
References dbg, get_data_window(), lvl_debug, attr::num, attr::type, and attr::u.
|
static |
References c, and COLOR_BITDEPTH.
Referenced by draw_polygon(), draw_polygon_with_holes(), draw_rectangle(), expose(), and set_stroke_params_from_gc().
|
static |
References graphics_gc_priv::c, graphics_gc_priv::dashes, graphics_gc_priv::linewidth, graphics_gc_priv::ndashes, graphics_gc_priv::offset, and set_drawing_color().
Referenced by draw_circle(), and draw_lines().
|
static |
Referenced by button_press(), and button_release().
|
static |
Referenced by gc_new().
|
static |
Referenced by graphics_gtk_drawing_area_new_helper().
|
static |
Referenced by plugin_init().
|
static |
Referenced by plugin_init().