[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: New KDE printing system
From:       Michael Goffioul <goffioul () imec ! be>
Date:       2001-02-28 13:33:27
[Download RAW message or body]

Guillaume Laurent wrote:

> On Wednesday 28 February 2001 12:40, Harri Porten wrote:
>
> > If the KPrinterFactory is only used to create a single KPrinter object,
> > I'd rather hide the factory class and add the self() method to KPrinter.
>
> While the KPrinterFactory surely is a singleton, I don't see why you should
> be limited to having one KPrinter only. What if the user has several printers
> defined ?

The KPrinter object is not attached at all to a specific printer. It has exactly the
same role as a QPrinter object: it is essentially a QPaintDevice on which you
can draw, the result being sent to a printer instead of the screen. It is of course
configurable (as QPrinter) through a print dialog where you can select the printer,
the printing options, ...
Think of KPrinter as for QPrinter. The only significant difference is that it supports
different printing system, the factory being aware of the user settings, but that's
not the problem of the application developer.

Briefly said, a KPrinter object is NOT a real printer, it is an interface between the
Qt drawing primitives and a real printer, the latter being configurable.

Michael.

--
------------------------------------------------------------------
Michael Goffioul                IMEC-DESICS-MIRA
e-mail: goffioul@imec.be        (Mixed-Signal and RF Applications)
Tel:    +32/16/28-8510          Kapeldreef, 75
Fax:    +32/16/28-1515          3001 HEVERLEE, BELGIUM
------------------------------------------------------------------

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic