TCustomIcon.Assign procedure
Copies values from the specified persistent object into the current class instance.
Declaration
procedure Assign(Source: TPersistent); overrideDescription
Assign is an overridden method used to copy values from the
persistent object in
Source into the current class instance.
Assign calls
BeginUpdate to increment the active update counter,
and calls
EndUpdate prior to exiting from the method.
Assign handles specific class types in Source, including:
- TRasterImage
- Calls Clear to remove existing image content, and calls Add to create and icon image with the attributes in the PixelFormat, Height, and Width properties in Source. Calls AssignImage to store the image content from Source in the icon image. If the shared image class in Source is different than the one for the current class instance, UnshareImage is called.
- TCustomIcon
- Sets the value in Current to the value found in Source.
When Source is derived from another class type, the inherited Assign method is called.
See also
An experiment, built from Lazarus main 2dfa93c66e of 10-22-2026. Not the official Lazarus documentation.
