From 6bc6c0cca6c105450f7cc6f080c72d99f87c173f Mon Sep 17 00:00:00 2001 From: Stefan Wildemann Date: Sun, 28 Jul 2019 12:29:58 +0200 Subject: add:graphics:dpi scaling support (#813) This commit adds calculating a scaling factor out of the virtual_dpi assumed when the layout was created, and the real_dpi value of the hardware. It is activated if "virtual_dpi" tag is set into the "graphics" tag on navit.xml. Currently only qt5 graphics implment returning the hardware dpi. But this can be simulated and overwritten by setting "real_dpi" tag to "graphics" tag on navit.xm on all available graphics.l --- navit/callback.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'navit/callback.h') diff --git a/navit/callback.h b/navit/callback.h index b0f4b9f81..c45735280 100644 --- a/navit/callback.h +++ b/navit/callback.h @@ -30,6 +30,7 @@ extern "C" { enum attr_type; struct callback; struct callback_list; +typedef void (*callback_patch) (struct callback_list *l, enum attr_type type, int pcount, void **p, void * context); struct callback_list *callback_list_new(void); struct callback *callback_new_attr(void (*func)(void), enum attr_type type, int pcount, void **p); struct callback *callback_new_attr_args(void (*func)(void), enum attr_type type, int count, ...); @@ -41,6 +42,7 @@ void callback_list_add(struct callback_list *l, struct callback *cb); struct callback *callback_list_add_new(struct callback_list *l, void (*func)(void), int pcount, void **p); void callback_list_remove(struct callback_list *l, struct callback *cb); void callback_list_remove_destroy(struct callback_list *l, struct callback *cb); +void callback_list_add_patch_function (struct callback_list *l, callback_patch patch, void * context); void callback_call(struct callback *cb, int pcount, void **p); void callback_call_args(struct callback *cb, int count, ...); void callback_list_call_attr(struct callback_list *l, enum attr_type type, int pcount, void **p); -- cgit v1.2.1