Closed codecat closed 3 years ago
I have also removed the lambda's creating the config structures as well as the static variables intended to keep the config structures in memory as it doesn't appear to be necessary.
You are right, thanks for pointing this out! I now remember I had an issue with the glyph_range
param of AddFontFromMemoryTTF, not with the config in itself.
Your PR looks good to me, and brings value!
Are you OK to merge?
Ah good point, I didn't see that one! I kept those arrays static however, so the PR should still be correct. If all looks okay to you, I'm ok to merge!
This is in response to #12.
There is now an added
ImFontConfig config
parameters to all font loading functions, which serves as a "template" for the actual config (much like how imgui does it internally too). I've also exposedMergeFontAwesomeToLastFont
so that it's easier to use a different configuration (and size) for both icon font & regular font.Example usage:
I have also removed the lambda's creating the config structures as well as the static variables intended to keep the config structures in memory as it doesn't appear to be necessary.