1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
|
// An example of a resource file
//
#include "resource.h"
#include "windows.h"
/////////////////////////////////////////////////////////////////////////////
//
// RT_MANIFEST
//
1 24 DISCARDABLE "res/Win32++.manifest"
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
IDW_MAIN MENU
BEGIN
POPUP "&File"
BEGIN
MENUITEM "New &View", IDM_FILE_NEWVIEW
MENUITEM SEPARATOR
MENUITEM "Recent Files", IDW_FILE_MRU_FILE1, GRAYED
MENUITEM SEPARATOR
MENUITEM "E&xit", IDM_FILE_EXIT
END
POPUP "&Edit"
BEGIN
MENUITEM "Undo\tCtrl+Z", IDM_EDIT_UNDO
MENUITEM "Redo\tShift+Ctrl+Z", IDM_EDIT_REDO
MENUITEM SEPARATOR
MENUITEM "Cut\tCtrl+X", IDM_EDIT_CUT
MENUITEM "Copy\tCtrl+C", IDM_EDIT_COPY
MENUITEM "Paste\tCtrl+V", IDM_EDIT_PASTE
MENUITEM "Delete\tDel", IDM_EDIT_DELETE
END
POPUP "&View"
BEGIN
MENUITEM "&Tool Bar", IDW_VIEW_TOOLBAR, CHECKED
MENUITEM "&Status Bar", IDW_VIEW_STATUSBAR, CHECKED
END
POPUP "&Help"
BEGIN
MENUITEM "&About", IDM_HELP_ABOUT
END
END
MDIMENUVIEW MENU
BEGIN
POPUP "&File"
BEGIN
MENUITEM "New &View", IDM_FILE_NEWVIEW
MENUITEM "&Close", IDM_FILE_CLOSE
MENUITEM SEPARATOR
MENUITEM "E&xit", IDM_FILE_EXIT
END
POPUP "&Edit"
BEGIN
MENUITEM "Undo", IDM_EDIT_UNDO
MENUITEM "Redo", IDM_EDIT_REDO
MENUITEM SEPARATOR
MENUITEM "Cu&t", IDM_EDIT_CUT
MENUITEM "&Copy", IDM_EDIT_COPY
MENUITEM "&Paste", IDM_EDIT_PASTE
MENUITEM "De&lete", IDM_EDIT_DELETE
END
POPUP "&View"
BEGIN
MENUITEM "Tool Bar", IDW_VIEW_TOOLBAR, CHECKED
MENUITEM "Status Bar", IDW_VIEW_STATUSBAR, CHECKED
END
POPUP "&Color"
BEGIN
MENUITEM "&Black", IDM_COLOR_BLACK
MENUITEM "&Red", IDM_COLOR_RED
MENUITEM "&Green", IDM_COLOR_GREEN
MENUITEM "B&lue", IDM_COLOR_BLUE
MENUITEM "&White", IDM_COLOR_WHITE
END
POPUP "&Window"
BEGIN
MENUITEM "&Cascade\tShift+F5", IDW_WINDOW_CASCADE
MENUITEM "&Tile\tShift+F4", IDW_WINDOW_TILE
MENUITEM "Arrange &Icons", IDW_WINDOW_ARRANGE
MENUITEM "Close &All", IDW_WINDOW_CLOSEALL
END
POPUP "&Help"
BEGIN
MENUITEM "About", IDM_HELP_ABOUT
END
END
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDW_MAIN ICON "res/mdi.ico"
IDI_VIEW ICON "res/view.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Bitmap
//
IDW_MAIN BITMAP "res/toolbar.bmp"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDW_ABOUT DIALOGEX 0, 0, 186, 90
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION |
WS_SYSMENU
CAPTION "About"
FONT 8, "MS Shell Dlg", 400, 0
BEGIN
DEFPUSHBUTTON "OK",IDOK,68,49,50,14
CTEXT "MDI Frame",IDC_STATIC,60,22,64,11
ICON IDW_MAIN,0,4,4,20,20
END
/////////////////////////////////////////////////////////////////////////////
//
// Accelerator
//
IDW_MAIN ACCELERATORS
BEGIN
"N", IDM_FILE_NEW, VIRTKEY, CONTROL, NOINVERT
"O", IDM_FILE_OPEN, VIRTKEY, CONTROL, NOINVERT
"P", IDM_FILE_PRINT, VIRTKEY, CONTROL, NOINVERT
"S", IDM_FILE_SAVE, VIRTKEY, CONTROL, NOINVERT
"C", IDM_EDIT_COPY, VIRTKEY, CONTROL, NOINVERT
"X", IDM_EDIT_CUT, VIRTKEY, CONTROL, NOINVERT
"V", IDM_EDIT_PASTE, VIRTKEY, CONTROL, NOINVERT
"Z", IDM_EDIT_UNDO, VIRTKEY, CONTROL, NOINVERT
"Y", IDM_EDIT_REDO, VIRTKEY, SHIFT, CONTROL, NOINVERT
VK_DELETE, IDM_EDIT_DELETE, VIRTKEY, NOINVERT
END
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE
BEGIN
IDW_MAIN "MDI Frame"
END
STRINGTABLE
BEGIN
IDM_FILE_NEW "Create a New Document"
IDM_FILE_OPEN "Open Existing Document"
IDM_FILE_SAVE "Save the Document"
IDM_FILE_SAVEAS "Save the Document with a new name"
IDM_FILE_PRINT "Print the Document"
IDM_FILE_EXIT "End the Program"
END
STRINGTABLE
BEGIN
IDM_EDIT_UNDO "Undo the last action"
IDM_EDIT_REDO "Redo the previously undone action"
IDM_EDIT_CUT "Cut the Selected Contents to the Clipboard"
IDM_EDIT_COPY "Copy the Selected Contents to the Clipboard"
IDM_EDIT_PASTE "Paste the Clipboard Contents to the Document"
IDM_EDIT_DELETE "Erase the selected Contents"
IDW_VIEW_TOOLBAR "Show or hide the tool bar"
IDW_VIEW_STATUSBAR "Show or hide the status bar"
END
STRINGTABLE
BEGIN
IDM_HELP_ABOUT "Display Information about this program"
END
STRINGTABLE
BEGIN
IDW_FIRSTCHILD "Activate this window"
IDW_CHILD2 "Activate this window"
IDW_CHILD3 "Activate this window"
IDW_CHILD4 "Activate this window"
IDW_CHILD5 "Activate this window"
IDW_CHILD6 "Activate this window"
IDW_CHILD7 "Activate this window"
IDW_CHILD8 "Activate this window"
IDW_CHILD9 "Activate this window"
IDW_CHILD10 "Select a window"
END
STRINGTABLE
BEGIN
IDM_FILE_NEWVIEW "Create View MDI Child"
IDM_FILE_CLOSE "Close MDI Window"
IDM_COLOR_BLACK "Use Black Printing"
IDM_COLOR_RED "Use Red Printing"
IDM_COLOR_GREEN "Use Green Printing"
IDM_COLOR_BLUE "Use Blue Printing"
IDM_COLOR_WHITE "Use White Printing"
IDW_WINDOW_CASCADE "Cascade MDI Windows"
IDW_WINDOW_TILE "Tile MDI Windows"
IDW_WINDOW_ARRANGE "Arrange Icons"
IDW_WINDOW_CLOSEALL "Close All MDI Windows"
END
STRINGTABLE
BEGIN
SC_CLOSE "Close the Window"
SC_MAXIMIZE "Maximize the Window"
SC_MINIMIZE "Minimize the WIndow"
SC_MOVE "Move the Window"
SC_NEXTWINDOW "Select Next Window"
SC_PREVWINDOW "Select Previous Window"
SC_RESTORE "Restore the Window"
SC_SIZE "Resize the Window"
END
STRINGTABLE
BEGIN
IDW_FILE_MRU_FILE1 "Open this document"
IDW_FILE_MRU_FILE2 "Open this document"
IDW_FILE_MRU_FILE3 "Open this document"
IDW_FILE_MRU_FILE4 "Open this document"
IDW_FILE_MRU_FILE5 "Open this document"
IDW_FILE_MRU_FILE6 "Open this document"
IDW_FILE_MRU_FILE7 "Open this document"
IDW_FILE_MRU_FILE8 "Open this document"
IDW_FILE_MRU_FILE9 "Open this document"
IDW_FILE_MRU_FILE10 "Open this document"
IDW_FILE_MRU_FILE11 "Open this document"
IDW_FILE_MRU_FILE12 "Open this document"
IDW_FILE_MRU_FILE13 "Open this document"
IDW_FILE_MRU_FILE14 "Open this document"
IDW_FILE_MRU_FILE15 "Open this document"
IDW_FILE_MRU_FILE16 "Open this document"
END
|