home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / hansn.zip / README.TXT < prev    next >
Text File  |  1994-01-26  |  862b  |  17 lines

  1. This example demonstrates how to use one function for any window in a C++ environment. 
  2. In this example a single, globally available, function is used to access the CrtParms 
  3. of the current window.  The trick is making the function available application-wide 
  4. but using local data (attached to the current window).
  5.  
  6. Within this function you must avoid using class members other than GPFWINDOW 
  7. class members (base class). 
  8. To make the base class members available to this function it must be declared as 
  9. a member function for some window class in current application (ClassMain in this example).
  10. A call from a Gpf UserFunctionObject to this function would look like:
  11.  
  12.     ( (ClassMain*)GetSafeParentWindow() ) -> UFWin2GetCrt();
  13.  
  14. You should not call the function normally:
  15.     Main->UFWin2GetCrt()
  16. as only the Main window data will be accessible.
  17.