XBanner: Making XDM More Attractive

XBanner turns your boring, staid XDM login screen into one of those cool things you'll want to show all your friends (nonchalantly, of course).
Making the Link Between XDM and XBanner

Next, tell XDM to run XBanner by adding a line to XDM's Xsetup_0 script. This script runs before the login box pops up. Adding this will ensure that XBanner is run each time XDM wants to display the login box. The Xsetup_0 script is straightforward. Just add to the bottom of the file a line like this one:

/usr/local/bin/X11/xbanner -file \
/usr/local/etc/login_screen.res

Where login_screen.res (see Listing 2) contains the resources that generate the desired screen layout.

Listing 2. login_screen.res After XBanner draws its graphics, some server-side resources are left allocated (colormap entries) in order to ensure that programs running after XBanner can't alter the colors, and thereby make XBanner's graphics look a mess. The freetemp utility is the program that tells the X server to release the colormap entries. Also, it should be noted that some of the nicer features of XBanner, such as color-cycling and glittering stars, are done by leaving a process running, which must then be stopped before logging in. The freetemp utility does all the work of stopping lingering processes and releasing the colormap entries.

The best place to run freetemp is from the Xsession file. This file is run for each logged-in user. Place the freetemp line as close to the top of the file as possible, and make sure it is not within the context of an if statement or some other script element which might prevent it from running. As a safety measure, you can add a call to freetemp right before the call to xbanner in the Xsetup_0 script. This call is done just as a precautionary measure; it might save you in case something unexpected happened when the previous user logged out.

Creating a Resource File

The simplest way to start is to check out the many examples included in the installation. I have included samples of everything I could think of: color-cycling, multiple lines, glinting stars, different backgrounds, pixmaps, etc. The files in the samples/Demo/ directory are provided to serve as a template. Simply pick one and start modifying it. Experiment with the options until you find a look that pleases you.

The XBanner documentation is made up of two main files and some supplementary files. The file XBanner_Users_Guide.html contains, among other things, a hands-on structured guide to building a resource file from scratch. Follow the steps, and each click will bring you to the related resources and the available possibilities.

The file Resource_Reference.html contains a complete reference of all the resources XBanner recognizes. Each resource is given with its class name, an extensive explanation of what this resource does, what values it accepts and the command-line equivalent. The file also contains a description of the different types of resources XBanner uses, and some ideas.

This should be all you need to create a resource file. But of course, you can send me e-mail for suggestions and ideas. Many of the features of XBanner were implemented as a result of such questions.

Running the Demo

In order to run the demo properly—and in fact in order to use XBanner—you must have scalable fonts. These are fonts that can be scaled to any size without losing quality. XFree86 comes with a package of scalable fonts, and the XBanner documentation contains a special chapter about finding scalable fonts and installing them. You do not need XDM at all to be able to see the demo.

It is advisable that you close all applications before running the demo, to allow XBanner to allocate the necessary colors for the demo. Also, the best way to view the demo is with an empty screen with only a single small xterm located close to the bottom of the screen from which to run the demo.

After compilation, go to the directory samples/Demo/ and enter ./Demo or ./Demo.bash (if your system does not have csh).

Credits

I'd like to thank Oren Tirosh (orenti@hiker.org.il) for many hours of help, support, ideas, algorithms and more. Thanks also to Rich McClelan of Fullerton University for all the help he's given me in setting up the web pages, and getting me the space.

Thanks to Ben Spade (spade@spade.com) and Chris Yeo (Chris.Yeo@usask.ca) for their help with the documentation of XBanner 1.3, and other stuff.

Thanks also to the hundreds of people who have notified me about bugs, offered ideas, requested features, or sent me a pat on the back by e-mail.

Amit Margalit works for Digital in Israel in X11/Motif programming support. He started using Linux back in the happy days of Linux 0.99.12 and is preaching for the migration to Linux at every opportunity. He may be reached at amitm@doronx.iso.dec.com and amitm@netvision.net.il.

______________________

Webinar
One Click, Universal Protection: Implementing Centralized Security Policies on Linux Systems

As Linux continues to play an ever increasing role in corporate data centers and institutions, ensuring the integrity and protection of these systems must be a priority. With 60% of the world's websites and an increasing share of organization's mission-critical workloads running on Linux, failing to stop malware and other advanced threats on Linux can increasingly impact an organization's reputation and bottom line.

Learn More

Sponsored by Bit9

Webinar
Linux Backup and Recovery Webinar

Most companies incorporate backup procedures for critical data, which can be restored quickly if a loss occurs. However, fewer companies are prepared for catastrophic system failures, in which they lose all data, the entire operating system, applications, settings, patches and more, reducing their system(s) to “bare metal.” After all, before data can be restored to a system, there must be a system to restore it to.

In this one hour webinar, learn how to enhance your existing backup strategies for better disaster recovery preparedness using Storix System Backup Administrator (SBAdmin), a highly flexible bare-metal recovery solution for UNIX and Linux systems.

Learn More

Sponsored by Storix