home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / opendc12.zip / od124os2.exe / od12osp1.exe / src / dynamicp / ioddynam.txt < prev    next >
Text File  |  1997-04-02  |  3KB  |  83 lines

  1. Dynamic Part Demonstration:
  2.  
  3. This part handler is being provided by IBM for several purposes:
  4. 1) For use in demos of OpenDoc and its capabilities
  5. 2) As sample source code demonstrating various programming techniques involved
  6. in developing OpenDoc part handlers
  7. 3) As an example of the cross-platform programming capabilities of OpenDoc.
  8.  
  9. This part handler demonstrates various combinations of shear and rotation controlled by
  10. menu selections.  It may be used either as a stand-alone application (as
  11. its own root part), or as a component of a larger document (when embedded
  12. within another part handler).
  13.  
  14. How to Build:
  15.  
  16.     To build this part you will need the OpenDoc Release 1.1 toolkit.
  17.  
  18.     From the dynamicp source directory run
  19.  
  20.     nmake
  21.  
  22.     To register the part with OpenDoc, run
  23.  
  24.     nmake ForceRegistry
  25.  
  26. Prerequisites:
  27.  
  28.     1) SimplePart's runtime, iodsimpl.dll.
  29.     2) This code uses IBM OpenClass, and so must be compiled with
  30.        IBM's VisualAge C++ compiler.
  31.  
  32. Usage:
  33.  
  34.     To run the DynamicPart as a root part, issue the command:
  35.  
  36.     docshell -k DynamicPart
  37.  
  38.     Once the part is loaded, select the menu item
  39.     "Dynamic Part->Rotation->Start" to make the part turn within its frame.
  40.     Selecting the menu item "Dynamic Part->Rotation->Direction->Counter clockwise"
  41.     will make the part turn in the opposite direction.  You can similarly
  42.     affect "Horizontal Shear" and "Vertical Shear".  The menu item
  43.     "Dynamic Part->Reset" will return the part to its initial state and orientation.
  44.  
  45.     To change the text that is scrolled, copy the new text to the clipboard and
  46.     select Edit->Paste for the DynamicPart.
  47.  
  48.  
  49. Design Notes:
  50.  
  51.     This part subclasses from SimplePart.  On Windows, this part also uses a
  52.     modified version of the Focuslib utilities.  The modified source is
  53.     called "myfocus.cpp".
  54.  
  55.     From a programming standpoint, this part handler demonstrates the following
  56.     features:
  57.      - Platform independence using IBMs OpenClass libraries
  58.      - OpenDoc transformation matrices,
  59.      - Timers,
  60.      - Window Clipping,
  61.      - Frame Negotiation,
  62.      - Menus,
  63.      - Event Handling, and
  64.      - Persistence.
  65.  
  66. Known Restrictions:
  67.  
  68.     Some combinations of angles for Rotation, Horizontal shear and Vertical
  69.     Shear will raise an exception within the part handler.  On Windows, the
  70.     DOCSHELL will simply exit without saving changes.  OS/2 will first
  71.     display a message box with a warning message.  On Windows NT and 95,
  72.     the Horizontal Shear and Vertical Shear menus are not installed.  To
  73.     install them, remove the #ifdef _PLATFORM_OS2_ statements and the
  74.     corresponding #endifs from INSTLMNU.C and MADJMENU.C in DYNAMICP\BMENU,
  75.     and recompile the part.
  76.  
  77.     On Windows95 rotating and shearing are not supported.  Selecting the
  78.     rotation menu item will cause the contents to be scaled and translated
  79.     instead.
  80.  
  81.     The bitmap does not print on Windows NT and 95.
  82.  
  83.