diff options
author | Harley Acheson <harley.acheson@gmail.com> | 2021-08-25 23:30:00 +0300 |
---|---|---|
committer | Harley Acheson <harley.acheson@gmail.com> | 2021-08-25 23:30:00 +0300 |
commit | 5b751c95f4e58c5f56b1af61c835b4537f19f43c (patch) | |
tree | 139e884c0d42c20af4394c893a3e8d5904371e9b /source/blender/draw/intern/draw_manager_text.c | |
parent | 518b97e674a9e7cdc91bc4048a89eb8a8b37db0b (diff) |
BLF: Remove ASCII-only Code Paths
Remove redundant code for drawing text strings that contain only ASCII.
See D12293 for much more detail.
Differential Revision: https://developer.blender.org/D12293
Reviewed by Campbell Barton
Diffstat (limited to 'source/blender/draw/intern/draw_manager_text.c')
-rw-r--r-- | source/blender/draw/intern/draw_manager_text.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/source/blender/draw/intern/draw_manager_text.c b/source/blender/draw/intern/draw_manager_text.c index 265fdba66fd..cfaa22ba7c6 100644 --- a/source/blender/draw/intern/draw_manager_text.c +++ b/source/blender/draw/intern/draw_manager_text.c @@ -152,11 +152,9 @@ static void drw_text_cache_draw_ex(DRWTextStore *dt, ARegion *region) BLF_position( font_id, (float)(vos->sco[0] + vos->xoffs), (float)(vos->sco[1] + vos->yoffs), 2.0f); - - ((vos->flag & DRW_TEXT_CACHE_ASCII) ? BLF_draw_ascii : BLF_draw)( - font_id, - (vos->flag & DRW_TEXT_CACHE_STRING_PTR) ? *((const char **)vos->str) : vos->str, - vos->str_len); + BLF_draw(font_id, + (vos->flag & DRW_TEXT_CACHE_STRING_PTR) ? *((const char **)vos->str) : vos->str, + vos->str_len); } } @@ -235,7 +233,7 @@ void DRW_text_edit_mesh_measure_stats(ARegion *region, * etc.). See bug T36090. */ struct DRWTextStore *dt = DRW_text_cache_ensure(); - const short txt_flag = DRW_TEXT_CACHE_GLOBALSPACE | (unit->system ? 0 : DRW_TEXT_CACHE_ASCII); + const short txt_flag = DRW_TEXT_CACHE_GLOBALSPACE; Mesh *me = ob->data; BMEditMesh *em = me->edit_mesh; float v1[3], v2[3], v3[3], vmid[3], fvec[3]; |