Re: [gnome-print] Filter code for gnome-print

On Fri, 2002-05-10 at 02:42, Sijin M. Stephen wrote:
> I've been using libgnomeprint for a while..
> Now i want to do all those which i wrote directly into the 
> gnomeprintmaster  to a canvas,
>    I've got libgnomeprint   source code with me..
> How do i find out how the functions
>              gnome_print_moveto( ) is implemented..
> i searched through the source code... for it..    couldn't find it..

Yeah, it is kind of tricky. 

If you look at gnome-print-ps2.c you will see that in
gnome_print_ps2_class_init some methods of the gnome-print-context class
are overloaded. This allow us to write backends that don't need to
implement all of the methods, if you see the ps2 case we don't have to
implement the _moveto method, we let gnome-print-stdapi.c take care of
it, it keeps the path in the graphic context, however we do care about
the _stroke method, and that is when we output the path to the file/lpr.

See how ps2 implements it and see gnome-print.c and gnome-print-stdapi.c


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