Subject: Re: reasonable details for X-applications...
To: Frederick Bruckman <fredb@immanent.net>
From: Wolfgang S. Rupprecht <wolfgang@wsrcc.com>
List: netbsd-help
Date: 01/21/2003 18:15:34
Frederick Bruckman writes:
> Really? How? I set "DisplaySize" in the "Monitor" section, but that
> clearly doesn't do it.

For stock MIT Xsun and in previous XFree86 under netbsd/i386 I used to
use have this in /usr/X11R6/lib/X11/xdm/Xservers:

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

In current 4.x XFree86 with Matrox cards I find that the server is
able to get the settings from the monitor via the VGA cable.  It does
mean the monitor needs to be on when X starts.  If I forget a quick
meta-alt-backspace causes X to restart and read the monitors settings.
This is what the MGA log string looks like when the monitor setting
are successfully read:

(--) MGA(0): Display dimensions: (400, 300) mm
(--) MGA(0): DPI set to (101, 101)

Then in ~/.Xresources one should choose fonts that are defined by
point size instead of pixel size.  This is essentially what I have:

#define BIG_FONT    -*-courier-medium-r-normal-*-*-140-*-*-*-*-iso8859-1
Emacs*font: 		BIG_FONT
Emacs*EmacsScreen.font: BIG_FONT
XTerm*font: 		BIG_FONT

XTerm*fontMenu.Label:  VT Fonts
XTerm*fontMenu*fontdefault*Label:	Default
XTerm*fontMenu*font1*Label:	Unreadable
XTerm*VT100*font1:		nil2
XTerm*fontMenu*font2*Label:	8pt
XTerm*VT100*font2:		-adobe-courier-medium-r-normal-*-*-80-*-*-*-*-iso8859-1
XTerm*fontMenu*font3*Label:	10pt
XTerm*VT100*font3:		-adobe-courier-medium-r-normal-*-*-100-*-*-*-*-iso8859-1
XTerm*fontMenu*font4*Label:	12pt
XTerm*VT100*font4:		-adobe-courier-medium-r-normal-*-*-120-*-*-*-*-iso8859-1
XTerm*fontMenu*font5*Label:	14pt
XTerm*VT100*font5:		-adobe-courier-medium-r-normal-*-*-140-*-*-*-*-iso8859-1
XTerm*fontMenu*font6*Label:	18pt
XTerm*VT100*font6:		-adobe-courier-medium-r-normal-*-*-180-*-*-*-*-iso8859-1
XTerm*fontMenu*font7*Label:	24pt
XTerm*VT100*font7:		-adobe-courier-medium-r-normal-*-*-240-*-*-*-*-iso8859-1

This gives me a default of 14pt font, no matter what monitor I happen
to sit down in front of.

Some programs are better than others for correctly using the current
dpi setting as provided by the server.  Unfortunately some programs
are still hardcoded to assume 75dpi or 72dpi (such as, for example,
xdpi).  Gently reminding program authors that they can't assume every
monitor is 75dpi is a bit of an ongoing battle. ;-)

-wolfgang
-- 
Wolfgang S. Rupprecht  <wolfgang@wsrcc.com>  http://www.wsrcc.com/wolfgang/