Modifying an Existing Component - Overview

From RAD Studio
Jump to: navigation, search

Go Up to Modifying an existing component Index

The easiest way to create a component is to derive it from a component that does nearly everything you want, then make whatever changes you need. What follows is a simple example that modifies the standard memo component to create a memo that does not wrap words by default.

The value of the memo component's WordWrap property is initialized to True. If you frequently use non-wrapping memos, you can create a new memo component that does not wrap words by default.

Note: To modify published properties or save specific event handlers for an existing component, it is often easier to use a component template rather than create a new class.

Modifying an existing component takes only two steps: