summaryrefslogtreecommitdiffstats
path: root/minuitwrp/truetype.cpp
diff options
context:
space:
mode:
authorEthan Yonker <dees_troy@teamw.in>2018-08-24 18:17:36 +0200
committerEthan Yonker <dees_troy@teamw.in>2018-08-24 18:17:39 +0200
commit58f2132bc3954fc704787d477500a209eedb8e29 (patch)
treeeb0f79aacd68724b0c0c091018384ef924380f47 /minuitwrp/truetype.cpp
parentRemove remaining pieces of supersu (diff)
parentSnap for 4745538 from 723056a83f8c8b15af02d9c302862dbb2304ea8c to pi-release (diff)
downloadandroid_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.gz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.bz2
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.lz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.xz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.zst
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.zip
Diffstat (limited to 'minuitwrp/truetype.cpp')
-rw-r--r--minuitwrp/truetype.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/minuitwrp/truetype.cpp b/minuitwrp/truetype.cpp
index 18635a886..3e5f70719 100644
--- a/minuitwrp/truetype.cpp
+++ b/minuitwrp/truetype.cpp
@@ -461,7 +461,7 @@ static int gr_ttf_render_text(TrueTypeFont *font, GGLSurface *surface, const cha
int utf_bytes = 0;
unsigned int unicode = 0;
int i, x, diff, char_idx, prev_idx = 0;
- int height, base;
+ int height;
FT_Vector delta;
uint8_t *data = NULL;
const char *text_itr = text;
@@ -547,7 +547,6 @@ static int gr_ttf_render_text(TrueTypeFont *font, GGLSurface *surface, const cha
static StringCacheEntry *gr_ttf_string_cache_peek(TrueTypeFont *font, const char *text, int max_width)
{
- StringCacheEntry *res;
StringCacheKey k = {
.text = (char*)text,
.max_width = max_width
@@ -785,8 +784,8 @@ static bool gr_ttf_dump_stats_font(void *key, void *value, void *context)
" refcount: %d\n"
" max_height: %d\n"
" base: %d\n"
- " glyph_cache: %d entries\n"
- " string_cache: %d entries (%.2f kB)\n",
+ " glyph_cache: %zu entries\n"
+ " string_cache: %zu entries (%.2f kB)\n",
k->path, k->size, k->dpi,
f->refcount, f->max_height, f->base,
hashmapSize(f->glyph_cache),
@@ -808,7 +807,7 @@ void gr_ttf_dump_stats(void)
else
{
int total_string_cache_size = 0;
- printf("%d fonts loaded.\n", hashmapSize(font_data.fonts));
+ printf("%zu fonts loaded.\n", hashmapSize(font_data.fonts));
hashmapForEach(font_data.fonts, gr_ttf_dump_stats_font, &total_string_cache_size);
printf(" Total string cache size: %.2f kB\n", ((double)total_string_cache_size)/1024);
}