Java Desktop System Release 3 User Guide

Chapter 4 Working With Windows

The information in this chapter describes how to use windows in the Java Desktop System. You can use Metacity window manager with the Java Desktop System.This chapter describes the functions that are associated with the Metacity window manager.

Windows and Workspaces

Windows are displayed in subdivisions of the Java Desktop System that are called workspaces. Every workspace contains the same desktop, the same panels, and the same menus. However, you can run different applications, and open different windows in each workspace. You can display only one workspace at a time, but you can have windows open in other workspaces.

The Workspace Switcher panel application displays a visual representation of your windows and workspaces, as shown in Figure 4–1.

Figure 4–1 Workspace Switcher Panel Application

Workspace Switcher panel application. The context describes the graphic.

You can add workspaces at any time. To add workspaces to the Java Desktop System, right-click on the Workspace Switcher panel application, then choose Preferences. The Workspace Switcher Preferences dialog is displayed. Use the Number of workspaces spin box to specify the number of workspaces you require.

Window Manager Behavior

A window manager controls how windows appear and behave. The window manager manages where your windows are located, and which window has focus. The window frame contains buttons that enable you to perform standard actions such as moving, closing, and resizing windows.

You can set some window manager preferences in the Window Behavior preference tool. This manual describes the functions that are associated with the default configuration of the Metacity window manager. The default configuration is specified in the Window Behavior preference tool.

Types of Window

The Java Desktop System features the following types of windows:

Window Frames

A window frame is a border around a window. The window frame contains a titlebar. The titlebar contains buttons that you can use to work with the window.

Themes

You can apply several themes to your window frames. The theme determines how the frame looks. To choose a theme for all your window frames, use the Theme preference tool.

Control Elements

You can use the window frame to perform various actions with the window. In particular, the titlebar contains various buttons. The following figure shows the titlebar of an application window:

Window titlebar. Callouts: Window Menu button, Titlebar, Minimize, Maximize, Close Window buttons.

Dialog windows also contain some of the window frame control elements. Table 4–1 describes the active control elements on window frames, from left to right.

Table 4–1 Window Frame Control Elements

Control Element 

Description  

Window Menu button

Click on the button to open the Window Menu.

Titlebar 

You can use the titlebar to perform the following actions:  

  • To give focus to the window click on the titlebar.

  • To move the window grab the titlebar and drag the window to the new location.

  • To shade the window, double-click on the titlebar. To unshade the window, double-click on the titlebar again.

Minimize button

Click on the Minimize button to minimize the window.

Maximize button

Click on the Maximize button to maximize the window.

Close Window button

Click on the Close Window button to close the window.

Border 

The border around the window. Use the border to perform the following actions:  

  • To resize the window grab the border and drag the border to the new size.

  • To open the Window Menu, right-click on the border.

Window contents 

The area inside the window frame. Use the window contents to perform the following actions: 

  • To move a window, press-and-hold Alt, click in the window contents, then drag the window to the new location.

  • To resize a window, press-and-hold Alt, then middle-click near the corner you want to resize. To resize the window, drag from the corner on which you middle-clicked.

  • To open the Window Menu, press-and-hold Alt, then right-click in the window contents.

Using Menus and Panel Applications With Windows and Workspaces

This section describes the menus and panel applications that you can use to work with windows and workspaces.

Window Menu

The Window Menu is a menu of commands that you can use to perform actions on your windows. To open the Window Menu perform one of the following actions:

Table 4–2 describes the commands and submenus in the Window Menu.

Table 4–2 Window Menu Commands and Submenus

Menu Item 

Function 

Minimize

Minimizes the window. 

Maximize or Unmaximize

Maximizes the window. If the window is already maximized, choose Unmaximize to restore the window to its previous size.

On Top

Places the window above any other open windows on the desktop background. 

Move

Enables you to use the arrow keys to move the window. 

Resize

Enables you to use the arrow keys to resize the window. 

Close

Closes the window. 

Put on All Workspaces or Only on This Workspace

