mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-01-04 01:40:20 +01:00
[boilerplate/test-paginated] Issue a show_page before writing buffer
This is needed since cairo-test does not issue a show_page now, and the one coming from paginated layer is too late (around finish). The way we force the show_page is kinda funny. That is, we create a temporary cairo_t and call cairo_show_page() on it. But works.
This commit is contained in:
parent
efe8c82738
commit
5f5afac8f4
1 changed files with 5 additions and 0 deletions
|
|
@ -210,6 +210,11 @@ test_paginated_write_to_png (cairo_surface_t *surface,
|
|||
cairo_format_t format;
|
||||
test_paginated_closure_t *tpc;
|
||||
|
||||
/* show page first. the automatic show_page is too late for us */
|
||||
cairo_t *cr = cairo_create (surface);
|
||||
cairo_show_page (cr);
|
||||
cairo_destroy (cr);
|
||||
|
||||
tpc = cairo_surface_get_user_data (surface, &test_paginated_closure_key);
|
||||
|
||||
switch (tpc->content) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue