TddgButtonEdit—Container Components
Occasionally you might like to create a component that is composed of one or more other components. Delphi's TDBNavigator is a good example of such a component because it consists of a TPanel and a number of TSpeedButton components. Specifically, this section illustrates this concept by creating a component that is a combination of a TEdit and a TSpeedButton component. We will call this component TddgButtonEdit.
Design Decisions
Considering that Object Pascal is based on a single-inheritance object model, TddgButtonEdit will need to be a component in its own right, which must contain both a TEditl and a TSpeedButton. Furthermore, because it's necessary that this component contain windowed controls, it will ...
Get Borland® Delphi™ 6 Developer's Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.