[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

Re: windows fonts on Linux???????????



This is a multi-part message in MIME format.
- --------------6307ED1614785692D85A2B2C
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

http://www.frii.com/~meldroc/Font-Deuglification.html




ragOO, VU2RGU
- -- 
Keeping the Air-Waves FREE.....Amateur Radio
Keeping the W W W     FREE..Debian GNU/Linux
- --------------6307ED1614785692D85A2B2C
Content-Type: text/html; charset=us-ascii;
 name="Font-Deuglification.html"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="Font-Deuglification.html"

<HTML>
<HEAD>
<TITLE>XFree86 Font Deuglification HOW-TO</title>
<META NAME="description" CONTENT="How to fix ugly and unreadable XFree86 fonts.">
<META NAME="keywords" CONTENT="X, XFree86, Linux, font, TrueType, xfstt, Deuglification, HOW-TO">
</HEAD>

<BODY BGCOLOR="#FFFFFF" TEXT="#000000">

<TABLE ALIGN=CENTER WIDTH=95%>
<TR>
<TD>
<H1>XFree86 Font Deuglification Mini HOW-TO</H1>
<H2>Doug Holland, <TT><A HREF="mailto:meldroc@xxxxxxxx";>meldroc@xxxxxxxx</A></TT></H2>
Copyright &copy 1999, Doug Holland<BR>
Revision 0.12, last modified June 10, 1999<BR>
<HR>
<EM>How to fix ugly and unreadable X Window font problems.</EM>
<HR>

<H2>Table of Contents</H2>

<UL>
<LI>1. <A HREF="#intro">Introduction</A>
   <UL>
   <LI>1.1 <A HREF="#changelog">Change Log</A>
   <LI>1.2 <A HREF="#helpplease">A Plea for Help</A>
   </UL>

<LI>2. <A HREF="#xf86config">The XF86Config file</A>
   <UL>
   </LI>2.1 <A HREF="#fontpath">Setting the FontPath</A>
   </UL>

<LI>3. <A HREF="#xclopt">X server command line options</A>

<LI>4. <A HREF="#truetype">TrueType fonts</A> (one of the few things
   Windows is good for)
   <UL>
   <LI>4.1 <A HREF="#xfstt">xfstt</A>
      <UL>
      <LI>4.1.1 <A HREF="#install">Installation</A>
      <LI>4.1.2 <A HREF="#defaultsize">Adjusting the default font size.</A>
      </UL>
   </UL>

<LI>5. <A HREF="#kde">KDE</A>
   <UL>
   <LI>5.1 <A HREF="#kdestyle">Applying KDE font & colors to non KDE apps.</A>
   </UL>
   
<LI>6. <A HREF="#apps">Adjusting fonts in specific applications.</A>
   <UL>
   <LI>6.1 <A HREF="#netscape">Netscape Navigator/Communicator</A>
   <LI>6.2 <A HREF="#wordperfect">WordPerfect</A>
   <LI>6.3 <A HREF="#staroffice">StarOffice</A>
   </UL>

<LI>7. <A HREF="#credits">Credits</A>

<LI>8. <A HREF="#legal">Legalities</A>

</UL>

<HR>

<H2><A NAME="intro">1. Introduction</A></H2>

   <P>
   One of the most annoying sets of problems I have had to deal with
   is the abysmal default fonts and font settings of X (I'm talking
   specifically about XFree86, other versions of X may be better.) Many
   programs use fixed width default fonts when a variable width font
   would be more appropriate.  Other programs use fonts that are
   <SMALL><SMALL>ridiculously tiny</SMALL></SMALL> and unreadable.  The
   fonts that are bundled with XFree86 are barely adequate for the job.
   It does come with a halfway decent courier font, but its Times and
   Helvetica fonts are simple bitmap fonts that pixelize when they are
   scaled.  Yuck!  

   <P>
   This HOW-TO attempts to show how to adjust various font settings,
   install new fonts, and do other things that will greatly improve
   the appearance and readability of fonts on the X Window Desktop. 
   This is done by adjusting the FontPath in the XF86Config file, by
   adding switches to X server command line in startx or xdm, by adding
   new fonts, by installing the TrueType font server xfstt, and by
   using a feature in the K Desktop Environment 1.1 that automagically
   adjusts font settings in many applications, including non-KDE apps
   to set their fonts and colors to match KDE's style settings.

   <P>
   Comments, corrections, additions and critiques are always welcome.
   You can reach me at <A HREF="mailto:meldroc@xxxxxxxx";>meldroc@xxxxxxxx</A>.

   <H3><A NAME="changelog">1.1 Change Log</A></H3>
   <UL>
      <LI>0.1:  Feb. 21, 1999: First release.
      <LI>0.11: Feb. 27, 1999: Added copyright info to protect my butt.
      <LI>0.12: Jun. 10, 1999: Added A Plea for Help.
   </UL>

   <H3><A NAME="helpplease">1.2 A Plea for Help:</A></H3>

   <P>
   I would like to be able to distribute this document more widely on the
   net.  I've registered this HOW-TO with several web directories and search
   engines, including the Open Directory Project, Yahoo, Alta-Vista, Google
   and a bunch of others.  However, I still get comments stating that the
   Font Deuglification HOW-TO is difficult to find on the net.  That's where I
   need your help.  I would like this HOW-TO on as many search engines and
   directories as possible, and I would like to get in some popular Linux
   web sites such as Freshmeat and the Linux Documentation Project.  I would
   really love it if this HOW-TO became a part of the official Linux
   Documentation Project HOW-TO collection - it would bring Deuglification to
   as many people as possible, but I haven't been able to contact the HOW-TO
   maintainer.  Any assistance or advice would be most appreciated.

   <P>
   I now return you to your regularly scheduled Deuglification. ;)