Puts the window on all of your workspaces. If the window is already on all of your workspaces, choose Only on This Workspace to put the window on the current workspace only.

Move to Workspace Right or Move to Workspace Left

Move the window to the workspace to the right of the current workspace. If the window is already in the last workspace at the right of the Workspace Switcher, choose Move to Workspace Left to move the window to the workspace to the left of the current workspace.

Move to Another Workspace

Moves the window to another workspace. Select the workspace to which you want to move the window from the submenu. 

Window List

The Window List displays a button for each application window that is open. You can use the Window List to perform the following tasks:

When you open an application window, Window List displays a button that represents the window. The window list buttons show which application windows are open. You can view which windows are open even if some windows are minimized, or other windows overlap a window. Window List can display buttons for the windows in your current workspace, or in all workspaces. To select this option, you must change the preferences of Window List.

You can also right-click on a window list button to open the Window Menu for the window that the button represents. When you open the Window Menu from Window List, the Window Menu does not contain the workspace commands. For more information on the Window Menu commands, see Window Menu.

Figure 4–2 shows Window List when the following windows are open:

Figure 4–2 Window List Panel Application

Window List panel application. The context describes the graphic.

The buttons in the panel application show the status of your windows. Table 4–3 explains the information that the window list buttons provide about the window. The examples in Table 4–3 refer to Figure 4–2.

Table 4–3 Window Status Information on Window List Buttons

State 

Indicates 

Example 

Button is pressed in. 

The window has focus. 

gedit

Square brackets around window title. 

The window is minimized. 

[Dictionary]

Button is not pressed in, no square brackets around title. 

The window is displayed, and is not minimized. 

ghex

Numeral on button, in parentheses. 

The button represents a group of buttons.  

Gnome-terminal (3)

Grouping Buttons

Window List can group the buttons that represent windows in the same class under one window list button. The Gnome-terminal button in Figure 4–2 is an example of a button that represents a group of buttons. The following figure shows an example of Window List with a button group open:

Window List panel application with button group open.

To open a list of the windows in a group, click on the window list button that represents the group. You can click on the items in the list to give focus to windows, minimize windows, and restore windows.

To open the Window Menu for a window in a button group, right-click on the window list button that represents the group. A list of the windows in the group is displayed. To open the Window Menu for a window in the group, click on the item in the list. When you open the Window Menu from the Window List, the Window Menu does not contain the workspace commands. For more information on the Window Menu commands, see Window Menu.

Workspace Switcher

Workspace Switcher displays a visual representation of your workspaces, as shown in Figure 4–3. Figure 4–3 shows the Workspace Switcher when the Java Desktop System session contains four workspaces. Your workspaces appear as buttons on the panel application. The background of the button in the Workspace Switcher that represents the current workspace is highlighted. The current workspace in Figure 4–3 is the workspace at the left of the panel application. To switch to another workspace, click on the workspace in the panel application.

Figure 4–3 Workspace Switcher Panel Application

Workspace Switcher panel application. The context describes the graphic.

Workspace Switcher also displays the application windows and dialogs that are open in your workspaces.

The panel application displays the workspaces in order from left to right across the rows of the panel application. In Figure 4–3, the panel application is set up to display the workspaces in one row. You can specify the number of rows in which your workspaces are displayed in Workspace Switcher. You can also change the default behavior of the Workspace Switcher to display the names of your workspaces in the panel application.

Window Selector

You can view a list of all windows that are currently open. You can also choose a window to give focus to. To view the window list, click on the Window Selector panel application. The following figure shows an example of the Window Selector panel application:

Window selector panel application displayed from the bottom edge panel.

To give focus to a window, select the window from the Window Selector panel application.

The Window Selector lists the windows in all workspaces. The windows in all workspaces other than the current workspace, are listed under a separator line.

Manipulating Windows

This section describes how to manipulate windows.

To Give Focus to a Window

A window that has focus can receive input from the mouse and the keyboard. Only one window can have focus at a time. The window that has focus has a different appearance than other windows.

You can use the following elements to give focus to a window:

