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

Comparing rxvt-unicode/src/rxvtfont.C (file contents):
Revision 1.193 by sf-exg, Fri Nov 7 13:45:55 2014 UTC vs.
Revision 1.197 by root, Mon Jan 20 09:35:17 2020 UTC

239 else if (color >= 0) 239 else if (color >= 0)
240 { 240 {
241#if XFT 241#if XFT
242 Picture dst; 242 Picture dst;
243 243
244# ifdef HAVE_BG_PIXMAP 244# ifdef HAVE_IMG
245 if (term->bg_img 245 if (term->bg_img
246 && !term->pix_colors[color].is_opaque () 246 && !term->pix_colors[color].is_opaque ()
247 && ((dst = XftDrawPicture (d)))) 247 && ((dst = XftDrawPicture (d))))
248 { 248 {
249 XClearArea (disp, d, x, y, w, h, false); 249 XClearArea (disp, d, x, y, w, h, false);
1045 dTermDisplay; 1045 dTermDisplay;
1046 dTermGC; 1046 dTermGC;
1047 1047
1048 bool slow = this->slow 1048 bool slow = this->slow
1049 || width != term->fwidth 1049 || width != term->fwidth
1050 || height != term->fheight; 1050 || height != term->fheight
1051 || ascent != f->ascent;
1051 1052
1052 int base = ascent; // sorry, incorrect: term->fbase; 1053 int base = ascent; // sorry, incorrect: term->fbase;
1053 1054
1054 XGCValues v; 1055 XGCValues v;
1055 v.foreground = term->pix_colors[fg]; 1056 v.foreground = term->pix_colors[fg];
1409 { 1410 {
1410 if (ep != enc) 1411 if (ep != enc)
1411 { 1412 {
1412 rxvt_drawable &d2 = d.screen->scratch_drawable (w, h); 1413 rxvt_drawable &d2 = d.screen->scratch_drawable (w, h);
1413 1414
1414#ifdef HAVE_BG_PIXMAP 1415#ifdef HAVE_IMG
1415 Picture dst = 0; // the only assignment is done conditionally in the following if condition 1416 Picture dst = 0; // the only assignment is done conditionally in the following if condition
1416 1417
1417 if (term->bg_img 1418 if (term->bg_img
1418 && (bg == Color_transparent || bg == Color_bg 1419 && (bg == Color_transparent || bg == Color_bg
1419 || (bg >= 0 && !term->pix_colors[bg].is_opaque () && ((dst = XftDrawPicture (d2)))))) 1420 || (bg >= 0 && !term->pix_colors[bg].is_opaque () && ((dst = XftDrawPicture (d2))))))
1605 cs = codeset_from_name (spec + sizeof ("codeset=") - 1); 1606 cs = codeset_from_name (spec + sizeof ("codeset=") - 1);
1606 else 1607 else
1607 rxvt_warn ("unknown parameter '%s' in font specification, skipping.\n", spec); 1608 rxvt_warn ("unknown parameter '%s' in font specification, skipping.\n", spec);
1608 1609
1609 desc++; 1610 desc++;
1610 while (*desc <= ' ') desc++; 1611 while (*desc <= ' ' && *desc) desc++;
1611 } 1612 }
1612 1613
1613 end = strchr (desc, ','); 1614 end = strchr (desc, ',');
1614 if (!end) 1615 if (!end)
1615 end = desc + strlen (desc); 1616 end = desc + strlen (desc);
1733 // way to configure this and xft is easier to hack in, 1734 // way to configure this and xft is easier to hack in,
1734 // while x11 has more framework in place already. 1735 // while x11 has more framework in place already.
1735 // TODO: this is a real resource hog, xft takes ages(?) 1736 // TODO: this is a real resource hog, xft takes ages(?)
1736#if XFT && USE_SLOW_LOOKUP 1737#if XFT && USE_SLOW_LOOKUP
1737 // grab the first xft font that seems suitable 1738 // grab the first xft font that seems suitable
1739 // TOOD: should go first for cellchar (spacing 110) then mono, then else
1738 FcPattern *p = FcPatternCreate (); 1740 FcPattern *p = FcPatternCreate ();
1739 1741
1740 FcCharSet *s = FcCharSetCreate (); 1742 FcCharSet *s = FcCharSetCreate ();
1741 FcCharSetAddChar (s, unicode); 1743 FcCharSetAddChar (s, unicode);
1742 FcPatternAddCharSet (p, FC_CHARSET, s); 1744 FcPatternAddCharSet (p, FC_CHARSET, s);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines