Whitespace cleanup.

This can safely be ignonred by translators.

. Indent <screen> and <programlisting>.
. Add spacing to <listitems>.
. Wrap lines longer than 80 chars
. Remove eol whitespace.
This commit is contained in:
Giorgos Keramidas 2002-08-25 23:44:31 +00:00
parent 51f361fa4e
commit 105d40844f
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/head/; revision=14016

View file

@ -10,24 +10,41 @@
<sect1>
<title>Synopsis</title>
<para>FreeBSD uses <application>XFree86</application> to provide users with a powerful
graphical user interface. <application>XFree86</application> is an open-source
implementation of the X Window System. This chapter
will cover installation and configuration of <application>XFree86</application> on a
FreeBSD system. For more information on <application>XFree86</application> and
video hardware that it supports, check the <ulink
<para>FreeBSD uses <application>XFree86</application> to provide users with
a powerful graphical user interface. <application>XFree86</application>
is an open-source implementation of the X Window System. This chapter
will cover installation and configuration of
<application>XFree86</application> on a FreeBSD system. For more
information on <application>XFree86</application> and video hardware that
it supports, check the <ulink
url="http://www.XFree86.org/">XFree86</ulink> web site.</para>
<para>After reading this chapter, you will know:</para>
<itemizedlist>
<listitem>
<para>The various components of the X Window System, and how they
interoperate.</para>
</listitem>
<listitem><para>How to install and configure <application>XFree86</application>.</para></listitem>
<listitem><para>How to install and use different window managers.</para></listitem>
<listitem><para>How to use TrueType fonts in <application>XFree86</application>.</para></listitem>
<listitem><para>How to setup your system for graphical logins (<application>XDM</application>).</para></listitem>
<listitem>
<para>How to install and configure
<application>XFree86</application>.</para>
</listitem>
<listitem>
<para>How to install and use different window managers.</para>
</listitem>
<listitem>
<para>How to use TrueType fonts in
<application>XFree86</application>.</para>
</listitem>
<listitem>
<para>How to setup your system for graphical logins
(<application>XDM</application>).</para>
</listitem>
</itemizedlist>
<para>Before reading this chapter, you should:</para>
@ -144,8 +161,9 @@
window managers, and many more, are available in the
<filename>x11-wm</filename> category of the Ports Collection.</para>
<para>In addition, the <application>KDE</application> and <application>GNOME</application> desktop environments both have
their own window managers which integrate with the desktop.</para>
<para>In addition, the <application>KDE</application> and
<application>GNOME</application> desktop environments both have their
own window managers which integrate with the desktop.</para>
<para>Each window manager also has a different configuration mechanism;
some expect configuration file written by hand, others feature
@ -256,36 +274,34 @@
<sect1 id="x-install">
<title>Installing XFree86</title>
<para>Before installing <application>XFree86</application>, decide on which version to
run. <application>XFree86 3.X</application> is a maintenance
branch of <application>XFree86</application> development. It is very stable, and it
supports a huge number of graphics cards. However, no new
<para>Before installing <application>XFree86</application>, decide on which
version to run. <application>XFree86 3.X</application> is a maintenance
branch of <application>XFree86</application> development. It is very
stable, and it supports a huge number of graphics cards. However, no new
development is being done on the software. <application>XFree86
4.X</application> is a complete redesign of the system with many
new features such as better support for fonts and
anti-aliasing. Unfortunately this new architecture requires
that the video drivers be rewritten, and some of the older
cards that were supported in 3.X are not yet supported in 4.X. As all
new developments and support for new graphics cards are done on that
branch, <application>XFree86 4.X</application> is now the default
version of the X Window System on FreeBSD.</para>
4.X</application> is a complete redesign of the system with many new
features such as better support for fonts and anti-aliasing.
Unfortunately this new architecture requires that the video drivers be
rewritten, and some of the older cards that were supported in 3.X are not
yet supported in 4.X. As all new developments and support for new
graphics cards are done on that branch, <application>XFree86
4.X</application> is now the default version of the X Window System on
FreeBSD.</para>
<para>The FreeBSD setup program offers users the opportunity to install
and configure <application>XFree86 4.X</application> during installation (covered in
<xref linkend="x-server">). To install and run
and configure <application>XFree86 4.X</application> during installation
(covered in <xref linkend="x-server">). To install and run
<application>XFree86 3.X</application>, wait until after the base
FreeBSD system is installed, and then install <application>XFree86</application>. For example,
to build and install <application>XFree86 3.X</application> from the
ports collection:</para>
FreeBSD system is installed, and then install
<application>XFree86</application>. For example, to build and install
<application>XFree86 3.X</application> from the ports collection:</para>
<screen>&prompt.root; <userinput>cd /usr/ports/x11/XFree86</userinput>
&prompt.root; <userinput>make all install clean</userinput></screen>
<para>Alternatively, either version of <application>XFree86</application> can be
installed
directly from the FreeBSD
binaries provided on the <ulink
url="http://www.XFree86.org/">XFree86 web site</ulink>. A binary
<para>Alternatively, either version of <application>XFree86</application>
can be installed directly from the FreeBSD binaries provided on the
<ulink url="http://www.XFree86.org/">XFree86 web site</ulink>. A binary
package to use with &man.pkg.add.1; tool is also available for
<application>XFree86 4.X</application>. When the remote fetching
feature of &man.pkg.add.1; is used, the version number of the
@ -303,7 +319,8 @@
&prompt.root; <userinput>make install clean</userinput></screen>
<para>The rest of this chapter will explain how to configure
<application>XFree86</application>, and how to setup a productive desktop environment.</para>
<application>XFree86</application>, and how to setup a productive desktop
environment.</para>
<!-- Easiest way is from sysinstall for XFree86 4.X -->
@ -469,10 +486,10 @@ EndSection</programlisting>
seven hundred sixty-eight pixels at twenty-four bits per pixel,
add the <varname>DefaultDepth</varname> keyword with the
value of twenty-four, and add to the <literal>"Display"</literal>
subsection with the desired <varname>Depth</varname> the <varname>Modes</varname> keyword with the
resolution the user wishes to run at. Note that only VESA
standard modes are supported as defined by the target system's
graphics hardware.</para>
subsection with the desired <varname>Depth</varname> the
<varname>Modes</varname> keyword with the resolution the user wishes to
run at. Note that only VESA standard modes are supported as defined by
the target system's graphics hardware.</para>
<para>Finally, write the configuration file and test it using
the test mode given above. If all is well, the configuration
@ -524,8 +541,8 @@ EndSection</programlisting>
<para>This will allow configuration of the hardware as any other
graphics board.</para>
<para>If you are using <application>XFree86 4.1.0</application> (or later) and messages
about unresolved symbols like
<para>If you are using <application>XFree86 4.1.0</application> (or
later) and messages about unresolved symbols like
<literal>fbPictureInit</literal> appear, try adding the
following line after <literal>Driver "i810"</literal> in the
<application>XFree86</application> configuration file:</para>
@ -551,10 +568,10 @@ EndSection</programlisting>
<para>The default fonts that ship with
<application>XFree86</application> are less than ideal for typical
desktop publishing applications. Large presentation fonts show up
jagged and unprofessional looking, and small fonts in <application>Netscape</application> are
almost completely unintelligible. However, there are several
free, high quality Type1 (PostScript) fonts available which
can be readily used
jagged and unprofessional looking, and small fonts in
<application>Netscape</application> are almost completely unintelligible.
However, there are several free, high quality Type1 (PostScript) fonts
available which can be readily used
with <application>XFree86</application>, either version 3.X or
version 4.X. For instance, the URW font collection
(<filename role="package">x11-fonts/urwfonts</filename>) includes
@ -562,8 +579,8 @@ EndSection</programlisting>
Helvetica, Palatino and others). The Freefont collection
(<filename role="package">x11-fonts/freefont</filename>) includes
many more fonts, but most of them are intended for use in
graphics software such as the <application>Gimp</application>, and are not complete
enough to serve as screen fonts. In addition,
graphics software such as the <application>Gimp</application>, and are not
complete enough to serve as screen fonts. In addition,
<application>XFree86</application> can be configured to use
TrueType fonts with a minimum of effort: see the
<link linkend="truetype">section on TrueType fonts</link> later.</para>
@ -574,12 +591,11 @@ EndSection</programlisting>
<screen>&prompt.root; <userinput>cd /usr/ports/x11-fonts/urwfonts</userinput>
&prompt.root; <userinput>make install clean</userinput></screen>
<para>And likewise with the freefont or other collections. To tell the X server
that these fonts exist, add an appropriate line to the
<filename>XF86Config</filename> file (in
<filename>/etc/</filename> for <application>XFree86</application>
version 3, or in <filename>/etc/X11/</filename> for version 4),
which reads:</para>
<para>And likewise with the freefont or other collections. To tell the X
server that these fonts exist, add an appropriate line to the
<filename>XF86Config</filename> file (in <filename>/etc/</filename> for
<application>XFree86</application> version 3, or in
<filename>/etc/X11/</filename> for version 4), which reads:</para>
<programlisting>FontPath "/usr/X11R6/lib/X11/fonts/URW/"</programlisting>
@ -617,7 +633,8 @@ EndSection</programlisting>
TrueType font server is needed.
<application>Xfstt</application> is commonly used for
this purpose. To install <application>Xfstt</application>,
simply install the port <filename role="package">x11-servers/Xfstt</filename>.</para>
simply install the port
<filename role="package">x11-servers/Xfstt</filename>.</para>
<para>Now make a directory for the TrueType fonts (for example,
<filename>/usr/X11R6/lib/X11/fonts/TrueType</filename>)
@ -630,7 +647,8 @@ EndSection</programlisting>
<filename>fonts.dir</filename> file, so that the X font renderer
knows that these new files have been installed.
<command>ttmkfdir</command> is available from the FreeBSD
Ports Collection as <filename role="package">x11-fonts/ttmkfdir</filename>.</para>
Ports Collection as
<filename role="package">x11-fonts/ttmkfdir</filename>.</para>
<screen>&prompt.root; <userinput>cd /usr/X11R6/lib/X11/fonts/TrueType</userinput>
&prompt.root; <userinput>ttmkfdir > fonts.dir</userinput></screen>
@ -708,8 +726,8 @@ edit
<programlisting>match any family == "fixed" edit family =+ "mono";
match any family == "console" edit family =+ "mono";</programlisting>
<para>(this aliases the other common names for fixed fonts as <literal>"mono"</literal>),
and then add:</para>
<para>(this aliases the other common names for fixed fonts as
<literal>"mono"</literal>), and then add:</para>
<programlisting>match any family == "mono" edit spacing = 100;</programlisting>
@ -740,9 +758,9 @@ match any family == "LuciduxMono" edit family =+ "Lucidux Mono";</programl
<programlisting>match edit rgba=rgb;</programlisting>
<para>(depending on the sort of display, the last word may need to
be changed from <quote>rgb</quote> to <quote>bgr</quote>, <quote>vrgb</quote>
or <quote>vbgr</quote>: experiment and see which works best.)</para>
be changed from <quote>rgb</quote> to <quote>bgr</quote>,
<quote>vrgb</quote> or <quote>vbgr</quote>: experiment and see which
works best.)</para>
<para>Anti-aliasing should be enabled the next time the X server is
started. However, note that programs must know how to take
@ -754,8 +772,8 @@ match any family == "LuciduxMono" edit family =+ "Lucidux Mono";</programl
details); there are patches for GTK+ to do the same,
so if compiled against such a patched GTK+, the GNOME environment
and Mozilla can also use anti-aliased fonts. In fact, there
is now a port called <filename role="package">x11/gdkxft</filename> which allows one
to use antialiased fonts without recompiling: see
is now a port called <filename role="package">x11/gdkxft</filename>
which allows one to use antialiased fonts without recompiling: see
<xref linkend="x11-wm-gnome-antialias"> for details.</para>
<para>Anti-aliasing is still new to FreeBSD and
@ -977,6 +995,7 @@ match any family == "LuciduxMono" edit family =+ "Lucidux Mono";</programl
<sect2>
<title>Running a Network Display Server</title>
<para>In order for other clients to connect to the display
server, edit the access control rules, and enable the connection
listener. By default these are set to conservative values.
@ -1056,7 +1075,8 @@ DisplayManager.requestPort: 0</screen>
<para>The easiest way to install
<application>GNOME</application> is through the
<quote>Desktop Configuration</quote> menu during the FreeBSD
installation process as described in <xref linkend="default-desktop"> of Chapter 2. It can also
installation process as described in <xref
linkend="default-desktop"> of Chapter 2. It can also
be easily installed from a package or the ports
collection:</para>
@ -1110,13 +1130,14 @@ DisplayManager.requestPort: 0</screen>
<title>Anti-aliased fonts with GNOME</title>
<para>While anti-aliased fonts made their first appearance on
<application>XFree86</application> desktops in the <application>KDE</application> environment and are supported
there in the standard installation, it is also possible to
use them with GTK applications such as the <application>GNOME</application>
<application>XFree86</application> desktops in the
<application>KDE</application> environment and are supported there
in the standard installation, it is also possible to use them with
GTK applications such as the <application>GNOME</application>
environment. The most straightforward way is probably by
using the <application>libgdkxft</application> library, in
the <filename role="package">x11/gdkxft</filename> port. After installing this
port, read the
the <filename role="package">x11/gdkxft</filename> port. After
installing this port, read the
<filename>/usr/X11R6/share/doc/gdkxft/README</filename> file
carefully.</para>
@ -1134,17 +1155,13 @@ DisplayManager.requestPort: 0</screen>
<para>and with csh and similar shells, type</para>
<screen>
&prompt.user; <userinput>setenv LD_PRELOAD /usr/X11R6/lib/libgdkxft.so</userinput>
&prompt.user; <userinput>gimp</userinput>
</screen>
<screen>&prompt.user; <userinput>setenv LD_PRELOAD /usr/X11R6/lib/libgdkxft.so</userinput>
&prompt.user; <userinput>gimp</userinput></screen>
<para>Or, the commands</para>
<programlisting>
LD_PRELOAD=/usr/X11R6/lib/libgdkxft.so
export LD_PRELOAD
</programlisting>
<programlisting>LD_PRELOAD=/usr/X11R6/lib/libgdkxft.so
export LD_PRELOAD</programlisting>
<para>can be put into <filename>.xinitrc</filename>,
<filename>.xsession</filename> or in the appropriate
@ -1167,20 +1184,45 @@ export LD_PRELOAD
<application>KDE</application> brings to the user are:</para>
<itemizedlist>
<listitem><para>A beautiful contemporary desktop</para></listitem>
<listitem><para>A desktop exhibiting complete network transparency</para></listitem>
<listitem><para>An integrated help system allowing for convenient,
<listitem>
<para>A beautiful contemporary desktop</para>
</listitem>
<listitem>
<para>A desktop exhibiting complete network transparency</para>
</listitem>
<listitem>
<para>An integrated help system allowing for convenient,
consistent access to help on the use of the
<application>KDE</application> desktop and its
applications</para></listitem>
<listitem><para>Consistent look and feel of all
<application>KDE</application> applications</para></listitem>
<listitem><para>Standardized menu and toolbars, keybindings, color-schemes, etc.</para></listitem>
<listitem><para>Internationalization: <application>KDE</application>
is available in more than 40 languages</para></listitem>
<listitem><para>Centralized consisted dialog driven desktop configuration</para></listitem>
<listitem><para>A great number of useful
<application>KDE</application> applications</para></listitem>
applications</para>
</listitem>
<listitem>
<para>Consistent look and feel of all
<application>KDE</application> applications</para>
</listitem>
<listitem>
<para>Standardized menu and toolbars, keybindings, color-schemes,
etc.</para>
</listitem>
<listitem>
<para>Internationalization: <application>KDE</application>
is available in more than 40 languages</para>
</listitem>
<listitem>
<para>Centralized consisted dialog driven desktop
configuration</para>
</listitem>
<listitem>
<para>A great number of useful
<application>KDE</application> applications</para>
</listitem>
</itemizedlist>
<para><application>KDE</application> has an office application
@ -1203,9 +1245,9 @@ export LD_PRELOAD
other desktop environment, the easiest way to install
<application>KDE</application> is through the <quote>Desktop
Configuration</quote> menu during the FreeBSD installation
process as described in <xref linkend="default-desktop"> of Chapter 2. Once again, the software
can be easily installed from a package or from the ports
collection:</para>
process as described in <xref linkend="default-desktop"> of Chapter
2. Once again, the software can be easily installed from a package
or from the ports collection:</para>
<para>To install the <application>KDE</application> package
from the network, simply type:</para>
@ -1225,7 +1267,8 @@ export LD_PRELOAD
<screen>&prompt.user; <userinput>echo "exec startkde" &gt; ~/.xinitrc</userinput></screen>
<para>Now, whenever the X Window System is invoked with <command>startx</command>,
<para>Now, whenever the X Window System is invoked with
<command>startx</command>,
<application>KDE</application> will be the desktop.</para>
<para>If a display manager such as
@ -1281,8 +1324,9 @@ export LD_PRELOAD
group in <filename>/etc/group</filename> for this), and then
type <userinput>kcontrol</userinput>.</para>
<para> Click on the icon on the left marked <guibutton>System</guibutton>, then on
<guibutton>Login manager</guibutton>. On the right there are
<para>Click on the icon on the left marked
<guibutton>System</guibutton>, then on <guibutton>Login
manager</guibutton>. On the right there are
various configurable options, which the
<application>KDE</application> manual will explain in greater
detail. Click on <guibutton>sessions</guibutton> on the right.
@ -1321,10 +1365,12 @@ export LD_PRELOAD
;;
esac
esac</screen>
<para>A few lines need to be added to this section.
Assuming the labels from used were <quote>KDE</quote> and
<quote>GNOME</quote>,
use the following:</para>
<screen>case $# in
1)
case $1 in
@ -1344,6 +1390,7 @@ esac</screen>
login-time desktop background to be honored,
the following line needs to be added to
<filename>/usr/X11R6/lib/X11/xdm/Xsetup_0</filename>:</para>
<screen>/usr/local/bin/kdmdesktop</screen>
<para>Now, make sure <application>kdm</application> is listed in
@ -1359,18 +1406,20 @@ esac</screen>
<para>Starting with version 4.0.2,
<application>XFree86</application> supports anti-aliasing via
its <quote>RENDER</quote> extension, and starting with version 2.3, Qt (the
toolkit used by <application>KDE</application>) supports this
extension. Configuring this is described in <xref
its <quote>RENDER</quote> extension, and starting with version 2.3,
Qt (the toolkit used by <application>KDE</application>) supports
this extension. Configuring this is described in <xref
linkend="antialias"> on antialiasing X11 fonts. So, with
up-to-date software, anti-aliasing is possible on a
<application>KDE</application> desktop. Just go to the KDE
menu, go to <guimenuitem>Preferences</guimenuitem> -> <guimenuitem>Look and Feel</guimenuitem> -> <guimenuitem>Fonts</guimenuitem>, and click
on the check box
menu, go to <guimenuitem>Preferences</guimenuitem> ->
<guimenuitem>Look and Feel</guimenuitem> ->
<guimenuitem>Fonts</guimenuitem>, and click on the check box
<guibutton>Use Anti-Aliasing for Fonts and Icons</guibutton>.
For a Qt application which is not part of
<application>KDE</application>, the environment variable <varname>QT_XFT</varname>
needs to be set to <literal>true</literal> before starting the program.</para>
<application>KDE</application>, the environment variable
<varname>QT_XFT</varname> needs to be set to <literal>true</literal>
before starting the program.</para>
</sect3>
</sect2>
@ -1391,22 +1440,41 @@ esac</screen>
are:</para>
<itemizedlist>
<listitem><para>A simple, easy-to-handle desktop</para></listitem>
<listitem><para>Fully configurable via mouse, with drag and
drop, etc </para></listitem>
<listitem><para>Main panel similar to <application>CDE</application>, with menus, applets and
app launchers</para></listitem>
<listitem><para>Integrated window manager, file manager,
sound manager, <application>GNOME</application> compliance module, and other things</para></listitem>
<listitem><para> Themeable (since it uses GTK) </para></listitem>
<listitem><para> Fast, light and efficient: ideal for
older/slower machines or machines with memory limitations</para></listitem>
<listitem>
<para>A simple, easy-to-handle desktop</para>
</listitem>
<listitem>
<para>Fully configurable via mouse, with drag and
drop, etc </para>
</listitem>
<listitem>
<para>Main panel similar to <application>CDE</application>, with
menus, applets and app launchers</para>
</listitem>
<listitem>
<para>Integrated window manager, file manager, sound manager,
<application>GNOME</application> compliance module, and other
things</para>
</listitem>
<listitem>
<para>Themeable (since it uses GTK)</para>
</listitem>
<listitem>
<para>Fast, light and efficient: ideal for older/slower machines
or machines with memory limitations</para>
</listitem>
</itemizedlist>
<para>More information on <application>XFce</application>
can be found on the <ulink url="http://www.xfce.org/">XFce
website</ulink>.</para>
</sect3>
<sect3 id="x11-wm-xfce-install">
<title>Installing XFce</title>
@ -1437,7 +1505,6 @@ esac</screen>
command; or, configure the display manager to allow
choosing a desktop at login time, as explained in
the section on <link linkend="x11-wm-kde-kdm">kdm</link>.</para>
</sect3>
</sect2>
</sect1>