Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
2.  Configuring Session Manager When a Session Starts Sourcing Xsession.d Scripts  Previous   Contents   Next 
   
 

Displaying the Welcome Message

After sourcing HomeDirectory/.dtprofile and the Xsession.d scripts, Xsession displays a welcome message that covers the screen. You can customize the welcome message displayed, or turn off the message entirely. The dthello client is used to display the message.

To alter the message text, change the dthello options by modifying the dtstart_hello[0] variable.

To change dtstart_hello[0], create an /etc/dt/config/Xsession.d script that sets the new value. To display the message of the day for all users, create an executable sh or ksh script, for example /etc/dt/config/Xsession.d/myvars, and set dtstart_hello[0] as follows:

dtstart_hello[0]="/usr/dt/bin/dthello -file /etc/motd &"

Similarly, users can change the welcome message for their sessions by setting dtstart_hello[0] in HomeDirectory/.dtprofile.

To turn off the welcome message, set dtstart_hello[0]=" ".

For more information about dthello, see the dthello man page.

Setting Up the Desktop Search Paths

The desktop search paths are created at login by dtsearchpath. There are two categories of environment variables used by dtsearchpath:

Input Variables--System-wide and personal environment variables whose values are set by the system administrator or end user.

Output Variables--Variables created and assigned values by dtsearchpath. The value of each variable is the search path for the desktop session.

To alter the command-line options of dtsearchpath, modify the dtstart_searchpath variable. To change the dtstart_searchpath variable for all users, create an executable sh or ksh script (for example /etc/dt/config/Xsession.d/myvars), and set dtstart_searchpath as follows:

dtstart_searchpath="/usr/dt/bin/dtsearchpath"

Users can similarly change the dtsearchpath options for only their own sessions by setting dtstart_searchpath in HomeDirectory/.dtprofile.

For more information about dtsearchpath, see Chapter 9, Desktop Search Paths. For more information about dtsearchpath options, see the dtsearchpath man page.

Gathering Available Applications

The next step after setting up the desktop search paths is to gather available applications using dtappgather. To alter the command-line options of dtappgather, modify the dtstart_appgather variable. To change the dtstart_appgather variable for all users, create an executable sh or ksh script (for example /etc/dt/config/Xsession.d/myvars), and set dtstart_appgather as follows:

dtstart_appgather="/usr/dt/bin/dtappgather &"

Users can similarly change the dtappgather options for only their own sessions by setting dtstart_appgather in HomeDirectory/.dtprofile.

For more information about dtappgather options, see the dtappgather(4) man page.

Optionally Sourcing the .profile or .login Script

Xsession is able to source a user's traditional HomeDirectory/.profile or HomeDirectory/.login scripts. By default this capability is disabled. To tell Xsession to source the .profile or .login script, set DTSOURCEPROFILE to true.

To change DTSOURCEPROFILE for all users, create an /etc/dt/config/Xsession.d script that sets the new value. To set DTSOURCEPROFILE to true for all users, create an executable sh or ksh script, for example /etc/dt/config/Xsession.d/myvars, and set DTSOURCEPROFILE as follows:

DTSOURCEPROFILE=true

Users can similarly change DTSOURCEPROFILE for their own sessions by setting DTSOURCEPROFILE to true in HomeDirectory/.dtprofile.

Starting the ToolTalk Messaging Daemon

The ToolTalk messaging daemon, ttsession, enables independent applications to communicate with each other without having direct knowledge of each other. Applications create and send ToolTalk messages to communicate with each other. ttsession communicates on the network to deliver messages.

To alter the command-line options of ttsession, modify the dtstart_ttsession variable. To change the dtstart_ttsession variable for all users, create an executable sh or ksh script (for example /etc/dt/config/Xsession.d/myvars), and set dtstart_ttsession as follows:

dtstart_ttsession="/usr/dt/bin/ttsession -s"

Users can similarly change the ttsession options for their own sessions by setting dtstart_ttsession in HomeDirectory/.dtprofile.

For more information about ttsession options, see the ttsession man page. For more information on ttsession, see Common Desktop Environment: ToolTalk Messaging Overview.

Starting the Session Manager Client

At this point, Xsession starts /usr/dt/bin/dtsession, which continues the session startup process.

Loading the Session Resources

Session Manager uses the X server RESOURCE_MANAGER property to make desktop resources available to all applications. Session Manager loads the RESOURCE_MANAGER by:

  • Loading the system default resources

  • Merging any system-wide resources specified by the system administrator

  • Merging any user-specified resources

The desktop default resources can be found in /usr/dt/config/language/sys.resources. These resources will be made available to each user's session via the RESOURCE_MANAGER property. This file should not be edited, as it is overwritten upon subsequent desktop installations.

You can augment the system default resources by creating /etc/dt/config/language/sys.resources. In this file, you can override default resources or specify additional resources for all desktop users. Since this file is merged into the desktop default resources during session startup, only new or updated resource specifications should be placed in this file. Resources specified in this file will be made available to each user's session through the RESOURCE_MANAGER property. Resources specified in this file take precedence over those specified in the desktop default resource file.

Users can augment the desktop default and system-wide resources using their HomeDirectory/.Xdefaults file. Resources specified in this file will be made available to that user's session through the RESOURCE_MANAGER property. Resources specified in this file take precedence over those specified in the desktop default or system administrator resource files.


Note - The X Toolkit Intrinsics utility specifies that it will load resources for an application from either RESOURCE_MANAGER or from HomeDirectory/.Xdefaults, but not both. Ordinarily, this would mean that the user's HomeDirectory/.Xdefaults file would be ignored. However, Session Manager accommodates HomeDirectory/.Xdefaults by merging it into the RESOURCE_MANAGER at session startup as described above. If a user changes HomeDirectory/.Xdefaults, the changes will not be visible to new applications until the user invokes the Reload Resources action. The Reload Resources action will instruct Session Manager to reload the RESOURCE_MANAGER with the default, system-wide, and user-specified resources. This makes changes to the system-wide and personal resource files available to applications.


For more information see:

Starting the Color Server

Session Manager serves as the color server for the desktop and provides the following set of dtsession resources that can be used to configure it.

foregroundColor--controls whether a pixel is allocated for the foreground color

dynamicColor--specifies whether read-only colors are allocated

shadowPixmaps--specifies whether colors are allocated for top shadow or bottom shadow

colorUse--limits color allocation

writeXrdbColors--specifies whether the *background and *foreground resources are placed in the resource database

You can set color server resources for all users by creating /etc/dt/config/language/sys.resources and specifying the color server resources in that file.

Users can similarly set color server resources for their own sessions by specifying color server resources in HomeDirectory/.Xdefaults.

For more information about setting color server resources, see "Administering Colors".

Starting Workspace Manager

Session Manager is responsible for starting Workspace Manager. By default /usr/dt/bin/dtwm is started. An alternate window manager can be specified with the wmStartupCommand resource.

You can specify an alternate window manager for all users by creating /etc/dt/config/language/sys.resources and specifying the full path name and options for the window manager with the Dtsession*wmStartupCommand resource in that file.

Users can similarly specify an alternate window manager for their own sessions only by specifying the Dtsession*wmStartupCommand resource in HomeDirectory/.Xdefaults.

For more information about the Window Manager, see Chapter 16, Customizing the Workspace Manager.

 
 
 
  Previous   Contents   Next