|
From: Harald H. <h.h...@tu...> - 2005-10-13 00:53:12
|
On Wed, 12 Oct 2005, Ethan Merritt wrote:
> On Wednesday 12 October 2005 04:45 pm, Harald Harders wrote:
>
> > > Introduce a new coordinate system "absolute", or maybe even the specific
> > > units "in", "cm", "pt", "pixel".
> >
> > I totally agree with this approach. The specific units have too problems:
> > How shall pixel defined in vector terminals
>
> I assume that you would not specify a measurement in pixels if you are
> using a vector terminal.
I won't. But many other people will. And it might happen that you have
used a pixel terminal and switch to a vector terminal afterwards. Thus,
every unit should work everywhere.
> > and how shall in, ch, pt be
> > defined in terminals without a absolute canvas size?
>
> Which terminals do you have in mind here - the pixel terminals?
I thought of screen terminals (which in fact are also pixel terminals).
Pixel terminals are not a problem because of the resolution. I think we
can give every terminal that does not know a resolution a default of
72dpi. Also vector-based terminals could use a (pseudo) resolution to
convert pixels to real measures.
> > For png and jpeg, a
> > resolution in dpi could be given and thus in, ch, and pt also used.
>
> I think we would have to introduce a "dpi" parameter into the various terminal
> options. There would have to be a default value, which would usually turn out
> to be wrong, but what else can we do?
>
> set term png size 900,300 {dpi 300}
> would be the same as
> set term png size 3in, 1in dpi 300
That's a good idea. Then, all terminals could get the ability of absolute
measures. The second line would change to
set term png size inch 3,1 dpi 300
if inch is one of the new measures. Then, sizes could be given using
get_position() which allows all measures except 'screen', 'first',
'second', and 'graph'. Even 'character' could be valid (even if strange).
For pixel-based terminals, the unit could default to 'pixel', for
postscript to 'pt'.
I think adding 'inch', 'millimeter', 'point', and 'pixel' to the list of
coordinate systems would be a big step in the right direction. This would
enable users to produce plots in exact the size they want to get them.
Best regards
Harald
--
Harald Harders
h.h...@tu...
http://www.harald-harders.de
|