Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Debian GNU/Linux Reference Guide
Prev Home Next

9.4.4 X clients

Most X client programs can be started with a command like this:

     client $ xterm -geometry 80x24+30+200 -fn 6x10 -display hostname:0 &

Here, the optional command-line arguments mean:

  • -geometry WIDTHxHEIGHT+XOFF+YOFF: the initial size and location of the window.

  • -fn FONTNAME: the font to use for displaying text. FONTNAME can be:

    • a14: Normal size font

    • a24: Large size font

    • ... (check available fonts with xlsfont.)

  • -display displayname: the name of the X server to use. displayname can be:

    • hostname:D.S means screen S on display D of host hostname; the X server for this display is listening to TCP port 6000+D.

    • host/unix:D.S means screen S on display D of host host; the X server for this display is listening to UNIX domain socket /tmp/.X11-unix/XD (so it's only reachable from host).

    • :D.S is equivalent to host/unix:D.S, where host is the local hostname.

The default displayname for the X client program (application side) can be set by the DISPLAY environment variable. For example, prior to running an X client program, executing one of the following commands achieves this:

     $ export DISPLAY=:0 
             # The default, local machine using the first X screen
     $ export DISPLAY=hostname.fulldomain.name:0.2
     $ export DISPLAY=localhost:0

Its startup can be customized by ~/.xinitrc. For example:

     xrdb -load $HOME/.Xresources
     xsetroot -solid gray &
     xclock -g 50x50-0+0 -bw 0 &
     xload -g 50x50-50+0 -bw 0 &
     xterm -g 80x24+0+0 &
     xterm -g 80x24+0-0 &
     twm

As described in Custom X sessions, Section 9.4.5.1, this overrides everything normal execution of Xsession does when started from startx. Use ~/.xsession instead and use this approach only as the last resort. See xsetroot(1x), xset(1x), and X resources, Section 9.4.10.


Debian GNU/Linux Reference Guide
Prev Home Next

 
 
  Published under the terms of the GNU General Public License Design by Interspire