diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/macterm.c | 37 |
1 files changed, 33 insertions, 4 deletions
diff --git a/src/macterm.c b/src/macterm.c index 5446fd5efad..b9e76d47d16 100644 --- a/src/macterm.c +++ b/src/macterm.c | |||
| @@ -1313,7 +1313,7 @@ x_draw_fringe_bitmap (w, row, p) | |||
| 1313 | else | 1313 | else |
| 1314 | x_clip_to_row (w, row, gc); | 1314 | x_clip_to_row (w, row, gc); |
| 1315 | 1315 | ||
| 1316 | if (p->bx >= 0) | 1316 | if (p->bx >= 0 && !p->overlay_p) |
| 1317 | { | 1317 | { |
| 1318 | XGCValues gcv; | 1318 | XGCValues gcv; |
| 1319 | gcv.foreground = face->background; | 1319 | gcv.foreground = face->background; |
| @@ -1339,18 +1339,45 @@ x_draw_fringe_bitmap (w, row, p) | |||
| 1339 | #endif | 1339 | #endif |
| 1340 | } | 1340 | } |
| 1341 | 1341 | ||
| 1342 | if (p->which != NO_FRINGE_BITMAP) | 1342 | if (p->which) |
| 1343 | { | 1343 | { |
| 1344 | unsigned char *bits = fringe_bitmaps[p->which].bits + p->dh; | 1344 | unsigned char *bits = p->bits + p->dh; |
| 1345 | BitMap bitmap; | 1345 | BitMap bitmap; |
| 1346 | 1346 | ||
| 1347 | mac_create_bitmap_from_bitmap_data (&bitmap, bits, p->wd, p->h); | 1347 | mac_create_bitmap_from_bitmap_data (&bitmap, bits, p->wd, p->h); |
| 1348 | gcv.foreground = face->foreground; | 1348 | gcv.foreground = face->foreground; |
| 1349 | gcv.background = face->background; | 1349 | gcv.background = face->background; |
| 1350 | 1350 | ||
| 1351 | mac_draw_bitmap (display, window, &gcv, p->x, p->y, &bitmap); | 1351 | #if 0 /* TODO: fringe overlay_p and cursor_p */ |
| 1352 | gcv.foreground = (p->cursor_p | ||
| 1353 | ? (p->overlay_p ? face->background | ||
| 1354 | : f->output_data.mac->cursor_pixel) | ||
| 1355 | : face->foreground)); | ||
| 1356 | |||
| 1357 | if (p->overlay_p) | ||
| 1358 | { | ||
| 1359 | clipmask = XCreatePixmapFromBitmapData (display, | ||
| 1360 | FRAME_X_DISPLAY_INFO (f)->root_window, | ||
| 1361 | bits, p->wd, p->h, | ||
| 1362 | 1, 0, 1); | ||
| 1363 | gcv.clip_mask = clipmask; | ||
| 1364 | gcv.clip_x_origin = p->x; | ||
| 1365 | gcv.clip_y_origin = p->y; | ||
| 1366 | XChangeGC (display, gc, GCClipMask | GCClipXOrigin | GCClipYOrigin, &gcv); | ||
| 1367 | } | ||
| 1368 | #endif | ||
| 1352 | 1369 | ||
| 1370 | mac_draw_bitmap (display, window, &gcv, p->x, p->y, &bitmap); | ||
| 1353 | mac_free_bitmap (&bitmap); | 1371 | mac_free_bitmap (&bitmap); |
| 1372 | |||
| 1373 | #if 0 /* TODO: fringe overlay_p and cursor_p */ | ||
| 1374 | if (p->overlay_p) | ||
| 1375 | { | ||
| 1376 | gcv.clip_mask = (Pixmap) 0; | ||
| 1377 | XChangeGC (display, gc, GCClipMask, &gcv); | ||
| 1378 | XFreePixmap (display, clipmask); | ||
| 1379 | } | ||
| 1380 | #endif | ||
| 1354 | } | 1381 | } |
| 1355 | 1382 | ||
| 1356 | mac_reset_clipping (display, window); | 1383 | mac_reset_clipping (display, window); |
| @@ -8517,6 +8544,8 @@ static struct redisplay_interface x_redisplay_interface = | |||
| 8517 | x_get_glyph_overhangs, | 8544 | x_get_glyph_overhangs, |
| 8518 | x_fix_overlapping_area, | 8545 | x_fix_overlapping_area, |
| 8519 | x_draw_fringe_bitmap, | 8546 | x_draw_fringe_bitmap, |
| 8547 | 0, /* define_fringe_bitmap */ | ||
| 8548 | 0, /* destroy_fringe_bitmap */ | ||
| 8520 | mac_per_char_metric, | 8549 | mac_per_char_metric, |
| 8521 | mac_encode_char, | 8550 | mac_encode_char, |
| 8522 | NULL, /* mac_compute_glyph_string_overhangs */ | 8551 | NULL, /* mac_compute_glyph_string_overhangs */ |