Skip to content

Commit a018711

Browse files
committed
Adding TText wrapper
1 parent e7be7fc commit a018711

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

Source/fmx/WrapFmxShapes.pas

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,15 @@ TPyDelphiPath = class(TPyDelphiCustomPath)
119119
property DelphiObject: TPath read GetDelphiObject write SetDelphiObject;
120120
end;
121121

122+
TPyDelphiText = class(TPyDelphiControl)
123+
function GetDelphiObject: TText;
124+
procedure SetDelphiObject(const Value: TText);
125+
public
126+
class function DelphiObjectClass : TClass; override;
127+
// Properties
128+
property DelphiObject: TText read GetDelphiObject write SetDelphiObject;
129+
end;
130+
122131
implementation
123132

124133
uses
@@ -161,6 +170,7 @@ procedure TShapesRegistration.RegisterWrappers(
161170
APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiArc);
162171
APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiCustomPath);
163172
APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiPath);
173+
APyDelphiWrapper.RegisterDelphiWrapper(TPyDelphiText);
164174
end;
165175

166176
{ TPyDelphiShape }
@@ -368,6 +378,23 @@ procedure TPyDelphiPath.SetDelphiObject(const Value: TPath);
368378
inherited DelphiObject := Value;
369379
end;
370380

381+
{ TPyDelphiText }
382+
383+
class function TPyDelphiText.DelphiObjectClass: TClass;
384+
begin
385+
Result := TText
386+
end;
387+
388+
function TPyDelphiText.GetDelphiObject: TText;
389+
begin
390+
Result := TText(inherited DelphiObject);
391+
end;
392+
393+
procedure TPyDelphiText.SetDelphiObject(const Value: TText);
394+
begin
395+
inherited DelphiObject := Value;
396+
end;
397+
371398
initialization
372399
RegisteredUnits.Add(TShapesRegistration.Create);
373400

0 commit comments

Comments
 (0)