[an error occurred while processing this directive]

HP OpenVMS Systems Documentation

Content starts here Getting Started With the New Desktop

Getting Started With the New Desktop


Previous Contents Index

3.4.3 Security Settings

In the DECwindows desktop, security access is enabled via Session Manager's Options pull-down menu. Once access is specified, changes are saved in the DECW$USER_DEFAULTS:DECW$SMB_SECURITY.DAT file (and referenced by the resource sm.host_list:).

When you first log in to the New Desktop, Session Manager (dtsession) reads any existing DECW$USER_DEFAULTS:DECW$SMB_SECURITY.DAT file and transfers the resource (sm.host_list:) to an appropriate resource (*hostList:) in the New Desktop. The resource is saved in your DT.RESOURCES file when you save a home session or exit your session.

You can modify security access for your session by using the graphical user interface provided in Style Manager. From the Style Manager menu bar, select Security and then add or delete authorized users.

3.4.4 Keyboard Settings

If you have a DECW$USER_DEFAULTS:DECW$SMB_KEYBOARD.DAT file in the DECwindows desktop environment, the value of the keyboard dialect resource (keyboard_dialect) is transferred to your New Desktop session when you first log in. The new name for this resource is *keyboardDialect.

You can use Style Manager to modify the keyboard dialect and input method selection. When you select the keyboard icon, a list box containing all possible keyboard mappings is displayed. When you select a keyboard mapping, it takes effect immediately. The resource is saved in your DT.RESOURCES file when you save a home session or exit your session.

3.4.5 Printer Management

Print Dialog provides the New Desktop with access to the DECwindows print widget for customizing and submitting print jobs. By default, Print Dialog saves its application state in the file disk$:[user.DT.TMP]DTPRINTINFO when the user clicks on the OK button. If the disk$:[user.DT.TMP] directory does not exist, or if the user does not click on the OK button prior to submitting the job, the Print Dialog settings selected are not used in the current print job.

If Print Dialog does not appear, or if the print job is not submitted, try deleting the latest version of the application state file in [username.DT.TMP] and reissuing the command.

3.4.5.1 Adding Printers to the Personal Printers Subpanel

Printers are represented as icons on the desktop. You can change the default printer and you can add additional printer icons to the Personal Printers subpanel, provided you have an action definition file, an action (stub) file, and an icon for each additional printer. The easiest way to create these three files is with the Create Action application (see Section 4.1.4).

A template printer action definition file is supplied with the New Desktop in the following location:


CDE$SYSTEM_DEFAULTS:[APPCONFIG.TYPES.C]PRINTER.DT_TEMPLATE

Read this file for instructions on creating printer action definitions.

You can add printer icons to the Personal Printers subpanel using the following steps:

  1. Display the printer icon using File Manager.
  2. Display the Personal Printer subpanel.
  3. Drag the printer icon from File Manager to the Personal Printer subpanel and drop it on the Install Icon item.

3.4.5.2 Creating a Printer Subpanel Control Definition File

Dropping a printer icon on the Install Icon control at the top of the Personal Printers subpanel automatically creates a printer subpanel control definition file and adds the new printer control to the bottom of the subpanel.

A template file for a printer subpanel control definition file is available in the following location:


CDE$SYSTEM_DEFAULTS:[APPCONFIG.TYPES.C]PRINTER.FP_TEMPLATE

Read this file for instructions on creating printer subpanel control definitions.

3.4.5.3 Changing the Default System Printer

To change the default system printer, add the following line to the
SYS$MANAGER:SYSTARTUP_VMS.COM file:


$ DEFINE/SYSTEM/EXECUTIVE_MODE SYS$PRINT printer-name

3.4.5.4 Changing the Default Printer for Your Own Use

The default printer is the printer associated with the Printer icon on the Front Panel. By default, this printer is defined by the value of the SYS$PRINT logical.

To change the default printer for your own use, add the following line to your LOGIN.COM file:


$ DEFINE SYS$PRINT printer-name

Alternatively, you can change the default printer for your own use by selecting a different printer from the list of available printers in the Printer Dialog box, as follows:

  1. Click on the printer icon on the Front Panel to display the Printer Dialog box.
  2. From the list of printers on your system, click on the printer you want as a new default printer.
  3. Click on OK.

Note that changing the default printer for Print Dialog does not change the default printer associated with the Print item on File Manager's Selected pop-up menu. You can change the default printer used by File Manager by following these steps:

  1. Click on the icon of the file you want to print.
  2. Click on the Selected item of the File Manager menu bar to display the Selected menu.
  3. Click on Print... to display the Printer Dialog box.
  4. From the list of printers on your system, click on the printer you want as a new default printer for File Manager.
  5. Click on OK.

