tall and skinny truetype chars in xfree86 v4 and redhat 7.0

tall and skinny truetype chars in xfree86 v4 and redhat 7.0

Post by Johan Kullsta » Sat, 07 Oct 2000 04:00:00



i have installed redhat 7.0 and am using xfree86 version 4.0.1.
i am using redhat's X font server, xfs which i take is derived from
xfree86 v4 too.

everything is great except one thing.  all truetype and .pfb type1
fonts get rendered as extra tall and skinny.  all other fonts
including .pfa type1 look normal.  xfontsel shows resx is 75 while
resy is 100.  xdpyinfo gives

screen #0:
  dimensions:    1152x864 pixels (333x241 millimeters)
  resolution:    88x91 dots per inch

i am guessing that 88 rounds down to 75 and that 91 rounds up to 100.

i have a machine at home with different video card and monitor and it
doesn't have this problem.  the resolution there gives smaller numbers
for dots per inch which both round to 75.

1) does the 75x100 thing have anything to do with the resolution
   reported by xdpyinfo?

2) how does the X system know how large my screen is?  does the
   monitor report this back to X?

3) does anyone have any ideas as to how to induce truetype fonts to be
   rendered with a reasonable aspect ratio?

--
J o h a n  K u l l s t a m

sysengr

 
 
 

tall and skinny truetype chars in xfree86 v4 and redhat 7.0

Post by Toby Hayne » Wed, 11 Oct 2000 04:00:00



  Johan> i have installed redhat 7.0 and am using xfree86 version 4.0.1.  i am
  Johan> using redhat's X font server, xfs which i take is derived from xfree86
  Johan> v4 too.

  Johan> everything is great except one thing.  all truetype and .pfb type1
  Johan> fonts get rendered as extra tall and skinny.  all other fonts
  Johan> including .pfa type1 look normal.  xfontsel shows resx is 75 while
  Johan> resy is 100.  xdpyinfo gives

  Johan> screen #0: dimensions: 1152x864 pixels (333x241 millimeters)
  Johan> resolution: 88x91 dots per inch

  Johan> i am guessing that 88 rounds down to 75 and that 91 rounds up to 100.

I'd agree.

  Johan> i have a machine at home with different video card and monitor and it
  Johan> doesn't have this problem.  the resolution there gives smaller numbers
  Johan> for dots per inch which both round to 75.

  Johan> 1) does the 75x100 thing have anything to do with the resolution
  Johan> reported by xdpyinfo?

Probably, although I'm not an expert.

  Johan> 2) how does the X system know how large my screen is?  does the
  Johan> monitor report this back to X?

It guesses :-) There is some negotation between the Xserver and the monitor
with some drivers, so it's possible it gets close to the right answer, but in
this case it doesn't produce the best result...

  Johan> 3) does anyone have any ideas as to how to induce truetype fonts to be
  Johan> rendered with a reasonable aspect ratio?

You should work out roughly what the true dpi of your monitor is in the screen
resolution you want to use - it may be 100dpi or higher. For sanities sake
we'll assume you have square pixels on your screen, and you can tell the X server
precisely what dpi to use. If you use xdm to start X, look in

/etc/X11/xdm/Xservers

and edit the file to look like to get 100dpi in both directions:

:0 local /usr/X11R6/bin/X -dpi 100

Cheers,
Toby Haynes

--

Toby Haynes
The views and opinions expressed in this message are my own, and do
not necessarily reflect those of IBM Canada.

 
 
 

tall and skinny truetype chars in xfree86 v4 and redhat 7.0

Post by Johan Kullsta » Wed, 11 Oct 2000 04:00:00




>   Johan> i have installed redhat 7.0 and am using xfree86 version 4.0.1.  i am
>   Johan> using redhat's X font server, xfs which i take is derived from xfree86
>   Johan> v4 too.

>   Johan> everything is great except one thing.  all truetype and .pfb type1
>   Johan> fonts get rendered as extra tall and skinny.  all other fonts
>   Johan> including .pfa type1 look normal.  xfontsel shows resx is 75 while
>   Johan> resy is 100.  xdpyinfo gives

>   Johan> screen #0: dimensions: 1152x864 pixels (333x241 millimeters)
>   Johan> resolution: 88x91 dots per inch

>   Johan> i am guessing that 88 rounds down to 75 and that 91 rounds up to 100.

> I'd agree.

>   Johan> i have a machine at home with different video card and monitor and it
>   Johan> doesn't have this problem.  the resolution there gives smaller numbers
>   Johan> for dots per inch which both round to 75.

>   Johan> 1) does the 75x100 thing have anything to do with the resolution
>   Johan> reported by xdpyinfo?

> Probably, although I'm not an expert.

>   Johan> 2) how does the X system know how large my screen is?  does the
>   Johan> monitor report this back to X?

> It guesses :-) There is some negotation between the Xserver and the monitor
> with some drivers, so it's possible it gets close to the right answer, but in
> this case it doesn't produce the best result...

>   Johan> 3) does anyone have any ideas as to how to induce truetype fonts to be
>   Johan> rendered with a reasonable aspect ratio?

> You should work out roughly what the true dpi of your monitor is in the screen
> resolution you want to use - it may be 100dpi or higher. For sanities sake
> we'll assume you have square pixels on your screen, and you can tell the X server
> precisely what dpi to use. If you use xdm to start X, look in

> /etc/X11/xdm/Xservers

> and edit the file to look like to get 100dpi in both directions:

> :0 local /usr/X11R6/bin/X -dpi 100

i'm not using xdm.  however, i did

echo /usr/X11R6/bin/X -dpi 100 > ~/.xserverrc

and this make X believe my screen is 100x100 dpi and everything is
fine with my fonts.

thanks.

--
J o h a n  K u l l s t a m

sysengr

 
 
 

1. Solution: tall skinny truetype/Type1 fonts

I came across a problem when I upgraded to RedHat 7.2, in that for
some reason all of my TrueType and Type1 fonts appeared tall and
skinny.  Turns out, this is due to an incorrect determination of the
screen resolution by X, so that one dimension is viewed as 75 dpi and
the other as 100 dpi.

Anyway, here are the solutions I found.

First, you can use the "-dpi 100" or "-dpi 75" flags when launching X.
 You can change this in various places, depending on how X starts up.
There's info on how to do this in the Google archives.

Another, I think better, solution is to edit the Monitor section of
your XF86Config file so that it knows your actual screen size.  In
particular, add a DisplaySize <xsize> <ysize>, where <xsize> and
<ysize> are in millimeters.  This goes in the "Monitor" section.  Note
that on RH7.1 and RH7.2 anyway, if you're using XFree 4.*, you need to
put this in the XF86Config-4 file, not the XF86Config file.

Hope this is helpful to someone.
Yaron Minsky

2. fopen() fails; errno == EINPROGRESS ?!?!

3. Matrox Mystique ands X.

4. After SMIT IP change, networking and X server are broken

5. XFree86 v4.1 Slower Than XFree86 v4.0

6. kerndist download

7. XFree86 v4.0.3 RPM packages for RedHat v6.2?

8. ANNOUNCE: LinuxMonth

9. RedHat/Linux v4.2 and XFree86-3.3-1 for 386(S3 Vision968)

10. Suse 7.0; Yast2, kinternet, rc.dialout und ich komme nicht ins Internet

11. 3DLabs GVX1 under Redhat Linux 7.0 (XFree86 4.0.1)

12. RedHat 7.0 has the Xfree86 3.3.6 server, but 4.0.1 clients!