[Gambas-user] GTK and printing to printer

Benoit Minisini gambas at ...1...
Sun Jan 29 16:56:58 CET 2006


On Sunday 29 January 2006 10:02, Christopher Brian Jack wrote:
> On Sun, 29 Jan 2006, Christopher Brian Jack wrote:
> > Date: Sun, 29 Jan 2006 00:42:09 -0800 (PST)
> > From: Christopher Brian Jack <brian at ...1334...>
> > To: gambas-user at lists.sourceforge.net
> > Subject: Re: [Gambas-user] GTK and printing to printer
> >
> > On Sun, 29 Jan 2006, Rob Kudla wrote:
> > > On Sun January 29 2006 00:48, Christopher Brian Jack wrote:
> > > > > Not yet, I've not implemented the printer class. In fact
> > > > > I'll need a separate component as printers are part of the
> > > > > Gnome libraries, not the GTK libraries.
> > > >
> > > > What about using something like CUPS (Common Unix Printing
> > > > System)?
> > >
> > > GNOME or Qt printing support is to CUPS as Gtk or Qt is to X.
> > > They have different purposes, and in the case of high-level
> > > application development, both are necessary.
> > >
> > > I thought gimp-print was part of Gtk now, though.
> >
> > If that is true then it should be possible to make a component that uses
> > CUPS directly to implement a printing class independant of Qt and Gtk.
>
> Alternatively make a printing class abstraction that outputs as PostScript
> and use the available component(s) (Qt/Gtk/whatever future interface
> components) to handle printing from the resulting PostScript.  This may
> not solve the Gtk printing issue but it will make a standardized output
> hence leaving an abstracted printer class that can make the final printing
> output interface based on available components and/or Operating System and
> environment.  I guess I'm forward thinking a bit to when there may
> potentially be Gambas in Windows (or other OSes say like MacOSX).  It
> seems to make sense to abstract printing to a single class the produces an
> common intermediary that is independant to whichever low level printing
> driver is ultimately available at runtime.
>
> It just seems to be a lot of extra work to reimplement the entire printer
> class for each new interface component that comes along (say a
> gb.mingw.gdi for windows and a gb.carbon and/or gb.cocoa are produced by
> developers who want to see Gambas on Windows and MacOSX)
>
> .=================================================.
>
> |  Christopher BRIAN Jack aka "Gau of the Veldt"  |
>
> +================================================='
>
> | brian _AT_ brians-anime _DOT_ com
> | brian _AT_ animemayhem _DOT_ com
> | brian _AT_ nall.brians-anime _DOT_ com
> | brian _AT_ ruby.brians-anime _DOT_ com
> | gau_veldt _AT_ hotmail _DOT_ com
>
> `=================================================-
> Hi Spambots, my email address is sputnik at ...1334...
>

To Christopher:

It already works like that. Everything that is printed on Linux is printed in 
Postcript. And so does the QT library.

CUPS is just the system that makes the interface between postcript and the 
printer.

P.S.: I think you should reduce your signature. Your name will be sufficient 
for this mailing-list :-)

To Daniel:

if the printing support is in the Gnome library, I can put the Printer class 
of gb.qt inside a new component, gb.qt.print, and so you will be able to make 
a gb.gtk.print component based on the needed GNOME libraries.

What do you think about that?

-- 
Benoit Minisini





More information about the User mailing list