--- rxvt-unicode/src/defaultfont.C 2004/03/04 00:59:10 1.32 +++ rxvt-unicode/src/defaultfont.C 2004/03/05 05:52:02 1.37 @@ -277,6 +277,7 @@ { if (unicode <= 0x001f) return true; + if (unicode >= 0x0080 && unicode <= 0x009f) return true; @@ -284,6 +285,9 @@ && linedraw_cmds[unicode - 0x2500]) return true; + if (IS_COMPOSE (unicode)) + return true; + switch (unicode) { case ZERO_WIDTH_CHAR: @@ -309,6 +313,7 @@ while (len--) { + compose_char *cc; text_t t = *text++; // is it in our linedrawing table? @@ -347,6 +352,20 @@ gcv.line_width = 0; XChangeGC (d.display->display, GC, GCLineWidth, &gcv); } + else if (IS_COMPOSE (t) && (cc = rxvt_composite[t])) + { + 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); + } + } else switch (t) { @@ -1019,6 +1038,7 @@ else f = new rxvt_font_x11; + f->fs = this; f->set_term (r); f->set_name (strdup (name)); @@ -1099,7 +1119,6 @@ rxvt_fontset::populate (const char *desc) { clear (); - printf ("P(%s)\n",desc); fonts.push_back (new_font (0, CS_UNICODE)); realize_font (0);