<P>
<HR>

<H2><A NAME="xf86config">2. The XF86Config file</A></H2>

   <P>
   The first place to look when seeking to cure font problems is the
   <STRONG><TT>XF86Config</TT></STRONG> file.
   (<TT>/usr/X11/lib/X11/XF86Config</TT> or <TT>/etc/X11/XF86Config</TT>
   are the usual locations.)  If you haven't guessed already, the most
   important part of this file relating to fonts is the
   <TT>FontPath.</TT> Before we get into that, this would be a good
   time to check the other parts of your X configuration.  Bad monitor
   settings can be even more of a headache than bad fonts, so make sure
   your refresh rate is as high as your monitor can handle (85 Hz is
   great, 75 Hz is OK, 60 Hz is painful.)

   <H3><A NAME="fontpath">2.1 Setting the FontPath</A></H3>

      <P>
      Use your favorite text editor and edit <TT>XF86Config</TT>.  Near
      the top of the file, you should see something like this:

<PRE>
FontPath	"/usr/X11R6/lib/X11/fonts/misc/"
FontPath	"/usr/X11R6/lib/X11/fonts/Type1/"
FontPath	"/usr/X11R6/lib/X11/fonts/Speedo/"
FontPath	"/usr/X11R6/lib/X11/fonts/75dpi/"
FontPath	"/usr/X11R6/lib/X11/fonts/100dpi/"
</PRE>

      <P>
      The <TT>FontPath</TT> tells X where to find the fonts it uses
      to render text on your display.  Order is important -- when an X
      application asks X to render some text, the X server usually has
      some leeway to choose the font that is used.  The X server then
      goes through the <TT>FontPath</TT> and grabs the first font it
      sees that matches the X client's criteria, and then renders.

      <P>
      The default FontPath typically puts 75dpi fonts before the 100dpi
      fonts.  If you have a high resolution display, this means very
      tiny fonts.  The first tweak you'll use is to switch the 75dpi &
      100dpi FontPath lines.

<PRE>
FontPath	"/usr/X11R6/lib/X11/fonts/misc/"
FontPath	"/usr/X11R6/lib/X11/fonts/Type1/"
FontPath	"/usr/X11R6/lib/X11/fonts/Speedo/"
FontPath	"/usr/X11R6/lib/X11/fonts/100dpi/"
FontPath	"/usr/X11R6/lib/X11/fonts/75dpi/"
</PRE>

      <P>
      Next, specify that you prefer to use unscaled bitmap fonts.  If
      you've ever used Netscape or any other program that displays
      titles using big fonts, you'll notice that those fonts are
      pixelized.  This is very ugly and needs to be fixed.  So add
      <TT>:unscaled</TT> to the ends of the misc, 100dpi & 75dpi fonts.
      You can even use both unscaled and scaled fonts if you want, just
      put the unscaled <TT>FontPath</TT> lines first to tell X you prefer
      unscaled fonts if possible. 

<PRE>
FontPath	"/usr/X11R6/lib/X11/fonts/misc:unscaled"
FontPath	"/usr/X11R6/lib/X11/fonts/100dpi:unscaled"
FontPath	"/usr/X11R6/lib/X11/fonts/75dpi:unscaled"
FontPath	"/usr/X11R6/lib/X11/fonts/Type1"
FontPath	"/usr/X11R6/lib/X11/fonts/Speedo"
FontPath	"/usr/X11R6/lib/X11/fonts/misc"
FontPath	"/usr/X11R6/lib/X11/fonts/100dpi"
FontPath	"/usr/X11R6/lib/X11/fonts/75dpi"
</PRE>

      <P>
      After making these changes, restart X.  Doesn't the desktop look
      better already?