The default printer and other options that you set using Print Dialog remain in effect until you change them again.

3.4.5.5 Print Dialog Command Line Options

Print Dialog accepts the command line options shown in Table 3-4. You can use these in a print command that you supply to the Create Action application (in the Add Datatype dialog box). You can also use them for printing a file from a DECterm with the options that you specified in the New Desktop environment, if you do not have access to the file's icon. You might also want to use Print Dialog from a DECterm for debugging print actions for your data types.

Table 3-4 Print Dialog Command Line Options
Option Description
-session sessionfile Loads the session file and restores the client to its original state on the desktop. By default, the session file name is determined at logout by the desktop.
-state statefile Loads the state file and restores the client to its original application state. By default, the state file is disk$:[ user.DT.TMP]DTPRINTINFO.
-interface Displays the Print Dialog interface. By default, this value is FALSE.
-unmanage Unmanages the Print Dialog interface when the user clicks on the OK button. By default, this value is TRUE.
-printer print-queue Specifies the name of the printer to receive the print job request. The printer name saved in the application state file takes precedence over this option. By default, this value is set to the value of the default printer.
-default print-queue Specifies the name of the default printer to receive the print job request. The printer name saved in the application state file takes precedence over this option. By default, this value is set to the value of the SYS$PRINT logical of the system or to the printer name specified with the -printer option.
filenames Path names of the files to be printed. If this argument is used with the -interface option, the files are printed when the user clicks on OK.
-usage Displays the command line options.

3.4.5.6 Starting Print Dialog From a Command Line

To run Print Dialog from a DECterm window, define the following symbol:



$ PRINTDIALOG :== $CDE$PATH:PRINTDIALOG

To display Print Dialog, enter the following command:



$ PRINTDIALOG -interface

To print a file, enter the following command:



$ PRINTDIALOG filename

3.4.6 Changing the Default Editor

The default editor of the New Desktop is the CDE Text Editor. If you prefer to use another editor, you can make it the default editor by following these steps:

  1. Copy the file CDE$SYSTEM_DEFAULTS:[APPCONFIG.TYPES.C]USER-PREFS.DT into your disk$:[user.DT.TYPES] subdirectory.
  2. Within the new copy of the file, revise the specification for "ACTION TextEditor".
    To use the DECwindows TPU editor, change MAP_ACTION from dtpad to dxeve. To run the TPU editor in a DECterm window, change MAP_ACTION from dtpad to tpuedit.

Both dxeve and tpuedit are preconfigured actions. These preconfigured actions may not be adequate if you are accustomed to editing with a customized TPU section file or with command files. To edit with a customized section file or with command files, you need to explicitly specify your edit command in an action definition file (see Section 4.1) and then map the TextEditor action to the new action name.

3.4.7 Window Colors and Screen Background

Window colors and screen background settings in the DECwindows desktop resource files (DECW$SMB_WINDOW_COLOR.DAT, DECW$SMB_BACKGROUND_COLOR.DAT) are not read into the New Desktop resources.

You can use Style Manager's Color dialog box to customize window colors and screen backgrounds in the New Desktop. You can specify a different background for each workspace, which can be useful for identifying them. You can also use the Color dialog box to troubleshoot the color display, as described in Section 3.6.

3.4.8 Window Manager Customizations

In the DECwindows desktop, Window Manager configuration customizations are specified in two files: DECW$MWM.DAT and DECW$MWM_RC.DAT. The New Desktop Window Manager supports configuration customization in two similar files: DTWM.DAT and SYS.DTWMRC, respectively.

3.4.8.1 Window Manager Resource File (DTWM.DAT)

The Window Manager default resource file, DTWM.DAT, is located in the CDE$SYSTEM_DEFAULTS:[APP-DEFAULTS.C] directory. Information stored in this file affects many aspects of the Window Manager, including the pointer focus, the icon box, the placement of the icon box, icon colors, use of the Front Panel, window border shading, window menu appearance, and workspace backdrop specifications. The following example shows part of the default DTWM.DAT file:


Dtwm*Dtstyle*iconImage:      Fpstyle
Dtwm*Dthelpview*iconImage:   Fphelp
Dtwm*backdrop*image: SkyLight
Dtwm*ws0*backdrop*image: SkyLight
Dtwm*ws1*backdrop*image: WaterDrops
Dtwm*iconBoxGeometry:                         1x4+16+20
Dtwm*iconBoxSBDisplayPolicy:                  horizontal

