impr: Better font loading logic

This commit is contained in:
WerWolv
2024-06-16 22:41:16 +02:00
parent deee76e455
commit f49715c7a0
8 changed files with 351 additions and 264 deletions

View File

@@ -6,11 +6,14 @@
#include <romfs/romfs.hpp>
namespace hex::fonts {
void loadFonts();
void registerFonts();
bool buildFontAtlas();
}
IMHEX_LIBRARY_SETUP("Fonts") {
hex::log::debug("Using romfs: '{}'", romfs::name());
hex::fonts::loadFonts();
hex::ImHexApi::System::addStartupTask("Loading fonts", true, hex::fonts::buildFontAtlas);
hex::fonts::registerFonts();
}