| 3274 | } |
| 3275 | |
| 3276 | ImFont* ImFontAtlas::AddFontFromMemoryCompressedBase85TTF(const char* compressed_ttf_data_base85, float size_pixels, const ImFontConfig* font_cfg, const ImWchar* glyph_ranges) |
| 3277 | { |
| 3278 | int compressed_ttf_size = (((int)ImStrlen(compressed_ttf_data_base85) + 4) / 5) * 4; |
| 3279 | void* compressed_ttf = IM_ALLOC((size_t)compressed_ttf_size); |
| 3280 | Decode85((const unsigned char*)compressed_ttf_data_base85, (unsigned char*)compressed_ttf); |
| 3281 | ImFont* font = AddFontFromMemoryCompressedTTF(compressed_ttf, compressed_ttf_size, size_pixels, font_cfg, glyph_ranges); |
| 3282 | IM_FREE(compressed_ttf); |
| 3283 | return font; |
| 3284 | } |
| 3285 | |
| 3286 | // On font removal we need to remove references (otherwise we could queue removal?) |
| 3287 | // We allow old_font == new_font which forces updating all values (e.g. sizes) |
nothing calls this directly
no test coverage detected