SelectDirBrowseLabel 中的新行被目录编辑框剪切

New lines in SelectDirBrowseLabel get cut by directory edit box

我的安装程序设置中有以下几行

procedure CurPageChanged(CurPageID: Integer);
begin
  if IsAdmin then
    WizardForm.SelectDirBrowseLabel.Caption := 'Installation directory:'
  else
    WizardForm.SelectDirBrowseLabel.Caption := 'Restart installer as Administrator to install {#AppName} system wide.' #13#10 + #13#10 + 'Installation directory:';
end;

问题是新行上的文本被目录条目框截断,因此它们不可见。

我会在编辑框下方添加信息标签:

procedure InitializeWizard();
var
  InfoLabel: TNewStaticText;
begin
  InfoLabel := TNewStaticText.Create(WizardForm);
  InfoLabel.Parent := WizardForm.SelectDirPage;
  InfoLabel.Left := WizardForm.SelectDirLabel.Left;
  InfoLabel.Top := WizardForm.DirEdit.Top + WizardForm.DirEdit.Height + ScaleY(16);
  InfoLabel.Caption :=
    'Restart installer as Administrator to install {#AppName} system wide'
end;


这是更好的解决方案吗?
Make Inno Setup installer request privileges elevation only when needed