2025年3月25日 星期二 甲辰(龙)年 月廿四 设为首页 加入收藏
rss
您当前的位置:首页 > 计算机 > 软件应用 > 行业软件

如何为您的 Inno Setup 安装包左下角增加自定义文本及提示

时间:04-28来源:大眼仔作者:大眼仔~旭点击数:44

对于喜欢玩 DIY 的同学来说肯定都希望自己的安装包能个性化,而 Inno Setup 就可以充分满足您的需求,只是相对来说Inno Setup在简易的向导模式中并不能很好的实现完全个性化自定义。当然,这里给大家提供的也是小编网络上收集并整理后的代码,如果您觉得有用,可以拿来使用。

Inno Setup 左下角自定义文本及提示效果:

Inno Setup 安装包左下角增加自定义文本及提示
Inno Setup 安装包左下角增加自定义文本及提示

Inno Setup 左下角自定义文本及提示代码:

  • [Code]
  • function ShouldSkipPage(PageID: Integer): Boolean;
  • begin
  • if PageID=wpReady then
  • result := true;
  • end;
  • procedure AboutButtonOnClick(Sender: TObject);
  • begin
  • MsgBox('大眼仔~旭 分享(Anan)2020(www.dayanzai.me)', mbInformation, mb_Ok);
  • end;
  • procedure URLLabelOnClick(Sender: TObject);
  • var
  • ErrorCode: Integer;
  • begin
  • ShellExec('open', 'http://www.dayanzai.me', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
  • end;
  • procedure InitializeWizard();
  • var
  • AboutButton, CancelButton: TButton;
  • URLLabel: TNewStaticText;
  • begin
  • WizardForm.FilenameLabel.Visible:= false;
  • WizardForm.BorderIcons:= [biSystemMenu, biMinimize];
  • WizardForm.BorderIcons:= [biHelp, biSystemMenu, biMinimize];
  • WizardForm.LICENSEACCEPTEDRADIO.Checked:=true;
  • CancelButton := WizardForm.CancelButton;
  • AboutButton := TButton.Create(WizardForm);
  • AboutButton.Left := WizardForm.ClientWidth - CancelButton.Left - CancelButton.Width;
  • AboutButton.Top := CancelButton.Top;
  • AboutButton.Width := CancelButton.Width;
  • AboutButton.Height := CancelButton.Height;
  • AboutButton.Caption := '关于(&A)';
  • AboutButton.OnClick := @AboutButtonOnClick;
  • AboutButton.Parent := WizardForm;
  • URLLabel := TNewStaticText.Create(WizardForm);
  • URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
  • URLLabel.Left := AboutButton.Left + AboutButton.Width + ScaleX(20);
  • URLLabel.Caption := '大眼仔~旭';
  • URLLabel.OnClick := @URLLabelOnClick;
  • URLLabel.Parent := WizardForm;
  • URLLabel.Font.Style := URLLabel.Font.Style;
  • URLLabel.Cursor := crHand;
  • URLLabel.Font.Color := clBlue;
  • end;

Inno Setup 是一款开源且免费的实用安装包制作工具,除了通过向导模式制作简单的安装包,您如果有代码功底可以很好的使用Inno Setup制作非常个性化的安装包效果。

方便获取更多学习、工作、生活信息请关注本站微信公众号城东书院 微信服务号城东书院 微信订阅号
推荐内容
相关内容
栏目更新
栏目热门