From: Sven Neumann <[EMAIL PROTECTED]>
   Date: 09 Aug 2004 12:53:25 +0200


   Robert L Krawitz <[EMAIL PROTECTED]> writes:

   >    GIMP has all this already, why would you want to deal with units in
   >    a library such as gimp-print?
   > Two reasons:
   > 1) Gimp-Print covers more than just the GIMP -- there's also the CUPS
   >    driver, the Ghostscript IJS driver, and Foomatic, in addition to a
   >    few third party apps.

   I suggest to leave it up to the application that uses gimp-print
   then. Any application that uses units in it's user interface will have
   a framework to deal with units. If you add your own framework to
   gimp-print you are only making things more complex.

Right.  The problem is how the application determines whether a
particular parameter is a measurement or just an arbitrary floating
point number.  The only piece of framework that Gimp-Print's going to
have is a new parameter type that's a "unit" rather than a
dimensionless floating point or integer number.  How the application
deals with that is up to it.  Basically it sounds like we're in
reasonable agreement here.

   > 2) The dimension type tells the user interface to treat this
   >    parameter specially (display it in units of the user's choice).

   Any length parameter in GIMP is measured in pixels and if there's
   resolution information, the user is given the opportunity to use
   arbitrary units to specify it. The underlying code still sees nothing
   but pixels. I don't see why the underlying code (in this case
   gimp-print) would have to know about this.

That's an issue for the plugin to deal with.  Gimp-Print deals
entirely in points (1/72"), and it's up to the application to
translate that into units useful for people.

In the future we may extend Gimp-Print to allow other fundamental
units of measure, because 1/72" may not be fine enough.  This can be
done compatibly (make the default be 1/72", and provide a way for an
application to specify a different base unit).  But that's neither
here nor there right now.

Robert Krawitz                                     <[EMAIL PROTECTED]>

Tall Clubs International  -- or 1-888-IM-TALL-2
Member of the League for Programming Freedom -- mail [EMAIL PROTECTED]
Project lead for Gimp Print   --

"Linux doesn't dictate how I work, I dictate how Linux works."
--Eric Crampton
Gimp-developer mailing list

Reply via email to