Most of the resources defined in the DECwindows Window Manager resource file (DECW$MWM.DAT) can be used with the New Desktop's Window Manager by adding the applicable resources to DTWM.DAT and changing the application class name from Mwm to Dtwm. Note that customizations to the DECwindows Window Manager resource file (DECW$MWM.DAT) are not automatically carried forward to the New Desktop's Window Manager resource file (DTWM.DAT). The user or system manager must make the appropriate edits to the DTWM.DAT file.

As with all application resource files, user-specific customized versions of this file should be placed in the DECW$USER_DEFAULTS directory (which is typically the user's home directory). To put into effect any changes made to the Window Manager resource file, you must restart the Window Manager.

For more information about the Window Manager resources, refer to the Dtwm manpage.

3.4.8.2 Window Manager Resource Configuration File (SYS.DTWMRC)

The Window Manager resource configuration file for the New Desktop, SYS.DTWMRC, is available in CDE$SYSTEM_DEFAULTS:[CONFIG.C]. It is a supplementary resource file that is used with the Window Manager resource file (DTWM.DAT) to control much of the behavior of the New Desktop Window Manager.

In the DECwindows desktop, supplemental window manager configurations are made via the DECW$MWM_RC.DAT file. Information stored in this resource file affects the Window Manager Root Window Menu, customized key binding descriptions, mouse button binding descriptions, and other attributes. Customizations made to DECW$MWM_RC.DAT are not automatically carried forward to the New Desktop. You can update the New Desktop's SYS.DTWMRC file with previous customizations made to DECW$MWM_RC.DAT by doing the following:

  1. Copy CDE$SYSTEM_DEFAULTS:[CONFIG.C]SYS.DTWMRC to disk$:[user.DT]DTWMRC.DAT.
  2. Make any edits that you would like to the file. You can incorporate changes previously made to DECW$MWM_RC.DAT and make other edits.
  3. Restart the Window Manager to put these changes into effect.

Functional enhancements are available for DTWMRC.DAT, such as a series of new Workspace Manager functions (for example, f.create_workspace) to support the multiple-workspace environment. For more information about this new functionality, as well as more information about customizing DTWMRC.DAT, refer to the DTWMRC manpage.

3.4.9 Automatic Application Startup

The DECwindows desktop provides the Automatic Startup... option from Session Manager for specifying which applications should be started when you log in to a session. You can put additional customizations in the SYS$LOGIN:DECW$LOGIN.COM file.

The New Desktop provides a different technique for starting applications when you log in to a session. There are two options, both based on starting a default set of applications you want and then saving the state of your session: Resume Current Session or Return to Home Session.

Style Manager's Startup menu provides these options, as described in Section 2.1.11.

Applications are responsible for informing the New Desktop how to restart them. The CDE applications of the New Desktop give detailed information, including which windows are displayed, where they are positioned, and current values. The DECwindows applications, in general, provide only enough information for them to be restarted; no state information is preserved.

Optional DECwindows applications, such as DECwindows Notes, may not provide any information and therefore are not restarted. For such cases, there is a command procedure called disk$:[user.DT]SESSIONETC.COM, that you can use to start any applications that cannot be restarted automatically. This procedure is analogous to the DECW$LOGIN.COM procedure in the traditional DECwindows environment.

3.5 Using the New Desktop Error Logs

The New Desktop provides two log files by default---one for session startup and one for the session itself---and a third log file for the login process, if you define the symbol for it. These log files are described in the following list:

  • Login log file
    To create a log file for the login process, define the DECW$LOGINLOG symbol in your SYS$MANAGER:DECW$PRIVATE_APPS_SETUP.COM file as the name of the log file you want to create. (This is the same way you create a log file for the login process for the traditional DECwindows desktop.) For example, the following definition will write login log file messages to the file SYS$MANAGER:LOGIN.LOG:


    $ DECW$LOGINLOG == "SYS$MANAGER:LOGIN.LOG"
    
  • Session startup log file
    After login but before Session Manager takes control, the log file SYS$LOGIN:DECW$SM.LOG is used to display information about session startup. Additional information pertaining to exiting your session is added to the file. This file is analogous to the file of the same name in the traditional DECwindows environment.
    If you do not want this log file, you can define the symbol DECW$SESSIONLOG to be "FALSE" in your SYS$MANAGER:DECW$PRIVATE_APPS_SETUP.COM file, as shown in the following example:


    $ DECW$SESSIONLOG == "FALSE"
    
  • Error log file for the session
    Once Session Manager takes control, all errors are written to the session error log file disk$:[user.DT]ERRORLOG. All New Desktop applications running in the current session write their status and error information to this file with a timestamp on each entry. In addition, application output (data sent to SYS$OUTPUT) is captured in the error log file, except in the following cases:
    • If the application is run with its own DECterm for displaying output.
    • If the output is explicitly sent somewhere other than SYS$OUTPUT.
    • If the account of the user running the application differs from the account of the user who is logged in to the New Desktop.
    • If the application is runing on a system other than the one on which the New Desktop Session Manager is running.

    A new ERRORLOG. file is created each time you log in. The previous version is renamed to ERRORLOG.OLD, and the version before that is renamed to ERRORLOG.OLDER. There is only one version of each of these files. Only the three latest error log files are saved; previous error logs are automatically deleted.
    The Watch Errors action, provided in the Desktop Tools application group, enables easy viewing of the ERRORLOG. file.

3.6 Using Colors in the New Desktop Environment

In the New Desktop, color allocation is centralized. A set of colormap entries is preallocated when a session starts. The default values for widget color resources are mapped to these colormap entries. All applications that do not explicitly set widget color resources will use the shared colormap entries. By using this approach you can dynamically change colors for all applications by changing the pixel values of the shared colormap entries.

In the New Desktop, the Session Manager acts as the color server for the desktop. It reserves and controls a portion of the X server's colormap, dividing it into a series of color sets. A color set consists of a color for each of the resources, as described in Table 3-5.

Table 3-5 Color Set Resources
Resource Description
Background An application's background color
Foreground An application's foreground color
topShadowColor The color for the top and left borders of application controls and the window frame
bottomShadowColor The color for the right and bottom borders of application controls and the window frame
selectColor The color used to highlight selected controls in the application

Style Manager combines up to eight color sets to create a color palette. The widgets to which these color sets apply are determined by color set ID resources. A color set can be applied to all widgets, only to popup dialog boxes, or only to text widgets based on these resources.

The colors in each color set are based on the background color choice. The background color for each color set is displayed in Style Manager's Color dialog as a colored button. Depending on the setting of the Number of Colors option, two to eight buttons will be displayed. The Number of Colors option appears on Style Manager's Color menu, shown in Figure 3-2.

Figure 3-2 Style Manager's Color Menu


You can set the Desktop's colors by choosing from the list of color palettes and modifying the color sets displayed in the buttons with the Modify... dialog.

When you select a color button and move the sliders in the Modify dialog, the application's colors displayed in that color will change if the application supports dynamic colors. If the color does not change when you move the sliders, you can assume that the application's colors are not under the control of the New Desktop but are under the control of the application. You can change an application's color resources to change its colors.

3.6.1 Changing the Number of Available Colors

It is possible that the colors needed by an application combined with the colors needed by the New Desktop could exceed the maximum number of colors available on the display (even if they are the same colors). If an application cannot set all the colors it needs, it can reveal the problem by:

  • Generating errors such as "Unable to allocate colormap entry...".
  • Not generating errors but displaying in different colors or changing the desktop's colors when they are started.

If an application exhibits any of these symptoms, use the Number of Colors... dialog, shown in Figure 3-3, to give as many colors as possible to the application. The number of color sets used by the desktop depends on the selection in the Number of Colors... dialog. The fewer color sets used for the desktop, the more colors available for an application. The Number of Colors options are described in Table 3-6.

Figure 3-3 Number of Colors Menu


Table 3-6 Number of Colors Options
Options Description
More Colors for Desktop Specifies a high color display. The color palettes use 8 color sets and have a maximum of 42 colors (including black and white).
More Colors for Applications Specifies a medium color display for the desktop. The color palettes use 4 color sets and have a maximum of 22 colors (including black and white).
Most Colors for Applications Specifies a low color display for the desktop. The color palettes use 2 color sets and have a maximum of 12 colors (including black and white).
Black and White Specifies a black-and-white display. The color palettes use only two colors. In this nondynamic color configuration, the available palettes are BlackWhite and WhiteBlack.
Default Allows the color server to select the color configuration based on the number of colors on the display. The default is usually More Colors for Applications.

Note

The Color Customizer example program uses a similar technique for providing a dynamic color environment. It allocates an additional set of colors for the color resources it manages, which further limits the number of colors available for applications. This can cause some undesired interactions with the dynamic color environment provided with the New Desktop.

For more information about how the New Desktop manages the colormap, use the Man Page Viewer to view the dtsession reference page.


Previous Next Contents Index