1
1
Fork 0
mirror of https://github.com/QB64-Phoenix-Edition/QB64pe.git synced 2024-07-04 04:50:22 +00:00

Update func__loadfont() to use filepath_fix_directory()

This commit is contained in:
Samuel Gomes 2023-12-29 03:01:24 +05:30
parent 035a12e76e
commit d4437d1b32

View file

@ -24787,7 +24787,7 @@ int32_t func__loadfont(qbs *file_name, int32_t size, qbs *requirements, int32_t
FONT_DEBUG_PRINT("Loading font from memory. Size = %i", bytes);
} else {
qbs_set(fileNameZ, qbs_add(file_name, qbs_new_txt_len("\0", 1))); // s1 = filename + CHR$(0)
content = FontLoadFileToMemory((char *)fileNameZ->chr, &bytes); // this we must free!!!
content = FontLoadFileToMemory(filepath_fix_directory(fileNameZ), &bytes); // this we must free!!!
FONT_DEBUG_PRINT("Loading font from file %s", fileNameZ->chr);
}