With focus-follows-pointer (sys.resources: Dtwm*keyboardFocusPolicy: pointer)
a move from a terminal straight onto a desktop icon or onto dtbar kept the
terminal as the keyboard focus: the icon windows did not select EnterNotify,
and McdeDesktopEvent returns True for every event of an icon, so the
workspace's root/backdrop enter path (HandleWsEnterNotify -> Do_Focus_Key
(NULL)) never ran. The bar is a window of its own and dtwm does not focus
it, so hovering it changed nothing either.
- WmMcdeDesktop.c: the icon windows select EnterWindowMask, and their
EnterNotify calls Do_Focus_Key(NULL, time, ALWAYS_SET_FOCUS) -- the focus
goes to the pointer root and dtwm clears the active client.
- dtbar.c: the shell already had EnterWindowMask for the menu refresh; on a
normal enter it now sets the input focus to PointerRoot unless the root or
the bar already has it. A menu's grab (NotifyGrab) is left alone, so
keyboard menu handling is untouched.
Measured under Xvfb :89 (1024x768, pointer policy, Toronto backdrop, dtbar,
two xterms at +56+126 and +406+326):
- before: xterm A -> bar kept xterm A; xterm B -> Computer icon kept xterm B.
- after: A -> icon focus 1 (PointerRoot), B -> icon 1, A -> bar 1,
B -> backdrop 1; hovering A or B again focuses that xterm; the front panel
still takes the focus itself, and the client loses it (unchanged).
make mcde-linux MCDE_DIRS="install programs/dtwm programs/dtbar" exit=0;
"check programs/dtbar" 1 PASS, 0 FAIL; MCDE_DIRS=plist
"mcde-plist-check: ok".
AGENTS.md: the window/focus paragraph says what an icon or the bar now does.
Conditional Compilation
-----------------------
The following is a listing of the conditional compilation switches that
are "not obvious." Excluded are hardware or OS identifiers (e.g. __ultrix),
header file include flags, and macros (e.g. ABS).
DEBUG
Turns on code that prints out error messages (specifically
protocol errors).
DEBUGGER
Turns on code to help debugging Help-on-item.
DEBUG_ICON_BOX
Turns on code that alters iconbox spacing to help debug iconbox.
(?)
DEBUG_RESOURCE_DATABASE
Turns on code that dumps out dtwm's local resource database
to aid in debugging resource problems.
DEBUG_SESSION_HINTS
If defined, the session hints property is left on the root
window after being read. Normally, it is deleted.
ICCC_COMPLIANT
This enables stricter ICCCM compliance. Specifically, some
clients didn't get WM_PROTOCOLS quite right.
INTEGRATION_TESTING_
Swaps assignment of black and white on wait state cursor as
a quick indicator of which client is showing the wait state.
LARGECURSORS
Allows cursors larger than 16x16.
MESSAGE_CAT
Enables message catalog code for local language support.
MOTIF_DEFAULT_ICON
Enables the default window icon with four buttons.
OLD_CODE
Vestigal code.
R2_COMPAT
Enables support for old clients that still pass window geometry
hint information in WM_NORMAL_HINTS.
UNMAP_ON_RESTART
All windows are unmapped on restart.