OS/2 PM utility DLL that dynamically repositions pushbuttons evenly across the bottom of a dialog box.
BTNPLC.DLL exports a single function, PlaceDialogButtons, which is useful
when some dialog buttons are conditionally hidden or shown. After adjusting
button visibility in WM_INITDLG, call this function to spread the remaining
visible buttons evenly across the dialog's bottom edge.
Example usage:
PSHORT aidButtons;
aidButtons = malloc( 2 * sizeof( SHORT ) );
aidButtons[0] = DID_OK;
aidButtons[1] = DID_CANCEL;
PlaceDialogButtons( hab, hwndDlg, 2, aidButtons );
free( aidButtons );Function signature:
USHORT _System PlaceDialogButtons(
HAB hab, /* Anchor block handle */
HWND hwndDlg, /* Dialog window handle */
SHORT cButtons, /* Count of buttons */
PSHORT aidButtons /* Array of button IDs */
);src/
BTNPLC.C - PlaceDialogButtons implementation + GCC DLL entry point
btnplc-gcc.def - GCC module definition (LIBRARY, bldlevel, EXPORTS)
btnplc-ow.lnk - OpenWatcom wlink script
Install the following ArcaOS/OS/2 packages:
yum install git gcc make libc-devel binutils watcom-wrc watcom-wlink-hll
For OpenWatcom builds, install OpenWatcom 2.0 separately.
Run from the project root on the OS/2 system:
compile-gcc.cmd
The DLL is placed in bin-gcc\BTNPLC.DLL.
The build log is saved to compile-gcc.log.
To clean: compile-gcc.cmd clean
compile-ow.cmd
The DLL is placed in bin-ow\BTNPLC.DLL.
The build log is saved to compile-ow.log.
To clean: compile-ow.cmd clean
| Version | Date | Notes |
|---|---|---|
| 1.02 | 2026-07-28 | Moved sources to src/, added OW build, fixed _System on definition, guarded _DLL_InitTerm for OW, fixed STACKSIZE typo. |
| 1.01 | 2023-05-25 | Added GCC DLL entry point (_DLL_InitTerm), bldlevel description. |
| 1.00 | 1990-06-17 | Original version by David C. Briccetti. |
May be used for any purpose but not sold (per original author).
- Martin Iturbide (2023, 2026)
- David C. Briccetti (1990)