FcConfigGetFilename(3)

πŸ’– NAME πŸ’–

Okay bestie, welcome to the FcConfigGetFilename(3) page β€” manual name FcConfigGetFilename, section 3, and she's all about finding a config file πŸ”₯.

FcConfigGetFilename β€” find a config file πŸŽ€

✨ SYNOPSIS ✨

Include this, bestie:

#include <fontconfig/fontconfig.h>

FcChar8 * FcConfigGetFilename (FcConfig *config, const FcChar8 *name);

🌸 DESCRIPTION 🌸

Okay so picture this: you give this function the specified external entity name, and it returns the associated filename. It’s literally giving applications a way to convert various configuration file references into filename form. Slay πŸ”₯.

If name is null or empty, that means the default configuration file should be used. Which file that references can be overridden with the FONTCONFIG_FILE environment variable. Not me knowing all the env vars πŸ’….

Next up: if name starts with ~, it refers to a file in the current users home directory. Otherwise, if name doesn’t start with /, it refers to a file in the default configuration directory. The built-in default directory can be overridden with the FONTCONFIG_PATH environment variable. Periodt 🌈.

And heads up, bestie: the result of this function is affected by the FONTCONFIG_SYSROOT environment variable or equivalent functionality. Keep that in mind, iykyk 🫢.


Byeee bestie πŸ’– β€” this page is from Fontconfig 2.17.0, dated 27 June 2025. Mwah πŸ’‹

πŸ“¦ where this page comes from