Declaration
property UserData: pointer;
Description
Contains a pointer to a user data buffer. This can be used for your own purposes to store information about the layer.
Note: If you set
UserDataLen, ImageEn will automatically save the data, and handle the freeing of memory.
| Demos\LayerEditing\UserDataInLayer\UserDataInLayer.dpr |
type
TMyRecord = record
SourceText: array[0..255] of AnsiChar;
SourceWidth: integer;
SourceHeight: integer;
end;
PMyRecord = ^TMyRecord;
var
rc: PMyRecord;
begin
New( rc )
With rc^ do
begin
Width := ...;
Height := ...;
Text := ...;
end;
ImageEnView1.CurrentLayer.UserData := rc;
ImageEnView1.CurrentLayer.UserDataLen := SizeOf( PMyRecord );
end;
See Also
◼UserDataLen