… | |
… | |
524 | |
524 | |
525 | void draw (rxvt_drawable &d, int x, int y, |
525 | void draw (rxvt_drawable &d, int x, int y, |
526 | const text_t *text, int len, |
526 | const text_t *text, int len, |
527 | int fg, int bg) |
527 | int fg, int bg) |
528 | { |
528 | { |
529 | while (len--) |
529 | while (len) |
530 | { |
530 | { |
531 | int fid = fs->find_font_idx (*text); |
531 | int fid = fs->find_font_idx (*text); |
|
|
532 | int w = 1; |
|
|
533 | while (w < len && text[w] == NOCHAR) |
|
|
534 | w++; |
532 | (*fs)[fid]->draw (d, x, y, text, 1, fg, bg); |
535 | (*fs)[fid]->draw (d, x, y, text, w, fg, bg); |
533 | ++text; |
536 | text += w; |
|
|
537 | len -= w; |
534 | x += term->fwidth; |
538 | x += term->fwidth * w; |
535 | } |
539 | } |
536 | } |
540 | } |
537 | }; |
541 | }; |
538 | |
542 | |
539 | ///////////////////////////////////////////////////////////////////////////// |
543 | ///////////////////////////////////////////////////////////////////////////// |