这是代码:
[Code]procedure InitializeWizard;var Bitmapfilename: string; BitmAPImage: TBitmAPImage; WelcomePage: TWizardPage;begin WelcomePage := CreateCustomPage(wpWelcome,'',''); Bitmapfilename := ExpandConstant('{tmp}\Datanova_logo.bmp'); ExtractTemporaryfile(Extractfilename(Bitmapfilename)); BitmAPImage := TBitmAPImage.Create(WelcomePage); BitmAPImage.autoSize := True; BitmAPImage.Bitmap.LoadFromfile(Bitmapfilename); BitmAPImage.Cursor := crHand; BitmAPImage.left := 10; BitmAPImage.top := 10; BitmAPImage.Parent := WelcomePage.Surface;end;
如何在隐藏主面板的情况下在整个页面上显示图像?
解决方法 切换到欢迎页面时需要隐藏Bevel1,MainPanel和InnerNotebook组件,并在离开时再次显示它们.相反,只有当您显示欢迎页面时才需要显示图像,因为它覆盖整个页面区域.所以下面的代码将起到作用:[Code]var WelcomePageID: Integer; BitmAPImage: TBitmAPImage;procedure InitializeWizard;var WelcomePage: TWizardPage; begin WelcomePage := CreateCustomPage(wpWelcome,''); WelcomePageID := WelcomePage.ID; BitmAPImage := TBitmAPImage.Create(WizardForm); BitmAPImage.Bitmap.LoadFromfile('C:\Image.bmp'); BitmAPImage.top := 0; BitmAPImage.left := 0; BitmAPImage.autoSize := True; BitmAPImage.Cursor := crHand; BitmAPImage.Visible := False; BitmAPImage.Parent := WizardForm.InnerPage;end;procedure CurPageChanged(CurPageID: Integer);begin BitmAPImage.Visible := CurPageID = WelcomePageID; WizardForm.Bevel1.Visible := CurPageID <> WelcomePageID; WizardForm.MainPanel.Visible := CurPageID <> WelcomePageID; WizardForm.InnerNotebook.Visible := CurPageID <> WelcomePageID;end;总结
以上是内存溢出为你收集整理的inno-setup – 如何隐藏主面板并在整个页面上显示图像?全部内容,希望文章能够帮你解决inno-setup – 如何隐藏主面板并在整个页面上显示图像?所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)