Element 

Action 

Mouse 

Click on the window, if the window is visible.  

Shortcut keys 

Use shortcut keys to switch between the windows that are open. To give focus to a window, release the keys. The default shortcut keys to switch between windows are Alt + Tab.

Window List

Click on the button that represents the window in Window List.

Workspace Switcher

Click on the window that you want to give focus to in the Workspace Switcher display. If you click on a window in another workspace, Workspace Switcher switches to the new workspace, and gives focus to the window.

To Minimize a Window

To minimize a window perform one of the following actions:

To Maximize a Window

When you maximize a window, the window expands as much as possible. To maximize a window perform one of the following actions:

To Restore a Window

To restore a maximized window perform one of the following actions:

To restore a minimized window, click on the button that represents the window in Window List.

To Place a Window on Top of Other Windows

To place a window on top of other windows, open the Window Menu, then choose On Top.

To Close a Window

To close a window perform one of the following actions:

If you have unsaved data in the window, you are prompted to save your data.

To Resize a Window

To resize a window perform one of the following actions:


Note –

You cannot resize some dialog windows. Also, some application windows have a minimum size below which you cannot reduce the window.


To Move a Window

To move a window perform one of the following actions:

To Roll Up a Window

You can roll up and roll down windows, as follows:

Roll up

Reduce the window so that only the titlebar is visible.

Roll down

Switch a window from a rolled-up state so that the full window is displayed.

To roll up a window perform one of the following actions:

To Put a Window on All Workspaces

To put a window in all workspaces, open the Window Menu. Choose Put on All Workspaces. To set the window to appear only in the current workspace, choose Only on This Workspace.

To Move a Window to Another Workspace

You can move a window to another workspace in either of the following ways:

To Resize Panes

Some windows contain more than one pane. A pane is a subdivision of a window. For example, the file manager window contains a side pane and a view pane. A window that contains panes has a resize handle on the edge between the panes. To resize the pane, grab the resize handle, then drag the edge to the size you require.

Using Tables

Some windows contain information that is organized in a table. This section describes how to work with tables in windows.

To change the width of a column, drag one of the vertical edges of the column.

In some tables, you can sort the information by a particular column. To sort information in a table, click on the heading on top of the column by which you want to sort the information. An up arrow is displayed in the column heading by which the table is sorted. The following figure shows the up arrow.

Up arrow in a column heading.

To reverse the sort order, click on the column heading again. The up arrow changes to a down arrow. The down arrow indicates that the information in the column is sorted in reverse order.

In some tables, you can select multiple items. The following table describes how to select items in tables.

Task 

Action 

Select an item 

Click on the item. 

Select a group of contiguous items 

Press-and-hold Shift. Click on the first item in the group, then click on the last item in the group.

Select multiple items 

Press-and-hold Ctrl. Click on the items that you want to select.

Manipulating Workspaces

This section describes how to manipulate workspaces.

To Switch Between Workspaces

You can switch between workspaces in any of the following ways:

To Add Workspaces

To add workspaces to the Java Desktop System, right-click on Workspace Switcher, then choose Preferences. The Workspace Switcher Preferences dialog is displayed. Use the Number of workspaces spin box to specify the number of workspaces you require. Workspace Switcher adds new workspaces at the end of the workspace list.

To Name Workspaces

The default names of your workspaces are Workspace 1, Workspace 2, Workspace 3, and so on. To assign names to your workspaces, right-click on Workspace Switcher, then choose Preferences. The Workspace Switcher Preferences dialog is displayed. Use the Workspaces names list box to specify the names of your workspaces. Select a workspace, then type the new name for the workspace.

To Delete Workspaces

When you delete a workspace the windows in the workspace are moved to another workspace, and the empty workspace is deleted.

To delete workspaces from the Java Desktop System, right-click on Workspace Switcher, then choose Preferences. The Workspace Switcher Preferences dialog is displayed. Use the Number of workspaces spin box to specify the number of workspaces you require. Workspace Switcher deletes workspaces from the end of the workspace list.