Closed codeman38 closed 1 year ago
I can confirm that the change in the above-linked pull request fixes this for me; after recompiling with the change, the "select font from file" option actually uses the selected font file now, when it didn't before.
The "select font from file" option in the configuration window is a complete no-op because of conflicting conditionals on what FC_VERSION is supported.
In line 278 of text-pango.c https://github.com/kkartaltepe/obs-text-pango/blob/8f4775d629624ea450474e39a4e7143166d8aeba/text-pango.c#L278 the "select font from file" option is hidden from the UI if FC_VERSION \< 21291. This is reasonable, as older fontconfig versions don't support the necessary API calls for this.
However, given that, the conditional in line 33 of text-utilities.h https://github.com/kkartaltepe/obs-text-pango/blob/8f4775d629624ea450474e39a4e7143166d8aeba/text-utilities.h#L33 is backwards! This code should only run if FC_VERSION >= 21291.