123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- #include "sys-defines.h"
- #include "extern.h"
- bool
- _pl_x_end_page (S___(Plotter *_plotter))
- {
-
- if (_plotter->x_double_buffering == X_DBL_BUF_BY_HAND)
-
- {
-
- int window_width = (_plotter->data->imax - _plotter->data->imin) + 1;
- int window_height = (_plotter->data->jmin - _plotter->data->jmax) + 1;
-
- if (_plotter->x_drawable1)
- XCopyArea (_plotter->x_dpy, _plotter->x_drawable3, _plotter->x_drawable1,
- _plotter->drawstate->x_gc_bg,
- 0, 0,
- (unsigned int)window_width, (unsigned int)window_height,
- 0, 0);
- if (_plotter->x_drawable2)
- XCopyArea (_plotter->x_dpy, _plotter->x_drawable3, _plotter->x_drawable2,
- _plotter->drawstate->x_gc_bg,
- 0, 0,
- (unsigned int)window_width, (unsigned int)window_height,
- 0, 0);
-
-
- if (_plotter->x_drawable1 || _plotter->x_drawable2)
- XFreePixmap (_plotter->x_dpy, _plotter->x_drawable3);
- }
-
- _pl_x_delete_gcs_from_first_drawing_state (S___(_plotter));
-
- return true;
- }
- void
- _pl_x_delete_gcs_from_first_drawing_state (S___(Plotter *_plotter))
- {
-
- if (_plotter->x_drawable1 || _plotter->x_drawable2)
- {
- XFreeGC (_plotter->x_dpy, _plotter->drawstate->x_gc_fg);
- XFreeGC (_plotter->x_dpy, _plotter->drawstate->x_gc_fill);
- XFreeGC (_plotter->x_dpy, _plotter->drawstate->x_gc_bg);
- }
- }
|