--- rxvt-unicode/src/defaultfont.C 2004/03/04 20:09:01 1.35 +++ rxvt-unicode/src/defaultfont.C 2004/03/11 20:26:49 1.39 @@ -270,6 +270,8 @@ width = 1; height = 1; ascent = 1; descent = 0; + set_name ("built-in pseudofont"); + return true; } @@ -313,6 +315,9 @@ while (len--) { +#if ENABLE_COMBINING + compose_char *cc; +#endif text_t t = *text++; // is it in our linedrawing table? @@ -351,11 +356,22 @@ gcv.line_width = 0; XChangeGC (d.display->display, GC, GCLineWidth, &gcv); } - else if (IS_COMPOSE (t)) +#if ENABLE_COMBINING + else if (IS_COMPOSE (t) && (cc = rxvt_composite[t])) { - const compose_char &cc = rxvt_composite[t]; - (void)0; //D ADD pseudo handling here + rxvt_font *f1 = (*fs)[fs->find_font (cc->c1)]; + f1->draw (d, x, y, &(t = cc->c1), 1, fg, bg); + if (cc->c2 != NOCHAR) + { + // prefer font of first character, for no good reasons + rxvt_font *f2 = f1->has_codepoint (cc->c2) + ? f1 + : (*fs)[fs->find_font (cc->c2)]; + + f2->draw (d, x, y, &(t = cc->c2), 1, fg, -1); + } } +#endif else switch (t) { @@ -1028,6 +1044,7 @@ else f = new rxvt_font_x11; + f->fs = this; f->set_term (r); f->set_name (strdup (name));