From: handa Date: Tue, 16 Mar 2004 13:16:28 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=3d7e521658e6b01eb5d2bc83f0985af7aaa935b9;p=m17n%2Fm17n-lib.git *** empty log message *** --- diff --git a/src/m17n-X.c b/src/m17n-X.c index a2ddcb8..e9e5a75 100644 --- a/src/m17n-X.c +++ b/src/m17n-X.c @@ -1706,6 +1706,7 @@ mwin__draw_box (MFrame *frame, MDrawWindow win, MGlyphString *gstring, } +#if 0 void mwin__draw_bitmap (MFrame *frame, MDrawWindow win, MRealizedFace *rface, int reverse, int x, int y, @@ -1724,13 +1725,29 @@ mwin__draw_bitmap (MFrame *frame, MDrawWindow win, MRealizedFace *rface, if (bmp[j / 8] & (1 << (7 - (j % 8)))) XDrawPoint (display, (Window) win, gc, x + j, y + i); } +#endif + +void +mwin__draw_points (MFrame *frame, MDrawWindow win, MRealizedFace *rface, + int intensity, MDrawPoint *points, int num) +{ + GCInfo *info = rface->info; + GC gc = info->gc[intensity]; + + if (!gc) + gc = info->gc[intensity] + = get_gc_for_anti_alias (frame->device, info, intensity); + + XDrawPoints (FRAME_DISPLAY (frame), (Window) win, gc, + (XPoint *) points, num, CoordModeOrigin); +} void -mwin__draw_pixmap (MFrame *frame, MDrawWindow win, MRealizedFace *rface, +mwin__draw_bitmap (MFrame *frame, MDrawWindow win, MRealizedFace *rface, int reverse, int x, int y, int width, int height, int row_bytes, unsigned char *pmp, - MDrawRegion region) + MDrawRegion region, int pixmap) { Display *display = FRAME_DISPLAY (frame); GCInfo *info = rface->info; @@ -1740,9 +1757,14 @@ mwin__draw_pixmap (MFrame *frame, MDrawWindow win, MRealizedFace *rface, for (j = 0; j < width; j++) if (pmp[j]) { - int intensity = reverse ? (7 - (pmp[j] >> 5)) : (pmp[j] >> 5); - GC gc = info->gc[intensity]; + int intensity; + GC gc; + if (pixmap) + intensity= reverse ? (7 - (pmp[j] >> 5)) : (pmp[j] >> 5); + else + intensity = 7; + gc = info->gc[intensity]; if (! gc) gc = info->gc[intensity] = get_gc_for_anti_alias (frame->device, info, intensity);