From 12a4ed383f21b65a5a244f47fe1bc9f13d4f63bb Mon Sep 17 00:00:00 2001 From: Jens Arnold Date: Mon, 25 Jul 2005 19:56:35 +0000 Subject: [PATCH] Added font_getstringsize to the plugin api, needed for the reworked grayscale library. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7240 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugin.c | 3 +++ apps/plugin.h | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/apps/plugin.c b/apps/plugin.c index 6df7621203..7bfa0e2a0f 100644 --- a/apps/plugin.c +++ b/apps/plugin.c @@ -341,6 +341,9 @@ static const struct plugin_api rockbox_api = { lcd_bitmap_part, lcd_bitmap, #endif +#ifdef HAVE_LCD_BITMAP + font_getstringsize, +#endif }; int plugin_load(const char* plugin, void* parameter) diff --git a/apps/plugin.h b/apps/plugin.h index 801c49e0f1..f504bacf22 100644 --- a/apps/plugin.h +++ b/apps/plugin.h @@ -87,7 +87,7 @@ #endif /* increase this every time the api struct changes */ -#define PLUGIN_API_VERSION 45 +#define PLUGIN_API_VERSION 46 /* update this to latest version if a change to the api struct breaks backwards compatibility (and please take the opportunity to sort in any @@ -419,6 +419,10 @@ struct plugin_api { void (*lcd_bitmap)(const unsigned char *src, int x, int y, int width, int height); #endif +#ifdef HAVE_LCD_BITMAP + int (*font_getstringsize)(const unsigned char *str, int *w, int *h, + int fontnumber); +#endif }; int plugin_load(const char* plugin, void* parameter);