11 string(Image *dst, Point pt, Image *src, Point sp, Font *f, char *s)
13 return _string(dst, pt, src, sp, f, s, nil, 1<<24, dst->clipr, nil, ZP, SoverD);
17 stringop(Image *dst, Point pt, Image *src, Point sp, Font *f, char *s, Drawop op)
19 return _string(dst, pt, src, sp, f, s, nil, 1<<24, dst->clipr, nil, ZP, op);
23 stringn(Image *dst, Point pt, Image *src, Point sp, Font *f, char *s, int len)
25 return _string(dst, pt, src, sp, f, s, nil, len, dst->clipr, nil, ZP, SoverD);
29 stringnop(Image *dst, Point pt, Image *src, Point sp, Font *f, char *s, int len, Drawop op)
31 return _string(dst, pt, src, sp, f, s, nil, len, dst->clipr, nil, ZP, op);
35 runestring(Image *dst, Point pt, Image *src, Point sp, Font *f, Rune *r)
37 return _string(dst, pt, src, sp, f, nil, r, 1<<24, dst->clipr, nil, ZP, SoverD);
41 runestringop(Image *dst, Point pt, Image *src, Point sp, Font *f, Rune *r, Drawop op)
43 return _string(dst, pt, src, sp, f, nil, r, 1<<24, dst->clipr, nil, ZP, op);
47 runestringn(Image *dst, Point pt, Image *src, Point sp, Font *f, Rune *r, int len)
49 return _string(dst, pt, src, sp, f, nil, r, len, dst->clipr, nil, ZP, SoverD);
53 runestringnop(Image *dst, Point pt, Image *src, Point sp, Font *f, Rune *r, int len, Drawop op)
55 return _string(dst, pt, src, sp, f, nil, r, len, dst->clipr, nil, ZP, op);
59 _string(Image *dst, Point pt, Image *src, Point sp, Font *f, char *s, Rune *r, int len, Rectangle clipr, Image *bg, Point bgp, Drawop op)
62 ushort cbuf[Max], *c, *ec;
79 while((*s || *r) && len){
83 n = cachechars(f, sptr, rptr, cbuf, max, &wid, &subfontname);
85 _setdrawop(dst->display, op);
90 b = bufimage(dst->display, m);
92 fprint(2, "string: %r\n");
100 BPLONG(b+5, src->id);
101 BPLONG(b+9, f->cacheimage->id);
103 BPLONG(b+17, pt.y+f->ascent);
104 BPLONG(b+21, clipr.min.x);
105 BPLONG(b+25, clipr.min.y);
106 BPLONG(b+29, clipr.max.x);
107 BPLONG(b+33, clipr.max.y);
119 for(c=cbuf; c<ec; c++, b+=2)
127 if(_getsubfont(f->display, subfontname) == 0){
128 def = f->display->defaultfont;