PUMonitor enhancement project follow-up...
The original author provided a text RC file that defines all the resources the utility uses. No problem there, the Resource Compiler get that into a RES file, which is then ultimately attached to the EXE itself. My makefile handles that. Keep in mind that he developed this in Borland C++, so I am assuming he used the Borland Resource Workshop.
Alright...so now I need to change the Settings dialogs and as best as I know (which granted is very little on this topic
) I was expecting to use the Dialog Editor to actually visually modify/add the right layouts, etc. The Dialog Editor however (which is the Toolkit one) only wants to open a RES file, which while managable (b/c I have that as an output of the Resource Compiler run) will not afterwards reflect the changes in the source RC file. In other words: it looks like I can make changes to the RES itself, but once I do how do I get these into the underlying RC itself?
I understand why the ability to just change the RES is desirable: after all, if I want to adjust just a resource it is awfully nice to do so w/o having to recompile all the sources, etc.
OK, so back to my task, my thinking here is: if my makefile is looking to always compile the RC, clearly when I modify just the RES I will always overwrite those changes with the output of compiled RC, no?
Further on I understand that the Dialog Editor should allow me to create the DLG file, with the option to create the compiled version, that being the RES extension. OK, but trying to do this with my Dialog Editor only allows me to open a RES file, and attempting to save it simply points back to the same RES and optional H files.
Alright...so digging through my OS/2 DEV library I see the mention of Dialog Editor ONLY creating DLG text files when one starts with a NEW dialog...hmm??? So is the expectation really that all further changes are to be done by hand (if I want to reflect the actual changes in the underlying DLG source), or through a direct GUI manipulation of the previously generated RES file (using Dialog Editor)?
That just seems weird...I should be able to visually modify a dialog and upon saving it update the source definition file itself, be it RC or DLG (depending of course on what particular resource I am modifying).
So what am I missing here?
FYI - attempting to open the RC file itself in Borland Resource Workshop produces an error:
"Compiling MENU: ID_MENU"
Error
G:\code\source\os2\pumonitor\src\source\pumon2.rc 20:Expecting END
The Help feedback states:
Resource Workshop encountered an unexpected token when searching for the END keyword. This error is frequently caused by a typo in an identifier name.
Which I think is strange given that this RC file compiles successfully into RES, which itself is attached into the EXE and by all accounts that's working quite fine.
Here is the matching part of the RC itself:
...
MENU ID_MENU
{
MENUITEM "~About" , ID_MENU_ABOUT, MIS_TEXT
MENUITEM "~Settings" , ID_MENU_SET , MIS_TEXT | MIS_SUBMENU
{
MENUITEM "~General" , ID_MENU_SET_0, MIS_TEXT
MENUITEM "~CPU Meter" , ID_MENU_SET_1, MIS_TEXT
MENUITEM "~Memory Meter" , ID_MENU_SET_2, MIS_TEXT
MENUITEM "~TCP/IP Traffic", ID_MENU_SET_3, MIS_TEXT
MENUITEM "M~ail Checker 1", ID_MENU_SET_4, MIS_TEXT
MENUITEM "M~ail Checker 2", ID_MENU_SET_5, MIS_TEXT
MENUITEM "M~ail Checker 3", ID_MENU_SET_6, MIS_TEXT
MENUITEM "M~ail Checker 4", ID_MENU_SET_7, MIS_TEXT
MENUITEM "M~ail Checker 5", ID_MENU_SET_8, MIS_TEXT
MENUITEM "C~onnectivity" , ID_MENU_SET_9, MIS_TEXT
}
MENUITEM "" , -1, MIS_SEPARATOR
MENUITEM "Read ~Mail ", ID_MENU_MAIL , MIS_TEXT
MENUITEM "" , -1, MIS_SEPARATOR
MENUITEM "~Close" , ID_MENU_CLOSE, MIS_TEXT
}
...