[cairo-bugs] [Bug 13344] the win32 printing surface is not resizable

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Fri Jan 11 04:33:34 PST 2008


http://bugs.freedesktop.org/show_bug.cgi?id=13344


Adrian Johnson <ajohnson at redneon.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ajohnson at redneon.com
             Status|NEW                         |RESOLVED
         Resolution|                            |NOTABUG




--- Comment #1 from Adrian Johnson <ajohnson at redneon.com>  2008-01-11 04:33:31 PST ---
The reason this function is not implemented is because cairo doesn't own the
device you are printing to. It just translates the cairo API to GDI calls. It
is the responsibility of the application to do all the setup of the Windows
device. For example the application needs to call the StartDoc, EndDoc,
StartPage, and EndPage functions. 

The recommended way to change the page size is to destroy the
cairo_win32_printing surface, use the windows API to change the page size, then
create a new cairo_win32_printing surface with the same device handle. This
works because the printing surface does not store any document level state. All
it does is store the drawing commands you call then when show_page is called or
the surface is finished it calls the GDI drawing functions on the device handle
you supply to draw the page.

The PS and PDF surfaces have set size because without those functions it would
not be possible for an application to change the page size.


-- 
Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the cairo-bugs mailing list