navit 0.5.3-trunk
Loading...
Searching...
No Matches
graphics_qt5.h
Go to the documentation of this file.
1
20#ifndef __graphics_qt_h
21#define __graphics_qt_h
22
23#ifndef USE_QWIDGET
24#define USE_QWIDGET 1
25#endif
26
27#ifndef USE_QML
28#define USE_QML 0
29#endif
30
31#include <QBrush>
32#include <QGuiApplication>
33#include <QPainter>
34#include <QPen>
35#include <QPixmap>
36#include <glib.h>
37#if USE_QML
38#include <QObject>
39#include <QQmlApplicationEngine>
40#include <QQuickWindow>
41#endif
42#if USE_QWIDGET
43#include "QNavitWidget.h"
44#endif
45
46#ifndef HAVE_FREETYPE
47#define HAVE_FREETYPE 0
48#endif
49
50#ifndef SAILFISH_OS
51#define SAILFISH_OS 1
52#endif
53
54#if HAVE_FREETYPE
56#endif
57
58struct graphics_gc_priv;
59struct graphics_priv;
60
61#if USE_QML
62class GraphicsPriv : public QObject {
63 Q_OBJECT
64public:
65 GraphicsPriv(struct graphics_priv* gp);
66 ~GraphicsPriv();
67 void emit_update();
68
69 struct graphics_priv* gp;
70
71signals:
72 void update();
73};
74#endif
75
76struct graphics_priv {
77#if USE_QML
78 QQmlApplicationEngine* engine;
79 GraphicsPriv* GPriv;
80 QQuickWindow* window;
81#endif
82#if USE_QWIDGET
84#endif
85 QPixmap* pixmap;
86 QPainter* painter;
89 int x;
90 int y;
94#if HAVE_FREETYPE
95 struct font_priv* (*font_freetype_new)(void* meth);
97#endif
98#ifdef SAILFISH_OS
101#endif
103 GHashTable* overlays;
104 struct graphics_priv* parent;
105 bool root;
106 int argc;
107 char* argv[4];
108};
109
110struct graphics_gc_priv {
112 QPen* pen;
113 QBrush* brush;
114};
115/* central exported application info */
116extern QGuiApplication* navit_app;
117
118void resize_callback(struct graphics_priv* gr, int w, int h);
119
120#endif
Definition QNavitWidget.h:30
Interface to the FreeType 2 library, to render text as bitmaps.
QGuiApplication * navit_app
Definition graphics_qt5.cpp:79
void resize_callback(struct graphics_priv *gr, int w, int h)
Definition graphics_qt5.cpp:693
Definition callback.c:37
Definition callback.c:27
Definition event_glib.c:82
Definition font_freetype.h:36
Definition font_freetype.c:73
Definition graphics_android.c:76
QBrush * brush
Definition graphics_qt5.h:113
struct graphics_priv * graphics_priv
Definition graphics_qt5.h:111
QPen * pen
Definition graphics_qt5.h:112
Definition graphics_android.c:37
int disable
Definition graphics_qt5.h:88
int use_count
Definition graphics_qt5.h:87
int scroll_x
Definition graphics_qt5.h:91
char * argv[4]
Definition graphics_qt5.h:107
int h
Definition graphics_cocoa.m:69
struct font_freetype_methods freetype_methods
Definition graphics_egl.c:94
QPixmap * pixmap
Definition graphics_qt5.h:85
int argc
Definition graphics_qt5.h:106
struct window window
Definition graphics_egl.c:98
int scroll_y
Definition graphics_qt5.h:92
int x
Definition graphics_qt5.h:89
int w
Definition graphics_cocoa.m:69
QPainter * painter
Definition graphics_qt5.h:86
GHashTable * overlays
Definition graphics_qt5.h:103
struct callback_list * callbacks
Definition graphics_qt5.h:102
struct event_timeout * display_on_ev
Definition graphics_qt5.h:100
struct graphics_priv * parent
Definition graphics_cocoa.m:70
QNavitWidget * widget
Definition graphics_qt5.h:83
struct callback * display_on_cb
Definition graphics_qt5.h:99
bool root
Definition graphics_qt5.h:105
int y
Definition graphics_qt5.h:90
struct graphics_gc_priv * background_graphics_gc_priv
Definition graphics_qt5.h:93