From 81baeec59ba530c53f8db253bb0289825aef2f82 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 6 Nov 2021 16:26:09 +1100 Subject: Cleanup: remove window_manager & editor includes from BLF Remove the need to include the window manager & editor functions in low level font rendering code. - The default font size is now set when changed in the preferences. - Flushing cache is set as a callback. --- source/blender/blenfont/BLF_api.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source/blender/blenfont/BLF_api.h') diff --git a/source/blender/blenfont/BLF_api.h b/source/blender/blenfont/BLF_api.h index 78252bdb08b..217a4d5d918 100644 --- a/source/blender/blenfont/BLF_api.h +++ b/source/blender/blenfont/BLF_api.h @@ -43,6 +43,8 @@ void BLF_exit(void); void BLF_cache_clear(void); +void BLF_cache_flush_set_fn(void (*cache_flush_fn)(void)); + /* Loads a font, or returns an already loaded font and increments its reference count. */ int BLF_load(const char *name) ATTR_NONNULL(); int BLF_load_mem(const char *name, const unsigned char *mem, int mem_size) ATTR_NONNULL(); @@ -250,6 +252,7 @@ void BLF_thumb_preview(const char *filename, /* blf_default.c */ void BLF_default_dpi(int dpi); +void BLF_default_size(int size); void BLF_default_set(int fontid); int BLF_default(void); /* get default font ID so we can pass it to other functions */ /* Draw the string using the default font, size and dpi. */ -- cgit v1.2.3