5 Commits
Author SHA1 Message Date
lotherk e3d8227249 MCDE: a backdrop per workspace (t0290)
dtsystemsettings has a Workspace menu on the Desktop page: This
Workspace (the active one) or one of the named workspaces, read from
DtWsmGetWorkspaceList.  A chosen backdrop goes to that workspace: dtwm
learned f.change_backdrop_ws INDEX PATH PIXMAP STYLE (the same parse as
f.change_backdrop, with the workspace index first) and
McdeBackdropFromFile on pSD->pWS[INDEX]; SetNewBackdrop keeps the choice
with SaveWorkspaceResources, so dtsession carries it to the next login
and ChangeToWorkspace shows it.  Measured under Xvfb: the menu lists
This Workspace, One, Two, Three, Four; Two + Ankh.bm printed
'dtwm: backdrop ws=1 .../backdrops/Ankh.bm style=0'.  WmMain.c now
includes WmFunction.h (the MCDE prototypes were implicit).
2026-11-16 10:05:40 +00:00
lotherk ec322652d3 MCDE dtmail: the settings window, General and Viewing (t0138)
dtmail opens the shared settings window (lib/DtWidget/McdePrefs.c) with
`dtmail -prefs`: a row of icon tabs, the page under them, no OK or Cancel.
The argument is taken out of argv before Xt sees it, and RoamApp::initialize
returns after building the window -- no mailbox and no ToolTalk are needed
for it.

  General  Default email reader (dtmail, Thunderbird, Evolution, mutt,
           xdg-email), Check for new mail (Manually, 1, 5, 15, 30, 60
           minutes), New mail sound (the events of the session's theme, a
           click plays it), Play sounds for other mail actions, Show the
           unread count in the front panel, Downloads folder, Remove
           unedited downloads, and what a search includes (Trash, Junk).
  Viewing  Show message headers (All/Brief/Full), the order of the list,
           the preview pane.

Values are kept as English KEY=VALUE in ~/.dt/dtmail.conf (McdePrefsConf),
the labels themselves (mailreader=Thunderbird), so the file stays readable.
dtmail's CDE Options dialog stays for the retrieval details; these keys are
the one pattern every MCDE program has, and wiring each into dtmail's own
option system is a follow-up.

McdePrefs grew what dtmail needed and the measurements found:

  * the page is a vertical XmPACK_COLUMN row column of rows; a row is a form
    of its own, made by McdePrefsRowBegin()/McdePrefsRowEnd() -- a widget
    cannot be reparented, so a row cannot take one made elsewhere (the old
    chained-form rows overlapped with many rows);
  * the window takes the size of the chosen page (its children are measured
    after the page is managed) and the title is the page's name;
  * a tab click finds its window by walking up the widget chain to a shell
    whose XmNuserData is a Prefs -- XtParent(XtParent(w)) alone found
    nothing, so no tab did anything before (measured).

dtpad's settings use the same two calls now; its window still writes
~/.dt/dtpad.conf.

Measured under Xvfb with xdotool:

  - dtmail -prefs: the General page -- docs/screenshots/leopard/
    Mail-Preferences-mcde.png -- and after a click on the Viewing tab the
    title is "Viewing" and the window 356x275 instead of 430x634
    (docs/screenshots/leopard/Mail-Preferences-Viewing-mcde.png);
  - Default email reader -> Thunderbird: ~/.dt/dtmail.conf has
    "mailreader=Thunderbird";
  - the Downloads field typed to /tmp/Downloads and Return:
    "downloads=/tmp/Downloads";
  - "Play sounds for other mail actions" off and on again: "othersounds=0"
    then "othersounds=1";
  - dtpad's Wrap to fit: "wrap=1" in ~/.dt/dtpad.conf;
  - make check lib/DtWidget: test_prefs PASS; make lib/DtWidget, dtpad,
    dtmail exit=0.

