LINUX.ORG.RU
Ответ на: комментарий от inn
*@*:~$ fc-list -v | grep Ubuntu
	family: "Ubuntu Condensed"(s)
	fullname: "Ubuntu Condensed"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-C.ttf"(s)
	family: "Ubuntu"(s)
	fullname: "Ubuntu"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-R.ttf"(s)
	family: "Ubuntu"(s)
	fullname: "Ubuntu Bold"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-B.ttf"(s)
	family: "Ubuntu Mono"(s)
	fullname: "Ubuntu Mono Italic"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/UbuntuMono-RI.ttf"(s)
	family: "Ubuntu Mono"(s)
	fullname: "Ubuntu Mono Bold Italic"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/UbuntuMono-BI.ttf"(s)
	family: "Ubuntu"(s)
	fullname: "Ubuntu Italic"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-RI.ttf"(s)
	family: "Ubuntu Mono"(s)
	fullname: "Ubuntu Mono"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/UbuntuMono-R.ttf"(s)
	family: "Ubuntu"(s) "Ubuntu Light"(s)
	fullname: "Ubuntu Light Italic"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-LI.ttf"(s)
	family: "Ubuntu Mono"(s)
	fullname: "Ubuntu Mono Bold"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/UbuntuMono-B.ttf"(s)
	family: "Ubuntu"(s) "Ubuntu Light"(s)
	fullname: "Ubuntu Light"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-L.ttf"(s)
	family: "Ubuntu"(s)
	fullname: "Ubuntu Bold Italic"(s)
	file: "/usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-BI.ttf"(s)
Deleted
()
#include <stdio.h>
#include <fontconfig/fontconfig.h>

int main() {
        FcPattern *pattern = FcPatternBuild(NULL, FC_FONTFORMAT, FcTypeString, "TrueType", FC_FULLNAME, FcTypeString, "Verdana", (char *)0);
        FcObjectSet *objset = FcObjectSetBuild("file", (char *)0);
        FcFontSet *set = FcFontList(NULL, pattern, objset);

        for (int i = 0; i < set->nfont; i++) {
                FcPattern *font = set->fonts[i];
                unsigned char *file;
                FcPatternGetString(font, "file", 0, &file);
		printf("file: %s\n", file);
        }

        FcFontSetDestroy(set);
        FcObjectSetDestroy(objset);
        FcPatternDestroy(pattern);
}
AptGet ★★★
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.