On ?ro 16. lipca 2003 19:25, Tomasz Grobelny wrote: > On ?ro 16. lipca 2003 14:51, Tomasz Grobelny wrote: > > value.type=FcTypeString; > > value.u.s=_family.ascii(); > > FcPatternAdd(pat, FC_FAMILY, value, true); > > This certainly could be done better: I've just discovered FcPatterAdd<Type> > Now the code looks like this: pat=FcPatternCreate(); FcPatternAddString(pat, FC_FAMILY, _family.ascii()); FcPatternAddBool(pat, FC_SCALABLE, FcTrue); FcPatternAddBool(pat, FC_OUTLINE, FcTrue); FcPatternAddInteger(pat, FC_WEIGHT, _weight); FcPatternAddInteger(pat, FC_SLANT, _slant); FcPatternAddDouble(pat, FC_SIZE, _size); FcDefaultSubstitute(pat); FcConfigSubstitute(FcConfigGetCurrent(), pat, FcMatchPattern); FcResult result; font=FcFontMatch(FcConfigGetCurrent(), pat, &result); FcValue v; FcPatternGet(font, FC_FILE, 0, &v); cout<<v.u.s<<endl; But the output is (for "Times"): /usr/share/fonts/75dpi/timR24.pcf.gz so it is a non scalable, non outline font (I was requesting quite the opposite). Why is that so? Tomek