Open (follow-up): the reference's other pages (Accounts, Signatures, Rules),
wiring the keys into dtmail's own options, and ~/.dt/defaults with a
mailto: action -- choosing Thunderbird here stores the choice, but the
mailto: link still goes to dtmail's own action.
2026-11-14 13:03:41 +00:00
lotherk 63acc18853 MCDE: one settings window for every program, dtpad first (t0164)
lib/DtWidget/McdePrefs.c and include/Dt/McdePrefs.h: the reference's
preferences window -- a row of icon tabs from appconfig/icons/C (the active
one pressed), the tab's form under it, no OK or Cancel.  A tab's form is
built the first time it is shown; Escape closes, the close box only hides
it.  McdePrefsRow() puts a right-aligned label left of a widget and stacks
the rows; McdePrefsSeparator() draws the group lines.

Values are kept in ~/.dt/<prog>.conf as KEY=VALUE (English, the tab shown
last as lasttab=) -- McdePrefsConf.c does that without X, so test_prefs
tests it without a display: get/set, keep the other keys, replace instead of
doubling, no comment pile-up.

dtpad is the first user: Options > Preferences... opens two tabs, "Editing"
(Wrap to fit, Overstrike) and "Window" (Status line).  A change goes to the
Dt Editor at once, the Options menu's toggle follows, and the value is
written.  At start dtpad overlays ~/.dt/dtpad.conf over its X resources, so
the next start has it.

Measured under Xvfb with xdotool:

  - Options > Preferences... shows the icon tabs and the rows
    (docs/screenshots/leopard/dtpad-preferences-mcde.png);
  - switching "Wrap to fit" on writes "wrap=1" into ~/.dt/dtpad.conf (cat;
    the header is written once, lasttab=Editing is kept);
  - starting dtpad with "wrap=1" and "status=1" in that file shows the
    status line (Line: 1  Total: 1) without any menu being touched -- the
    change survives a restart;
  - Escape closes the window;
  - make check in lib/DtWidget: test_prefs PASS.

Open: dtfile's Prefs.c and dtcalendar (t0149, not built yet) are not moved
to it -- dtpad proves the building block; Command+, still finds a program's
menu entry through the old name heuristic instead of an explicit
registration.  Both are follow-up tasks.
2026-11-14 11:52:34 +00:00
lotherkandClaude Opus 5.5 70c9cd27cb mcde: rename to MCDE 0.1.0, conflict with cde, Makronix logo in dtlogin, the C99/POSIX system layer as contract
- pkgsrc recipe: DISTNAME mcde-0.1.0 (archive from tools/mcde-dist.sh),
  CONFLICTS+= cde-[0-9]*, DESCR.
- configure.ac: AC_INIT name and version 0.1.0; MCDE_VERSION; the
  tarname and the CDE_VERSION_* API level stay (share/cde, DtVERSION).
- Dt.h: DtVERSION_STRING "MCDE 0.1.0 (CDE 2.5.3)".
- programs/icons/MakronixDtlogo.pm from docs/logo/camouflage, installed,
  in PLIST, the default Dtlogin*logo*bitmapFile.
- include/Mcde/McdeSys.h: users, network/Wi-Fi, host name, time zone;
  checked with gcc -std=c99 -D_POSIX_C_SOURCE=200809L -pedantic.
- ext/src/mcde/AGENTS.md: the philosophy (CDE/Motif/Xlib only, C99/POSIX,
  everything OS-specific behind lib/McdeSys, conflicts with CDE).

Not built yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-09 19:40:06 +00:00
lotherkandClaude Opus 5.5 3b2a54c64b ext/src/mcde: import CDE 2.5.3 and pkgsrc wm/cde unchanged (the base of the MCDE fork)
cde-2.5.3.tar.gz, SHA512 a01b413b... as in pkgsrc distinfo; recipe from
pkgsrc 3c1118e94432.  Added with -f: CDE's .gitignore hides 612 files of
the archive.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-09 19:36:46 +00:00