Re: patch -- fix resolution in pango (win32 backend)



--- Tor Lillqvist <tml iki fi> wrote:
> I wrote:
> >  > > There usually is a way tell X11 the actual
> physical size of your
> >  > > display area. 
> 
> Looking more close into this, the Xsun server for
> instance has the
> command line options dpix and dpix, with which one
> can tell the
> dimensions of the monitor. XFree86 has the
> DisplaySize option in the
> XF86Config file. Exceed allows you to specify the
> monitor size in mm
> in its configuration dialog.
> 
> The X Logical Font Description Conventions document
> says: 
> 
>     RESOLUTION_X and RESOLUTION_Y are unsigned
> integer-strings that
>     give the horizontal and vertical resolution,
> measured in pixels or
>     dots per inch (dpi), for which the font was
> designed.
> 
> Note "for which the font was designed".
> 
> Let's not confuse matters by considering the typical
> X11 bitmap font
> directories for 75 and 100 dpi design sizes, and
> their order in a X
> server font path. That is irrelevant, in Windows and
> in modern X
> practice scaleable outline fonts are used.
> 
> Joaquín Cuenca Abela writes: 
> > The problem is not in code that assumes the same
> resolution in
> > printers as in screen, but code that assumes that
> the same physical
> > size is readable in screen only because it's
> readable in a printer
> > (and that's what pango is doing right now).
> 
> I don't think Pango assumes anything about what is
> readable on a
> screen. Surely it is the library or application that
> uses Pango that
> specifies the size of font to use. Ultimately it is
> the user that
> should be able to set things like this in
> preferences.
> 
> > yes, it does.  It picks a default value for your
> physical screen
> > size to match 75x75dpi.  I've changed it in my
> computer to have
> > 96x96dpi and now gtk+ 2 applications renders text
> at a much more
> > comfortable size :)
> 
> But instead of pretending that your monitor's size
> is smaller (has a
> higher dpi) than what it is, why not let X know the
> *true* size of it,
> and ask the applications to use larger fonts?
> Wouldn't that be much
> more straightforward?
> 
> Similarily for Windows, why use some silly 20-30%
> larger than actual
> "logical inch", and pretend to use a 12 point font
> (which actually on
> the screen is then maybe 14 points) when you could
> use true sizes, and
> simply ask the application to use a 14 point font
> size in the first
> place?

Because WYSIWYG programs want to use the same
font/same typographical size on screen and on the
printer.

Because you don't want to redo every document, every
presentation, every whatever that uses fonts for each
screen size that you have.

Because you don't want your fonts to grow magically
when you augment your screen resolution.

Because nobody cares (but highly specialized software,
as CAD programs) about the real physical size.  You
just want your stuff to render with the same number of
pixels independently of your screen/resolution (and
with an amount of pixels that makes it readable, btw).

Because you want gtk+ apps render text at the same
size as any other windows application.

Seriouly, the screen size that gives you HORZSIZE and
VERTSIZE 99.9% of times its just the screen size of an
average monitor... and afaik an average monitor from
the 80's, and even if it will give you the real screen
size, you don't care about it if you want to remain
device independent (the fact that X11 screwed the
whole thing, not having a way to render device
indepent text don't means that gtk in win should
repeat these errors).

You can not ask wordprocessors, for instance, to
render text on screen at 16points, and then on the
printer at 10points.

> The X11 protocol specs says about the per-screen
> information:
> 
>     Width-in-millimeters and height-in-millimeters
> can be used to
>     determine the physical size and the aspect
> ratio.
> 
> I couldn't find any other mention of millimetres,
> even less inch or
> dpi. Certainly nowhere in the X Protocol specs is
> there any mention
> of 75 dpi being a default resolution of a screen.
> 
> Now, if some X server by default, if the user hasn't
> bothered to
> measure his monitor, applies a 75dpi guesstimate,
> well, that is just a
> implementation-specific guess.

you're right, I'm sorry I was not specific enough.  I
was just speaking about XFree86.

Cheers,


=====
Joaquin Cuenca Abela
e98cuenc yahoo com

__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com



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