[Gnome-print] GnomePrintContext -> GnomePrintMaster



Hi,

How can I get a GnomePrintContext used as a gnome_print_preview_new()
into a GnomePrintMaster object ?

The general flow of logic (from the example programs) seems to be:

gpd = gnome_print_dialog_new()
gpm = gnome_print_master_new()
gnome_print_master_set_printer(gpm, gnome_print_dialog_get_printer(gpd))

pc = gnome_print_master_get_context(gpm)
... gnome_print*() functions
gnome_print_master_close()
if(preview)gnome_print_master_preview_new(gpm, "...")
gnome_print_master_print()

Alternatively, I can create a canvas object as part of my UI, and have

pc = gnome_print_preview_new(my_canvas, "paper")
...gnome_print*() functions

If I create a GnomePrintContext in this manner, how can I then get a
GnomePrintMaster object to know about this ?

(As an example of why you might want to do this, suppose you had a
screen with 4 squares, each being a canvas which can be drawn to.  I'd
like to draw something in each square, then from a menu choose an option
to print square 1, or 2, etc).

Bryan






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]