<P>
<HR>

<H2><A NAME="xclopt">3. X server command line options</A></H2>

   <P>
   The next thing you need to do is adjust the command line options for
   the X server.  You'll want to use the <TT>-dpi</TT> switch which
   specifies the display resolution in dots per inch.  As a lot of
   systems use high resolution displays these days, chances are they'll
   be working at 100 dpi.

   <P>
   If you start X from the console command prompt, type

<PRE>
startx -dpi 100.
</PRE>

   <P>
   If you use xdm for graphical logins, you'll want to edit your
   <TT>/usr/X11/lib/X11/xdm/Xservers</TT> file, which will have the command
   line for the Xserver in it.  Mine has the line

<PRE>
:0 local /usr/X11R6/bin/X -dpi 100 -gamma 1.6
</PRE>

   <P>
   More information is in the X and Xserver man pages.

<P>
<HR>

<H2><A NAME="truetype">4. TrueType fonts (one of the few things Windows is good for)</A></H2>

   <P>
   Because the boys at Redmond are very concerned with the appearance
   of their software (as opposed to the internal workings ;) they
   built TrueType font support into Windows.  Windows 95 and nearly
   every other variety of Windows comes with Arial, Times New Roman, and
   Courier New, which are roughly equivalant to Helvetica, Times and
   Courier.  TrueType fonts are scalable, so they look good in large
   sizes, and they are well hinted, so they are readable at small sizes.
   Many windows applications come with dozens of TrueType fonts.  Don't
   microwave your Windows CD yet, you'll want to get the fonts first.

   <H3><A NAME="xfstt">4.1 xfstt</A></H3>

      <P>
      Unfortunately, XFree86 does not come with built in TrueType
      support, so you'll have to add it yourself.  The easiest way of
      doing this is with xfstt, a free TrueType font server.

      <H4><A NAME="install">4.1.1 Installation</A></H4>

         <P>
         xfstt is very easy to install.  First, you'll want to download
	 the tarball from the web.  The most current version is at
	 <A HREF="http://metalab.unc.edu/pub/Linux/X11/fonts/Xfstt-0.9.10.tgz";>
	 http://metalab.unc.edu/pub/Linux/X11/fonts/Xfstt-0.9.10.tgz</A>

         <P>
	 Once you have the tarball, untar it.
<PRE>
tar -zxvf Xfstt-0.9.10.tgz
</PRE>

         <P>
	 Then build it and install it.  Read the INSTALL file for quick
	 instructions, but it's a no brainer.  <TT>make; make
	 install</TT> is all you have to do.  Once that's done, copy
	 the TrueType fonts you've managed to get from various sources
	 to <TT>/usr/ttfonts</TT>, and you're ready to go.  Start
	 xfstt by typing

<PRE>
xfstt --sync        # updates xfstt's font database
xfstt &             # runs xfstt in the background.
</PRE>

         <P>
         Then type 

<PRE>
xset +fp unix/:7100 # tells X about xfstt.
</PRE>
	 
         <P>
	 or add 

<PRE>
FontPath "unix/:7100"
</PRE>

         <P>
         to your <TT>XF86Config</TT> to tell X about the font service.

      <H4><A NAME="defaultsize">4.1.2 Adjusting the default font size.</A></H4>

         <P>
         If your TrueType fonts appear to be very tiny, the following
	 commands help.

         <P>
         Add the <TT>-dpi</TT> switch to your X server command line
	 (see section 3 to do this.)

         <P>
         Use the <TT>--res</TT> switch to tell xfstt to increase the
	 default resolution.  Use the following command line.

<PRE>
xfstt --res 120
</PRE>

<HR>

<H2><A NAME="kde">5. KDE</A></H2>

   <P>
   KDE is one of the best things that have happened to Linux and X in a
   long time.  It provides a consistent user interface that goes a long
   way towards making Linux accessable to the average non-geek.  More
   information about KDE can be found at <A HREF="http://www.kde.org/";>
   http://www.kde.org/</A>.  So why am I singing it's praises here?
   This is because KDE 1.1 has a new feature that will make the fonts
   & colors in your programs, including non-KDE applications consistent
   with KDE's current style.

   <H3><A NAME="kdestyle">5.1 Applying KDE font & colors to non KDE apps.</A></H3>

      <P>
      This is very easy.  Simply start up the KDE Control Center, go to
      Desktop, and go to Style inside Desktop.  In there, there will be
      a toggle switch labled "Apply fonts and colors to non-KDE apps".
      Turn it on, click OK, and your done!  The next time you start up
      many X applications, they will use the same colors and fonts that
      your KDE applications do.  Some people may like this feature
      better than others, but if you don't like it you can always turn
      it off.

