ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/defaultfont.C
(Generate patch)

Comparing rxvt-unicode/src/defaultfont.C (file contents):
Revision 1.57 by root, Wed Aug 11 01:36:51 2004 UTC vs.
Revision 1.58 by root, Wed Aug 11 03:51:32 2004 UTC

1213 fonts.push_back (new_font (fallback->name, fallback->cs)); 1213 fonts.push_back (new_font (fallback->name, fallback->cs));
1214 fallback++; 1214 fallback++;
1215 } 1215 }
1216 else 1216 else
1217 { 1217 {
1218 // try to find a new font 1218 // try to find a new font.
1219 // only xft currently supported, as there is no 1219 // only xft currently supported, as there is no
1220 // way to configure this and xft is easier to hack in, 1220 // way to configure this and xft is easier to hack in,
1221 // while x11 has more framework in place already. 1221 // while x11 has more framework in place already.
1222#if XFT 1222#if XFT
1223 // grab the first xft font that is suitable 1223 // grab the first xft font that seems suitable
1224 FcPattern *p = FcPatternCreate (); 1224 FcPattern *p = FcPatternCreate ();
1225 1225
1226 FcCharSet *s = FcCharSetCreate (); 1226 FcCharSet *s = FcCharSetCreate ();
1227 FcCharSetAddChar (s, unicode); 1227 FcCharSetAddChar (s, unicode);
1228 FcPatternAddCharSet (p, FC_CHARSET, s); 1228 FcPatternAddCharSet (p, FC_CHARSET, s);
1229 // charsets don't help that much, as xft might return
1230 // a non-matching font even if a better font is available :/
1229 1231
1230 FcPatternAddInteger (p, FC_PIXEL_SIZE, base_prop.height); 1232 FcPatternAddInteger (p, FC_PIXEL_SIZE, base_prop.height);
1231 FcPatternAddInteger (p, FC_WEIGHT, base_prop.weight); 1233 FcPatternAddInteger (p, FC_WEIGHT, base_prop.weight);
1232 FcPatternAddInteger (p, FC_SLANT, base_prop.slant); 1234 FcPatternAddInteger (p, FC_SLANT, base_prop.slant);
1233 1235

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines