Chapter 2 erratap60-pdf Toward the end of Listing 2.1, the first of the following lines: GlobalUnlock(MemPtr); GlobalFree(MemHandle);Should be changed to: GlobalUnlock(MemHandle); GlobalFree(MemHandle);Additionally, the following file, which also contains this error, should be updated. \source\Chapter02\ORAboutBox\StdAboutBoxForm.cpp A correct complete set of files for the Chapter02 folder is provided in the file Chapter02.zip p76-pdf The second sentence of the Property Categories in the Object Inspector section should be changed to the following: In Chapter 1 we described how the IDE's Object Inspector can be used to display and edit component properties and event handler functions. C++Builder 5 introduces the idea of property categories. All properties (which includes events) can now be arranged by category, as well as the normal alphabetical listing. The purpose of property categories is to allow the logical grouping of related properties. A property may belong to more than one category, if appropriate. Additionally it is now possible to hide properties from the Object Inspector by hiding its category. This is referred to as filtering. p79-pdf The text should read as follows. Filenames are split, some sentences were swapped, and there are brackets and the the pointer symbol (*) missing as well as the word "property". Also the specific chapter reference is not made. Paragraph 1: By default the global variable FontNamePropertyDisplayFontNames ($(BCB)\Include\Vcl\dsgnintf.hpp) is set to false and font names are not shown in the Object Inspector using the actual font style of the font, rather the default MS Sans Serif font is used. This was done because the rendering of such images can be slow on low-end machines or those with many fonts installed. This time delay is only incurred the first time the property is displayed so on most machines it is acceptable. To enable the images this variable must be set to true. Setting FontNamePropertyDisplayFontNames to true is a non-trivial exercise requiring the use of the Open Tools API. An alternative solution is to install a property editor that overrides TFontNameProperty. This approach is shown in Chapter 10. Paragraph 3: The TComponentImageIndexPropertyEditor is for TImageIndex properties in components, (descendants of TComponent), with a parent component that has a TCustomImageList* property with the name Images. This property editor will be used for custom components that meet these criteria. If a different name is required for the TCustomImageList* property in the parent component a new property editor must be created that derives from this one. Two things make this impractical. First, it is not possible to include the header of the $(BCB)\Include\Vcl\stdreg.hpp file where these four TImageIndex property editors are declared. This is because of missing header files included in the unit. Second, the rendering code is not correct for large images and is incorrectly offset. A better approach is to override this property editor and this has been shown in the "A Generalized Solution for ImageIndex Properties" section in Chapter 10. Paragraph 5: The TPersistentImageIndexPropertyEditor is for TImageIndex properties in classes that descend from TPersistent (but not TComponent) with a parent component that has a TCustomImageList* property with the name Images. This property editor will be used for classes that meet these criteria. Again if a different name is required for the TCustomImageList* property in the parent component, a new property editor must be created that derives from this one. The best approach to this to override this property editor as is shown in the "A Generalized Solution for ImageIndex Properties" section in Chapter 10. |