1 | /*----------------------------------------------------------------------* |
1 | /*----------------------------------------------------------------------* |
2 | * File: background.C - former xmp.C |
2 | * File: background.C - former xpm.C |
3 | *----------------------------------------------------------------------* |
3 | *----------------------------------------------------------------------* |
4 | * |
4 | * |
5 | * All portions of code are copyright by their respective author/s. |
5 | * All portions of code are copyright by their respective author/s. |
6 | * Copyright (c) 1997 Carsten Haitzler <raster@zip.com.au> |
6 | * Copyright (c) 1997 Carsten Haitzler <raster@zip.com.au> |
7 | * Copyright (c) 1997,1998 Oezguer Kesim <kesim@math.fu-berlin.de> |
7 | * Copyright (c) 1997,1998 Oezguer Kesim <kesim@math.fu-berlin.de> |
… | |
… | |
862 | else |
862 | else |
863 | {/* strightforward pixmap copy */ |
863 | {/* strightforward pixmap copy */ |
864 | gcv.tile = root_pixmap; |
864 | gcv.tile = root_pixmap; |
865 | gcv.fill_style = FillTiled; |
865 | gcv.fill_style = FillTiled; |
866 | |
866 | |
867 | while (sx < 0) sx += (int)window_width; |
867 | while (sx < 0) sx += (int)root_width; |
868 | while (sy < 0) sy += (int)window_height; |
868 | while (sy < 0) sy += (int)root_height; |
869 | |
869 | |
870 | gcv.ts_x_origin = -sx; |
870 | gcv.ts_x_origin = -sx; |
871 | gcv.ts_y_origin = -sy; |
871 | gcv.ts_y_origin = -sy; |
872 | gc = XCreateGC (dpy, root, GCFillStyle | GCTile | GCTileStipXOrigin | GCTileStipYOrigin, &gcv); |
872 | gc = XCreateGC (dpy, root, GCFillStyle | GCTile | GCTileStipXOrigin | GCTileStipYOrigin, &gcv); |
873 | |
873 | |
… | |
… | |
1217 | # if HAVE_SCROLLBARS |
1217 | # if HAVE_SCROLLBARS |
1218 | if (target->scrollBar.win) |
1218 | if (target->scrollBar.win) |
1219 | XSetWindowBackground (target->dpy, target->scrollBar.win, target->pix_colors[Color_border]); |
1219 | XSetWindowBackground (target->dpy, target->scrollBar.win, target->pix_colors[Color_border]); |
1220 | # endif |
1220 | # endif |
1221 | } |
1221 | } |
1222 | |
1222 | /* don't want Expose on the parent or vt. It is better to use |
1223 | /* don't want Expose on the parent */ |
1223 | scr_touch or we get a great deal of flicker otherwise: */ |
1224 | XClearArea (target->dpy, target->parent[0], 0, 0, 0, 0, False); |
1224 | XClearWindow (target->dpy, target->parent[0]); |
1225 | /* do want Expose on the vt, so we get refreshed properly */ |
|
|
1226 | XClearArea (target->dpy, target->vt, 0, 0, 0, 0, True); |
|
|
1227 | |
1225 | |
1228 | # if HAVE_SCROLLBARS |
1226 | # if HAVE_SCROLLBARS |
1229 | if (target->scrollBar.win) |
1227 | if (target->scrollBar.win) |
1230 | { |
1228 | { |
1231 | target->scrollBar.setIdle (); |
1229 | target->scrollBar.setIdle (); |
1232 | target->scrollbar_show (0); |
1230 | target->scrollbar_show (0); |
1233 | } |
1231 | } |
1234 | # endif |
1232 | # endif |
|
|
1233 | |
|
|
1234 | target->want_refresh = 1; |
|
|
1235 | flags |= hasChanged; |
1235 | } |
1236 | } |
1236 | } |
1237 | } |
1237 | |
1238 | |
1238 | #endif /* HAVE_BG_PIXMAP */ |
1239 | #endif /* HAVE_BG_PIXMAP */ |
1239 | |
1240 | |