Windows NT 4.0 source code leak
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

106 lines
11 KiB

{\rtf1\ansi \deff0\deflang1024{\fonttbl{\f0\froman Times New Roman;}{\f1\froman Symbol;}{\f2\fswiss Arial;}{\f3\fswiss Helvetica;}{\f4\fmodern Courier;}{\f5\fswiss Helv;}{\f6\froman Ariel;}{\f7\fmodern Courier New;}
{\f8\fswiss Univers (WN);}{\f9\froman CG Times (WN);}{\f10\fswiss MS Sans Serif;}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;
\red255\green255\blue255;\red0\green0\blue127;\red0\green127\blue127;\red0\green127\blue0;\red127\green0\blue127;\red127\green0\blue0;\red127\green127\blue0;\red127\green127\blue127;\red192\green192\blue192;}{\stylesheet{\s244\li120\sb80\sl-240
\f3\fs18\up6\lang1033 \sbasedon0\snext0 footnote reference;}{\s245\li120\sb80\sl-240 \f3\fs20\lang1033 \sbasedon0\snext0 footnote text;}{\s251\fi-245\li360\sb120\sa60\sl-240 \f10\fs20\lang1033 \sbasedon253\snext251 heading 4;}{
\s252\li120\sb120\sa60\sl-240 \f3\fs20\lang1033 \snext0 heading 3;}{\s253\li120\sb120\sa60\sl-240 \b\f3\fs20\lang1033 \snext0 heading 2;}{\s254\li120\sb280\sa120\sl-320 \b\f3\lang1033 \snext10 heading 1;}{\s255\li360\sb80\sl-240 \f3\fs20\lang1033
\snext0 Normal Indent;}{\li120\sb80\sl-240 \f3\fs20\lang1033 \snext0 Normal;}{\s2\fi-240\li600\sb60\sl-240 \f3\fs20\lang1033 \snext2 Jli;}{\s3\li120\sb60\sl-240\keep\tx520\tx920\tx1320\tx1720\tx2120 \f4\fs16\lang1033 \snext3 Ex;}{\s4\li120\sb160\sl-240
\f3\fs20\lang1033 \snext13 Sa1;}{\s5\fi-240\li360\sl-240\tx360 \f3\fs20\lang1033 \snext6 Lb1;}{\s6\fi-240\li360\sb60\sl-240\tx360 \f3\fs20\lang1033 \snext6 Lb2;}{\s7\li360\sb60\sl-240 \f3\fs20\lang1033 \snext6 Lp1;}{\s8\fi-1800\li1920\sb120\sa40\sl-240
\brdrb\brdrs\brdrw15\brsp20 \brdrbtw\brdrs\brdrw15\brsp20 \tx1920 \b\f3\fs20\lang1033 \snext9 Th;}{\s9\fi-1800\li1920\sb60\sl-240\tx1920 \f3\fs20\lang1033 \snext9 Tp;}{\s10\li120\sl-240 \f3\fs20\lang1033 \snext0 Normal 2;}{\s11\li120\sb120\sa120
\f3\fs20\lang1033 \snext0 bitmap;}{\s12\li120\sb120\sl-240 \f3\fs20\lang1033 \snext13 Sa2;}{\s13\fi-240\li360\sb60\sl-240 \f3\fs20\lang1033 \snext13 Jl;}{\s14\li120\sa60 \f8\fs20\lang1033 \snext14 *body;}{\s15\li120\sa60 \b\f8\fs20\lang1033
\snext15 *heading;}{\s16\li120\sa60\sl-240 \f8\fs20\lang1033 \sbasedon14\snext16 para;}{\s17\fi-280\li400\sa60 \f8\fs20\lang1033 \sbasedon14\snext17 jump;}{\s18\fi-280\li400\sa60\tx400 \f8\fs20\lang1033 \sbasedon14\snext18 list bullet;}{
\s19\fi-280\li600\sa60 \f8\fs20\lang1033 \sbasedon14\snext19 jump indent;}{\s20\li120\sa60\sl-40\brdrb\brdrs\brdrw15\brsp20 \brdrbtw\brdrs\brdrw15\brsp20 \f8\fs20\lang1033 \sbasedon14\snext20 table rule;}{\s21\fi-280\li400\sa60\tqr\tx280\tx400
\f8\fs20\lang1033 \sbasedon14\snext21 list number;}{\s22\li120\sb100\sa60 \b\f8\fs20\lang1033 \sbasedon15\snext17 see also;}{\s23\li400\sa60 \f8\fs20\lang1033 \sbasedon14\snext23 para indent;}{\s24\fi-1800\li1920\tx1920 \b\f8\fs20\lang1033
\sbasedon15\snext20 table head;}{\s25\fi-1800\li1920\sa60\tx1920 \f8\fs20\lang1033 \sbasedon14\snext25 table text;}{\s26\li120\sb120\sa60 \f8\fs20\lang1033 \sbasedon14\snext19 see also 2;}{\s27\li120\sa60\keep\tx520\tx920\tx1320\tx1720\tx2120
\f4\fs20\lang1033 \sbasedon14\snext27 code;}{\s28\sl-120 \f9\fs20\lang1033 \snext16 *spacing;}{\s29\sl-120 \f9\fs20\lang1033 \sbasedon28\snext29 s6;}{\s30\qj\li360 \lang1033 \sbasedon0\snext30 Help Text;}{\s31\li115\sb120\sa40\sl-240\brdrb
\brdrs\brdrw15\brsp20 \brdrbtw\brdrs\brdrw15\brsp20 \f10\fs20\lang1033 \sbasedon8\snext9 Th2;}{\s32\li115\sb120\sa40\sl-240\brdrb\brdrs\brdrw15\brsp20 \brdrbtw\brdrs\brdrw15\brsp20 \b\f10\fs16\lang1033 \sbasedon8\snext9 Th3;}{\s33\li115\sb200\sl-240
\f10\fs20\lang1033 \sbasedon0\snext0 Normal 3;}{\s34\fi-1800\li1915\sb120\sa40\sl-240\brdrb\brdrs\brdrw15\brsp20 \brdrbtw\brdrs\brdrw15\brsp20 \tx1915 \b\f10\fs20\lang1033 \sbasedon0\snext35 Thh;}{\s35\fi-1800\li1915\sb60\sl-240\tx1915 \f10\fs20\lang1033
\sbasedon0\snext35 Tph;}}{\info{\author TRIO}{\creatim\yr1992\mo6\dy24\hr16\min51}{\version1}{\edmins357}{\nofpages2}{\nofwords66236}{\nofchars69347}{\vern16504}}\paperw12240\paperh15840\margl1800\margr1800\margt1440\margb1440\gutter0 {\*\template
C:\\WINAPPS\\WINWORD\\WHAT31.DOT}\sectd \linex0 \pard\plain \keepn \f3\fs20\lang1033 {\fs16\up6 ${\footnote \pard\plain \s245\li120\sb80\sl-240 \f3\fs20\lang1033 {\fs16\up6 $} Contents}} {\fs16\up6 #{\footnote \pard\plain \s245\li120\sb80\sl-240
\f3\fs20\lang1033 {\fs16\up6 #} Contents}} {\fs16\up6 K{\footnote \pard\plain \s245\li120\sb80\sl-240 \f3\fs20\lang1033 {\fs16\up6 K} Contents}} \{bmc generic.bmp\} {\b\f2\fs32 GENERIC: Simple Example Application}{\b\f2\fs32
\par }\pard \li120 {\f2
\par }{\field{\*\fldinst {\f2 include GENERIC.DOC}}{\fldrslt {\f2 GENERIC is a sample application that illustrates what could be considered a 'mimimum' implementation of a Windows application.}{\f2
\par }{\f2
\par }{\f2 While it would be possible to write an application that was far more minimum then GENERIC, such an application would not implement some of the features of a Windows application that many users would consider 'standard'.}{\f2
\par }{\f2
\par }{\f2 The features that GENERIC implements:}{\f2
\par }{\f2
\par }\pard \li720 {\f2 Custom Icon}{\f2
\par }{\f2 Standard Menu Bar}{\f2
\par }\pard \fi-1320\li2040 {\f2 Standard Help Menu}{\f2
\par }{\f2 Full WinHelp Support}{\f2
\par }{\f2 Keyboard Accelerator Usage}{\f2
\par }{\f2 Version Control Information}{\f2
\par }{\f2 Full Win16, Win32s, Win32 Common Source Code}{\f2
\par }\pard \fi-1320\li1440 {\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Custom Icon}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab }{\f2 While this might appear to be a t}{\f2 rivial and obvious feature, it is suprising how many sample applicaitons fail to implement this.}{\f2
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\b\f2 GENERIC.ICO}{\f2 : This contains the bitmap representation of the icon. It was created with the icon editor application that comes with the SDK.}{\f2
\par }{\f2
\par }{\b\f2 GENERIC.RC}{\f2 : This file defines all of the resources used by the application, including the ICON resource type that will allow the custom icon to be loaded.}{\f2
\par }{\f2
\par }{\b\f2 GENERIC.C}{\f2 : Loads the ICON resource, and assigns it to the }{\i\f2 hIcon}{\f2 element of the }{\i\f2 WNDCLASS}{\f2 structure that is passed into the }{\i\f2 RegisterClass}{\f2 call.}{\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 An 'About...' Box With Custom Icon And Font Style}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab }{\f2
Many sample applications simply use a call to 'MessageBox' to put up their 'About' box (if they even bother to do so at all). This application goes a little further by not only creating an actual dialog box, but by also taking the few extra steps that mak
}{\f2 e the dialog look better, and contain useful information.}{\f2
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2 GENERI}{\f2 C.DLG}{\f2
\par }{\f2 GENERIC.RC}{\f2
\par }{\f2 GENERIC.RCV}{\f2
\par }{\f2 GENERIC.C}{\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Standard Menu Bar}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab }{\f2 The book "The Windows Interface: An Application Design Guide", presents a recommended standard menu bar configuration. As closely as appropriate, this application follows the presented layout.}{\f2
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2 GENERIC.RC}{\f2
\par }{\f2 GENERIC.C}{\f2
\par }{\f2
\par }\pard \fi-1320\li1440 {\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Standard Help Menu}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Full WinHelp Support}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Keyboard Accelerator Usage}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Version Control Information}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2
\par }\pard \fi-1320\li1440 {\f2
\par }{\b\f2 \page }{\b\f2 Feature:}{\f2 }{\f2 \tab }{\f2 Full Win16, Win32s, Win32 Common Source Code}{\f2
\par }{\b\f2 Description:}{\f2 }{\f2 \tab
\par }{\b\f2 Files used to implement Feature:}{\f2
\par }\pard \fi-720\li1440 {\f2
\par }{\f2
\par }\pard \fi-1320\li1440 }}\pard\plain \fi-1320\li1440 \f3\fs20\lang1033 {\f2
\par }\pard \li120 {\f2 \page }{\f2 This is a sample WinHelp source document. To easily modify this }{\f2 document to customize it for use in your application perform the following steps:}{\f2
\par }{\f2
\par }{\f2 (Assuming you are using Windows Word other document editors could be used, but you are on your own for doing the appropriate conversions)}{\f2
\par }{\f2
\par }\pard \fi-504\li624 {\f2 1.}{\f2 \tab }{\f2 Open up this document.}{\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 2.}{\f2 \tab }{\f2 Turn on the 'View | Field Codes' option from the menu bar.}{\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 3.}{\f2 \tab }{\f2 Either remove, or appropriately alter the "}{\f2 \{}{\f2 bmc generic.bmp}{\f2 \}}{\f2 " field on the first line. Do not make any modifications to the "$ # K" that preceeds it.}{\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 4.}{\f2 \tab }{\f2 Create a new document and enter into it all of the information you are wanting to have in the WinHelp file. Avoid 'hard' pagebreaks (<ctrl-enter>), and 'fancy' formatting.}{\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 5.}{\f2 \tab }{\f2 Change the "}{\f2 \{}{\f2 include GENERIC.DOC}{\f2 \}}{\f2 " field to point to your new document}{\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 6.}{\f2 \tab }{\f2
Hilite the entire 'include' field that you just altered, and hit F9 (this will grab the information out of your document). If you run into problems with this step, simply delete the entire 'include' field, and copy/paste in the document you had created.}{
\f2
\par }\pard \li120 {\f2
\par }\pard \fi-504\li624 {\f2 7.}{\f2 \tab }{\f2 Save this document out, but make sure that you save it out as an RTF file, and not a DOC file. The Help Compiler reads the RTF format for building WinHelp files.}{\f2
\par }\pard \fi-1320\li1440 {\f2 \page }{\f2
\par }}