[Previous] [Contents] [Index] [Next]


Start Photon Window Manager


pwm [-cDdfGHhKknPrSTtWw] [-a C|L|R] [-b color]
    [-g input_group] [-I image] [-R [b|c|f|m|r|t]...] 
    [-s server] [-Xcurs[,clr]]


-a C|L|R
Alignment. By default, title alignment is centered (C) in the title bar. This option lets you change the alignment to either left (L) or right (R) justification.
-b color
Background color (hex RGB value).
Cursor focus. By default, focus is given to a window when you click anywhere inside it. This option lets you change keyboard focus so that it follows the cursor. You can toggle this behavior within pwm using the Cursor Focus option.
Disable clock in Taskbar.
Full window dragging. Change the default dragging from outline to full window dragging. You can toggle this behavior within pwm using the Full Window Dragging option.
Click to front. By default, a window is brought to the front only if you click on the window title bar. This option lets you click anywhere in a window to bring it to the front. You can also set this behavior within pwm using the Click to Front option.
Enable multi-monitor placement policy.
-g input_group
Set the PWM input group (default 1).
Disable Taskbar Help button.
Auto hide Taskbar.
-I image
GIF image to use for the workspace menu button.
Disable keyboard.
Always process Ctrl -Alt keychords. This option allows Ctrl -Alt to always be recognized by PWM for keyboard navigation. By default, each window has its own Ctrl -Alt state.
Disable Cursor focus. If the cursor focus is set to the default mode in a mouse-less environment (or when the mouse doesn't start) a window can't be accessed. This option provides a override for a mouse-less environment. The ph -s command calls pwm with this option.
Disable Taskbar, console switch, Workspace menu, and keyboard. This option is an alternative to specifying -KTSW.
-R [b|c|f|m|r|t]
Run PWM on a remote computer (phditto/phindows).
Auto-raise window on steady cursor.
Disable console switching.
-s server
Photon server to attach to (default /dev/photon).
Disable Taskbar.
Keep the Taskbar in front on the workspace.
Disable PWM Workspace menu.
Disable PWM Workspace menu button image (use text instead).
Define default cursor type (E9xx code) and color (hex RGB value)


The Photon Window Manager (pwm) provides standard window management functions, including move, resize, minimize, maximize, raise, lower, and close. It provides common window frame borders that can be customized based on the requirements of the specific application. It also creates and manages the Taskbar.

PWM Options

Selecting the Options... item from the PWM Workspace Menu launches the pwmopts program, which allows configuration of the user workspace:

Full Window Dragging option
If enabled, windows are continuously redrawn as they are dragged/moved around the screen. If disabled, only an outline of the window frame is dragged and the window is redrawn at its final position. This is useful for slow video cards or when running over a slow phrelay link.
Cursor Focus option
If enabled, focus is given to the window under the cursor. If disabled, focus remains with the current focus window regardless of cursor location. The focus window is the one that receives all keystrokes.
Click To Front option
If enabled, a click in any part of the window will bring it to the front. If disabled, only clicking in the title bar will bring a window to the front.
Taskbar Front option
If enabled, the PWM Taskbar will always be in front of all other windows. If disabled, the Taskbar remains at the back and may be obscured.
Taskbar Hide option
If enabled, the Taskbar will "hide" when not in use. Moving the pointer to the bottom of the screen will cause the Taskbar to appear. When the pointer is moved off the Taskbar, the Taskbar disappears. If disabled, the Taskbar is always visible at the bottom of the screen.
Multi-Monitor Placement option
If enabled, this affects whether PWM considers the desktop to span only the first graphics region (monitor) or all graphics regions comprising the input group. This affects the placement of the PWM Taskbar and the PDM control panel, as well as the dimensions used when maximizing windows.
Left, Center, and Right buttons
Specifies the alignment of the window title within the window frame.
Window Active Frame, Window Inactive Frame, Window Title Color, and Background Color buttons
These buttons bring up a color selection dialog that lets you customize the window frame's active and inactive colors, title text color, and the background color (visible if PDM isn't displaying a background image). Each button is filled with the current color setting.

Within this color selection dialog, you can select a color either by picking an entry from the list of common colors along the bottom or by specifying individual RGB values using either the slider control or the text field to the right of the slider; enter a hex value in the field.

A sample of the selected color is displayed in the bottom left of the dialog. Clicking on this sample will query the graphics driver for the closest representation of this color with the current palette and will adjust the RGB components appropriately.

To accept the new color, click the Accept button.

Cancel button
Click the Cancel button to quit the options configuration program without saving any changes. You can also cancel by closing the window from the menu or pressing the Esc key.
Defaults button
To restore PWM options to their defaults, click this button. The default options are Full Window Dragging, Click To Front, and Center title alignment. The color defaults for the window are window green when active and medium grey when inactive.
Apply/Revert button
To apply changes and save them to the configuration file, click the Apply button; the text on the button changes to Revert. To apply changes without saving them to the configuration file, click the Revert button. PWM is notified of the new options and reconfigures itself. By clicking on the button again (without making any more changes), PWM will revert to the original settings. This is useful to test the behavior of a user interface against a variety of operating paradigms without the need for saving and relaunching the configuration window.
Apply & Save button
To save any modified options, click this button. This will write the options to the user configuration file ~/.photon/pwm/pwm.cfg as well as instruct PWM to reconfigure itself to the new options. The pwmopts program also terminates.

Configuring the PWM Workspace Menu

The PWM Workspace Menu is configurable on a per-user basis. The configuration file is in $HOME/.photon/pwm/pwm.menu.

Note: If you create a private menu, you won't see new menu items when they're added to the internal PWM.

Here's a sample personal PWM menu:

=Workspace Menu
Shell...        S  pterm
Desktop Manager D  pdm
Run...          R  phrun
QUICS           Q  pterm qtin
Mail            M  pterm elm
News            N  pterm trn
Workspace...    W  pwmopts
Graphics...     G  phgrafx
Fonts...        F  fontcfg
Printers...     P  prsetup

The format of the file is simple; each line describes a menu item. Menu items are defined in the form:


If the line starts with:

Environment variables can't be used because the command parsing is simple. However, you can write the command to a shell script and specify the script as the command to run.

The pdm command is treated differently; it's enabled or dimmed based on the registered existence of a PDM process.


Start the window manager with left-side title alignment, cursor focus, and click-to-front behavior:

pwm -cf -aL


Holds a user's PWM workspace configuration.
Holds a user's custom PWM Workspace menu.

Environment variables:

When set, disables the confirmation dialog when Photon exits. To disable this dialog, add the following lines before the ph command in the sysinit.node file:

# disable confirmation dialog when Photon exits
export PHWMEXIT=1
Specifies the options to be passed automatically to pwm.

See also:


[Previous] [Contents] [Index] [Next]