Delphi 6 New Characteristics - VCL Unit Changes and Characteristics (Chinese)

zhaozj2021-02-11  238

Delphi 6 new feature

Original: Borland Corporation

Translation: MusicWind®

Start Date: 2001-07-13

End Date: 2001-07-14 (Complete VCL Unit Changes and Characteristics)

statement:

The content of the following article takes the help document that comes with Delphi 6.

Copyright Borland Corporation.

Translation This draft has not been approved by Borland in advance, and Borland will forgive.

What is fresh?

Delphi 6 added some features and enhanced the original features, mainly with the following aspects:

IDE (integrated development environment)

Internet

XML (Extended Markup Language)

Compiler (compiler)

Com / Active X

Database Support

Corba

Actions

Custom Variants (can be defined)

VCL unit and characteristics

RTL unit and characteristics

Cross-Platform Development (cross-platform development)

Translation Tools (Translation Tool)

Deployment Changes (Publishing Mechanism)

Help System Extensibility (Extension Help System)

Note: Some features are not all Delphi versions.

VCL unit and characteristics

New VCL unit and new features (all versions)

New components:

TLABELEDEDIT

TLABELEDET is new in ExtCtrls.Pas unit, which demonstrates how to use sub-components. TLABELEDIT is an editing control with labels. Label is one of the properties of this control.

TValuelisteditor

Valuelisteditor is a custom raster component that uses the TSTRINGS save key / value pair. It works like an object viewer (Object Inspector).

Tcomboboxex

TCOMBOBOXEX is a new combo box control, which allows images to appear next to the list text.

TcolorBox

Tcolorbox is a new combo component that is used to select a variety of colors.

Improved features include:

Most window controls (WindowControl) have released the following bevel related properties:

Beveledges

Bevelinner

Bevelouter

Bevelkind

BevelWidth

Subcomponents

Now, components can have other components that create submas. For example, one component can have an attribute of a component reference, which can be internal (that is, a sub-component), or an external (ordinary component reference). If the internal components are referenced, the sub-component is not owned by the Form, but is owned by the components placed on the Form. This means that the assembly can be published in its internal subcomponents and can be properly fluidized. Also, the object viewer has been modified to support sub-component properties inside the component (such as a font property). To create a component with a sub-component, you need to call the Tcomponent.setSubComponent method.

The Publishable Interface Properties interface property (the type of the property is an interface) is now available, and when and only the class of this interface is a fluid component.

This means that now you can see the properties of the interface type in the Object Checkper, and a list of components that support this interface will appear for selection.

New unit and change

Checklst.pas

TcheckListbox adds a few new properties, including AutoComplete, HeaderColor, and HeaderBackgroundColor.

Classes.pas

TLIST has a new ASSIGN method, not only completes copy function, but also supports some simple collection operations.

Tcollection adds two protected methods to allow derived classes to further process for the operation of increasing and deleting entries. These two new methods are Added and Deleting, both without the default implementation. In order to maintain the streamline of Tcollection, there is no increasing onadded and an onDeleTing event. However, it is easy to implement in the derived class. In addition, TCOLLECTION adds an OWNER attribute to identify the owner.

TstringList Added attribute CaseSensitive (Semixer Sensitive), allowing you to control the operations of the substring list (sort, match) is sensitive.

TDATAMODULE moves from the Forms unit to the current unit (classes.pas), depends on the dependence of the visual control. This allows you to write a smaller service segment application without including the user interface.

Thread adds the Fatalexception property to identify any exceptions that cause normal running normal operation.

TSTREAM overloads the SEEK (search) function, allowing the value of the INT64 type to identify the location. The derived class can cover one of the overloads, but not override all.

TinterfaceDPersistent is a base class for a new persistent object, not a component, but an interface can be implemented.

Comctrls.pas

TtreeView's CreateTreenodes method is new.

The creation of a simple node has increased an event so that Tree's use does not have to re-create a derived class in order to overwrite the category of the node. And AddNode also made a modification, allowing you to pass the nodes you want to join to it.

Add an onaddition event that is triggered when the node is increased.

TreeView's Sort API has enhanced (function) and simplified (use). Now you can recat the sub-tree, and sort the top-level node. The TCUSTreEview and Ttreenode classes now provide an consistent definition for AlphaSort and Customsort, and these methods are added to TTreenodes. All changes are in the background, keeping compatible with the previous version.

Increase multiselect (multi-selection) related four attributes and eight methods.

TLISTVIEW has added a CreateListItems method that is similar to the CreateTreenodes of TtreeView.

TSTATUSBAR- Adjustable size clips can now be displayed, even if the father of the status bar is not directly form. As long as the lower right corner of the status strip is in the lower right corner position of the Form, the clip is displayed.

TDATETIMEPICKER adds the Format property to control the display mode of the date value.

THEADERCONTROL has added a number of new properties and events to support the drag and drop column. A new attribute Hotel is allowed to display highlight when the user's mouse is stopped on the top area.

Ttoolbar adds a MENU property that automatically adds many buttons corresponding to Menu menu items on the toolbar. When the user uses the custom dialog to customize the toolbar, there will be a series of events. Contnrs.PAS

Last and First (first) two functions (attributes) are added to TobjectList, Tcomponentlist, and TclassList. The return values ​​of these functions are different depending on the class.

