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



Dear Chema

I'm trying to add a customized reporting interface
 where    a report is generated by the package and , 
the user will be allowed to drag and drop the texts,images etc.

I tried to insert a lot of gnomecanvasitems  ( text ) into the canvas,  Now, eats up a lot of memory and my program segfaults
  
     Now i guess this is because the no. of canvasitems i'm creating is too high
Will it be much less memory consuming if i try to write a new widget like  ( canvas-text-box ) . This box can be later removed ..

I see that libgnomeprint has done is quite well.
            How did u manage to do it ?
           
( or could my segfaults be due to some other problem ? )


Chema Celorio wrote:
1021064721.1424.61.camel@trunk">
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

Chema



_______________________________________________
Gnome-print maillist - Gnome-print@ximian.com
http://lists.ximian.com/mailman/listinfo/gnome-p rint






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