<P>
<HR>

<H2><A NAME="apps">6. Adjusting fonts in specific applications:</A></H2>

   <H3><A NAME="netscape">6.1 Netscape Navigator/Communicator</A></H3>
   
      <P>
      Netscape Communicator is particularly susceptible to font
      problems.  If you're using the default FontPath, your fonts will
      be very tiny and very ugly.  The first thing you'll want to do is
      fix your XF86Config FontPath (see section 2.)  Using 100dpi fonts
      improves readability immensly.  You'll also want check your font
      settings under Edit/Preferences, under Appearance/Fonts.  To get
      rid of bitmap font pixelization, turn off the option "Allow
      Scaling" on the font selection.  

      <P>
      If you have xfstt, Netscape is perfectly capable of using TrueType
      fonts.  However, it doesn't handle xfstt's quirkiness very
      gracefully.  In Edit/Preferences, you can specify TrueType fonts
      as the variable and fixed width fonts, however Netscape will not
      remember the size you've picked after you closed it.  If you
      haven't used the <TT>-dpi</TT> switch when starting the X server
      or used the <TT>--res</TT> switch in xfstt, you'll get very tiny
      fonts.  Once I applied these two fixes, TrueType fonts work great.

   <H3><A NAME="wordperfect">6.2 WordPerfect</A></H3>

      <P>
      Coming soon.

   <H3><A NAME="staroffice">6.3 StarOffice</A></H3>

      <P>
      Coming soon.

<P>
<HR>

<H2><A NAME="credits">7. Credits</A></H2>
   <P>
   Created by Doug Holland<BR>
   Email: <A HREF="mailto:meldroc@xxxxxxxx";>meldroc@xxxxxxxx</A><BR>
   WWW: <A HREF="http://www.frii.com/~meldroc/";>http://www.frii.com/~meldroc</A><BR>

   <P>
   Thanks go to:
   <UL>
      <LI>Hilary, my girlfriend, who endured my long hours of geeking
          out in front of the computer and for being the best friend I
	  could ever have.
      <LI>The folks at <A HREF="news:comp.os.linux.x";>comp.os.linux.x</A>
          who gave me a hand in figuring all of this out in the first
	  place.
      <LI>The Linux community in general who made all of this possible
          in the first place.
      <LI>Microsoft and Apple: for providing the fonts that adorn my
      desktop.
   </UL>

<HR>

<H2><A NAME="legal">8. Legalities</A></H2>
<P>
Copyright &copy 1999 by Doug Holland.

<P>
Unless otherwise stated, Linux HOWTO documents are copyrighted by their
respective authors.  Linux HOWTO documents may be reproduced and distributed
in whole or in part, in any medium physical or electronic, as long as this
copyright notice is retained on all copies.  Commercial redistribution is
allowed and encouraged; however, the author would like to be notified of any
such distributions.

<P>
All translations, derivative works, or aggregate works incorporating
any Linux HOWTO documents must be covered under this copyright notice.
That is, you may not produce a derivative work from a HOWTO and impose
additional restrictions on its distribution. Exceptions to these rules
may be granted under certain conditions; please contact the Linux HOWTO
coordinator for more information. 

<P>
In short, we wish to promote dissemination of this information through
as many channels as possible. However, we do wish to retain copyright
on the HOWTO documents, and would very much like to be notified of any
plans to redistribute the HOWTOs, this one in particular!  Web page
authors are free to link to this HOWTO without restriction, though
the author would appreciate an email informing him of this, just so he
can boost his ego by knowing who else reads and links to this document.

<P>
Many of the terms mentioned in this document are trade names. Unless
otherwise stated, all trademarks are property of their respective owners. 

<P>
<HR>
8641 hits on this page.
</TD>
</TR>
</TABLE>
</BODY>
</HTML>



- --------------6307ED1614785692D85A2B2C--


- --------------------------------------------------------------------
For more information on Linux in India visit http://www.linux-india.org/
Linux India is NOT a forum for Microsoft/India/Pakistan/US/UK bashing.
Flame baits will not be tolerated.  If you can appreciate satire read
http://www.templetons.com/brad/emily.html

------------------------------

End of Linux India Digest V1 #68
********************************

--------------------------------------------------------------------
To unsubscribe send an email to majordomo@xxxxxxxxx with the word
'unsubscribe linux-india-digest' (without the quotes) in the body
of the email.