home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 September / Chip_2001-09_cd1.bin / zkuste / delphi / kolekce / d123456 / DFS.ZIP / ExtProgressBar.txt < prev    next >
Text File  |  2001-06-28  |  11KB  |  194 lines

  1. TdfsExtProgressBar v2.06
  2.  
  3. Description:
  4.   A progress bar control that enables access to the new style types and large
  5.   range values provided by the updated progress bar control.  The updated
  6.   progress bar is provided in the COMCTL32.DLL file that comes with Microsoft's
  7.   new internet software.
  8.  
  9.  
  10. Installation:
  11.   Delphi 1:
  12.     * This component is not compatible with Delphi 1.
  13.  
  14.   Delphi 2, C++Builder 1:
  15.     * Select the 'Component | Install' menu item.
  16.     * In the Install Components dialog, click the Add button.
  17.     * In the Add Module dialog, enter the full path name of the component's
  18.       registration unit (the unit that ends with 'Reg.pas', i.e.
  19.       'BrowseDrReg.pas') and click OK.
  20.     * In the Add Module dialog, click OK.
  21.     * The component library will be rebuilt and a new tab named 'DFS' will be
  22.       available on the Component Palette.
  23.  
  24.   Delphi 3, 4, 5, C++Builder 3 & 4:
  25.     * Do one of the following:
  26.       + Create a new package by selecting File | New and choosing Package from
  27.         the New tab in the dialog.
  28.       + Open an existing package file.  I suggest you do this if you already 
  29.         have a package that you like to use for small, third party components.
  30.         I specifically have a package named "3rdParty.dpk" that I use for 
  31.         small components that come from other people.  Or, if you are using
  32.         several of my components, you might create a "DFS.dpk" package and 
  33.         use it for all of my DFS components.
  34.     * In the resulting package window, click the Add button.
  35.     * In the Add dialog, on the Add Unit tab, enter the full path name of the 
  36.       component's registration unit (the unit that ends with 'Reg.pas', i.e. 
  37.       'BrowseDrReg.pas') and click OK.
  38.     * You may want to add the other source files (*.pas) to the package as 
  39.       well in the same manner as you did the registration unit.  While this is
  40.       not required, not doing it will cause compiler warnings when the package
  41.       is compiled.  The component will function fine either way, but I 
  42.       personally find the warnings very irritating and am not happy until 
  43.       every compiler warning and hint is gone.
  44.     * If this package is new, or it has never been installed, click the 
  45.       Install button in the package window.  If this package is already 
  46.       installed in Delphi, click the Compile button.
  47.  
  48.   C++Builder 5 and up:
  49.     * Perform the "Delphi 3 and up, C++Builder 3 and up" steps above, except
  50.       for the last step (Compile or Install).
  51.     * Select the package the component has been added to, and choose 
  52.       Project | Edit Option Source to open the package options in the editor.
  53.     * In the entry for PFLAGS, add the "-LUvcl50" option.  For example:
  54.         <PFLAGS value="-$YD -$W -$O -v -JPHNE -M -LUvcl50"/>
  55.     * Perform the final step from above, Compile or Install.
  56.     * For Borland's official word on this situation, open the C++Builder help
  57.       file and search the index for "dsgnintf.dcu" and see the "Compiling
  58.       packages with DsgnIntf" section.
  59.  
  60.   Delphi 6 and up:
  61.     * Perform the "Delphi 3, 4, 5, C++Builder 3 & 4" steps above, except
  62.       for the last step (Compile or Install).
  63.     * Add the DesignIDE package to the Requires list of the package into which
  64.       the component is being installed.
  65.     * Perform the final step from above, Compile or Install.
  66.     * This is necessary because of changes to the design-time support units
  67.       introduced in Delphi 6.  For complete information, see the Del6New.hlp
  68.       file in your Delphi 6 Help directory.  In the index, search for
  69.       "upgrade issues" and in the resulting list of topics, select the
  70.       "DsgnIntf renamed and related changes" topic.
  71.  
  72.  
  73. Redistributing COMCTL32.DLL:
  74.   Microsoft used to have a really nasty redistribution policy about
  75.   COMCTL32.DLL:  To redistribute it, you have to distribute Internet Explorer
  76.   with your app.  Well, they've finally unpuckered a little bit (probably
  77.   because enough people griped long and loud enough (like Ron Burk in his
  78.   Windows Developer's Journal editorials and mail responses, THANKS RON!).
  79.   Anyhoo, here are links where you can find official redistribution information:
  80.  
  81.   http://www.microsoft.com/permission/copyrgt/cop-soft.htm#Freq
  82.     This page lists general Microsoft copyright info, and address the
  83.     COMCTL32.DLL issue in particular.  Of greatest note is item #3 which grants
  84.     permission to redistrubute a self-extracting archive provided by MS which
  85.     contains the DLL.
  86.  
  87.   http://www.microsoft.com/msdn/downloads/files/40Comupd.htm
  88.     This page includes a link to the most current version (v4.72 as of this
  89.     writing) of COMCTL32.DLL in a self-extracting archive, and it even gives
  90.     directions on how to call it from your setup program so that it is "quiet",
  91.     that is it doesn't pop up a dialog over your installl program if you don't
  92.     want it to.
  93.  
  94.   http://www.microsoft.com/msdn/downloads/files/40Comupd.exe
  95.     This is the link to the most current redistributable package.  About 500k,
  96.     sheesh, but at least it's better than 20 or 30 meg that was required before.
  97.  
  98.   Many thanks to Arentjan Banck <ajbanck@davilex.nl> for passing these links
  99.   along to me.
  100.  
  101.  
  102. Notes:
  103.   * For the full documentation on all the new progress bar stuff as implemented
  104.     in the latest COMCTL32.DLL, have a look at Microsoft's documentation at:
  105.     http://www.microsoft.com/msdn/sdk/inetsdk/help/itt/CommCtls/ProgBar/ProgBar.htm
  106.     Also, you can find information on all the updates to COMCTL32.DLL at:
  107.     http://www.microsoft.com/msdn/sdk/inetsdk/help/itt/CommCtls/CommCtls.htm#book_cc
  108.   * This component demonstrates two useful techniques of component writing: how to
  109.     completely override a property from the ancestor class and how to add new
  110.     window styles to an existing window component.
  111.   * The Min, Max, and Position properties have been completely replaced from the
  112.     ones provided in TProgressBar.  This is because the new version allows for
  113.     32-bit values to be used instead of 16-bit.  This only applies if you are
  114.     NOT using it with Delphi 4.  D4 has it right.
  115.   * The new progress bar provides two new properties not available in
  116.     TProgressBar:
  117.  
  118.       Color:          The background color of the progress bar.
  119.       SelectionColor: The color of the filled area of the progress bar.
  120.  
  121.     Additionally, if you are not using Delphi 4, there are two other properties
  122.     that are not normally available:
  123.  
  124.       Smooth:     Causes the filled area to to be completely solid instead of
  125.                   the normal, blocked style.
  126.      Orientation: Either pbHorizontal or pbVertical, it allows the bar to be
  127.                   oriented vertically or horizontally.
  128.  
  129.   * The component also demonstrates something not seen very often, a "real world"
  130.     use (i.e. not assembler) for the XOR boolean operator.  See the
  131.     SetExtendedStyles method.  :)
  132.  
  133.  
  134. Known Issues:
  135.   * The Width property is getting trashed on form load when Align is not alNone
  136.     and Orientation is pbVertical.  When Loaded gets called, Width is
  137.     equal to Height, even though the form file has a valid Width value.  I am
  138.     at a complete loss to explain this.  The best I can tell you to do is
  139.     manually reset the Width property in your form's OnShow event.
  140.   * The documentation for the new COMCTL32.DLL lists a PBM_SETBKCOLOR message
  141.     very similar to PBM_SETBARCOLOR.  But, unlike PBM_SETBARCOLOR, I can't get
  142.     PBM_SETBKCOLOR to work.  It's supposed to change the background (unused
  143.     portion) color of the progress bar.  I have instead implemented it via the
  144.     WM_ERASEBKCOLOR message.  The code for PBM_SETBKCOLOR is all in place for
  145.     the Color property, and I can't find anything wrong with it, so my only
  146.     guess is that it isn't working in COMCTL32.DLL or something in the VCL is
  147.     stomping on it.  If you want to have a try and see if works for you, enable
  148.     the DFS_TRY_BKCOLOR define that's near the top of ExtProgressBar.pas.  If
  149.     you have more luck than me, please let me know.
  150.  
  151.  
  152. Revision History:
  153.   2.06:   + Updated for Delphi 6 compatibility.  See updated install directions
  154.             above.
  155.   2.05:   + Updated for C++Builder 5 compatibility.
  156.   2.04:   + It's *really* D5 compatible now.  Small change between the D5 eval
  157.             version and the real, shipping D5 version broke it.
  158.   2.03:   + TExtProgressBar classname changed to TdfsExtProgressBar.
  159.           + Updated for Delphi 5 compatibility.
  160.   2.02:   + Updated for C++Builder 4 compatibility.
  161.   2.01:   + Added ExtProgressBarReg unit.  All IDE specific code (i.e.
  162.             registering the component, property editors, etc.) are contained in
  163.             this unit.  This was done for two primary reasons:  1) Using the
  164.             component in a Delphi or C++Builder expert would register the
  165.             component as well.  2) Reduce code size in some cases -- usually
  166.             the smart linker removes this sort of stuff since the app never
  167.             references it, but now it's for certain since it isn't even in the
  168.             unit.  This change means that you need to install the component
  169.             using the new "registration" unit instead of the unit containing
  170.             the component.
  171.   2.00:  + Rewrite for Delphi 4.  Delphi 4 provides the most important parts of
  172.            this component, namely 32-bit values for the ranges and the
  173.            horizontal and smooth styles.  However, it does not implement
  174.            everything, such as the ability to change the colors.  So, I have
  175.            rewritten it such that the properties match the ones in Delphi 4 so
  176.            that maintaining/migrating will be easier.  Notably, there is no
  177.            longer an ExtendedStyles property.  Instead, there are Orientation
  178.            and Smooth properties.
  179.   1.13:  + Added Version property.
  180.   1.12:  + Renamed Color property to SelectionColor.  Color is used throughout
  181.            the VCL to mean the background color, so I changed it for consitency.
  182.          + Added new Color property to control the background color.  I never
  183.            could get the COMCTL way of doing this (PBM_SETBKCOLOR message) to
  184.            work, so I've just implemented it the old way (WM_ERASEBKGND message).
  185.   1.11:  + Wouldn't compile under C++Builder 1.
  186.   1.10:  + Added new property: Color.  Sets the color of the bar.  This feature
  187.            was introduced in COMCTL32.DLL v4.71.
  188.          + Fixed problem with C++Builder 3 run-time packages.
  189.   1.02:  + Updated for new DFS.INC file, component tab name, history/comments
  190.            file.
  191.   1.01:  + Wouldn't compile under Delphi 3.
  192.   1.00:  + Initial release.
  193.  
  194.