mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-03 23:00:27 +02:00
cocoa: setting the default system font to a text edit on allocation
git-svn-id: trunk@62252 -
This commit is contained in:
parent
968577d0f0
commit
45b2dae59f
@ -409,6 +409,7 @@ begin
|
||||
Result := TCocoaTextField.alloc.lclInitWithCreateParams(AParams);
|
||||
if Assigned(Result) then
|
||||
begin
|
||||
Result.setFont(NSFont.systemFontOfSize(NSFont.systemFontSize));
|
||||
Result.callback := TLCLCommonCallback.Create(Result, ATarget);
|
||||
SetNSControlValue(Result, AParams.Caption);
|
||||
end;
|
||||
@ -419,6 +420,7 @@ begin
|
||||
Result := TCocoaSecureTextField.alloc.lclInitWithCreateParams(AParams);
|
||||
if Assigned(Result) then
|
||||
begin
|
||||
Result.setFont(NSFont.systemFontOfSize(NSFont.systemFontSize));
|
||||
TCocoaSecureTextField(Result).callback := TLCLCommonCallback.Create(Result, ATarget);
|
||||
SetNSText(Result.currentEditor, AParams.Caption);
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user