Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenfont')
-rw-r--r--source/blender/blenfont/intern/blf_font.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/blenfont/intern/blf_font.c b/source/blender/blenfont/intern/blf_font.c
index 07e568dd279..cc7eb336b21 100644
--- a/source/blender/blenfont/intern/blf_font.c
+++ b/source/blender/blenfont/intern/blf_font.c
@@ -58,6 +58,8 @@
#include "BIF_gl.h"
#include "BLF_api.h"
+#include "UI_interface.h"
+
#include "GPU_immediate.h"
#include "GPU_matrix.h"
#include "GPU_batch.h"
@@ -184,6 +186,9 @@ void blf_batch_draw(void)
glEnable(GL_BLEND);
glBlendFuncSeparate(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA, GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
+ /* We need to flush widget base first to ensure correct ordering. */
+ UI_widgetbase_draw_cache_flush();
+
BLI_assert(g_batch.font->tex_bind_state != 0); /* must still be valid */
glActiveTexture(GL_TEXTURE0);
glBindTexture(GL_TEXTURE_2D, g_batch.font->tex_bind_state);