TSTACK, TQUEUE (Queue), TOBJECTSTACK (Object Stack), and TOBJECTQUEUE (Object Queue) PUSH now change to a function, simple returns to be pushed into the stack (or queue) object. Just like push, then view. This is very useful when you want to push the object that is just created during the promotion (the translator's note: In fact, Borland should take into account!).

TBucketList and TobjectBucketList are a simple hash table.

Controls.pas

TCUSTOMLISTControl is a new public base class for expressing list controls for entries (such as combo boxs, list boxes, and list views, etc.). It introduces some new methods for manipulating a list of inheritance of the child.

TDRAGOBJECTEX, TDRAGCONTROLOBJECTEX, and TDRAGDOCKOBJECTEX are three new drag objects. After the drag operation is over, they can be released automatically. They correspond to TDRAGOBJECT, TDRAGCONTROLOBJECT and TDRAGDOCKOBJECT, which distinguishes that the old version cannot be automatically released when the drag and drop operation is complete.

Two methods added to TControl: ClientToparent and ParentToclient, used to convert coordinates between father and children. Working mode is similar to ClientToscreen and ScreenToClient.

TwinControl adds an overloaded method PaintTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT to Canvas instead of the HDC (Device Description Table Handle).

TMODALRESULT is moved to Forms.PAS. In addition, add the following support functions:

Function ispositiveResult (Const AmodalResult: TMODALRESULT): Boolean

Function isnegativeResult (Const AmodalResult: tmodalResult): boolean;

Function isabortresult (Const AmodalResult: TMODALRESULT): Boolean;

Function IsanallResult (Const AmodalResult: TMODALRESULT): Boolean;

Function StripallFromResult (Const AmodalResult: TMODALRESULT): TMODALRESULT

Dbctrls.pas

TDBlookUplistbox and TDBlookUpComboBox add NULLVALUEKEY properties to allow users to assign values ​​with null values.

TDBCOMBOBOX adds AutoComplete and AutodropDown properties.

TDBListbox also adds the AutoComplete property.

TopEndialog Add OptionSex Properties (Translator Note: This property is used to set the Win2000 unique positional toolbar), similarly, save the dialog added this property. Extctrls.pas

The TIMAGE-ProPortional property is increased to control the aspect ratio of the image without the size of the image control.

Forms.PAS

Tapplication (and TapplicationEvents) adds an ONSETTINGCHANGE event to inform the system settings.

TForm adds ALPHABLEND, AlphablendValue, TransparentColor, and TransparentColorValue to support layered Form.

Tscreen provides a range of properties (WorkareAreft, Workaretop, WorkaReft, WorkareaHeight, WorkAreawidth). In addition, there is a new series of new methods that allow you to position which monitor is more in touch, rectangles, or windows.

TMONITOR expands multi-monitor support, providing current domain, WorkareArect, and BoundSRect.

New autodragdocking support. This feature allows you to close the automatic docking function of the application. In addition, you allow you to modify such a flag in the Delphi Options Settings dialog.

The TMODALRESULT statement is moved to the Control.PAS unit.

Graphics.PAS

New TFONTRECALL, TPENRECALL, and TBRUSHRECALL three new classes allow you to quickly access font (font), Pen (brush) and brush (brush). They are derived from TRECALL (declared in the Classes unit), TRECALL needs to be used with TPERSIStent.

The system color is sorted to find it.

Add 4 on the basis of the original 16 colors:

ClmoneyGreen

CLSKYBLUE

CLCREAM

CLMedgray

Imglist.pas

Draw, Drawoverlay and Geticon methods are added to OverLoad tags for the property settings for you override the list of images.

InIfiles.Pas

The INI file began to support the use of streaming binary data.

TMEMINIFILE supports whether the control subster is sensitive.

ThaShedStringList is a new TStrings derived class that uses internal hash (mixed) tables to increase access speed.

Masks.pas

EditMask and text use custom types so their properties editor is more useful.

Menus.pas

TMENUITEM adds an AutoCheck attribute to indicate whether the user point and menu entry are automatically switched between the marked and unmatled.

Registry.pas

Tregistry begins to support the use of streaming binary data.

Stdctrls.pas

OnCloseup and an Onsect event are added to TCUSTomComboBox (TcomboBox is also the same). The onCloseup event is triggered when the drop-down list of the group is turned off (the time triggered with the onDropdown). Onsect is triggered when the list is selected (or when scrolling the optional value up and down) is changed). The combo box adds the AutoCompelete property, default to TRUE.

TListbox adds an attribute of two styles: LBVIRTUAL and LBVIRTUALOWNERDRAW. Two styles are used to support the virtual list box, that is, no entry is saved. You can specify the number of entries by setting the count property, and then provide an entry (and related objects) in ONDATA, OONDATAFIND, and ONDATAOBJECT events. Typinfo.Pas

The getPropInfo method that calls the object is safe. If the object does not have any RTTI information, simply return NIL.

Increase FreeAndnilproperties. It will release (free) and blank (NIL) support all object properties of the RTTI object. Note that it will perform this operation, including the referenced object, so it is best to release the referenced objects, blank.

转载请注明原文地址:https://www.9cbs.com/read-5333.html

New Post(0)