Dodakaedr
читать дальше »
[Setup]
AppName=My Application
AppVersion=1.5
DefaultDirName={pf}\My Application
[Files]
DestName: "WizardForm.BitmapImage1.bmp"; Source: "E:\Картинки\mostkorol2_1024.bmp"; Flags: dontcopy solidbreak
[code]
var
Panel1: TPanel;
BitmapImage1: TBitmapImage;
Label1: TLabel;
Label2: TLabel;
procedure InitializeWizard();
begin
WizardForm.MainPanel.Hide;
{ Panel1 }
Panel1 := TPanel.Create(WizardForm);
with Panel1 do
begin
Parent := WizardForm.InnerPage;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(499);
Height := ScaleY(57);
BevelOuter := bvNone;
end;
{ BitmapImage1 }
BitmapImage1 := TBitmapImage.Create(WizardForm);
with BitmapImage1 do
begin
Parent := Panel1;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(497);
Height := ScaleY(57);
ExtractTemporaryFile('WizardForm.BitmapImage1.bmp');
Bitmap.LoadFromFile(ExpandConstant('{tmp}\WizardForm.BitmapImage1.bmp'));
end;
{ Label1 }
Label1 := TLabel.Create(WizardForm);
with Label1 do
begin
Parent := Panel1;
Caption := 'Выбор папки установки';
Font.Color := clWhite;
Font.Height := -12;
Font.Name := 'Tahoma';
Font.Style := [];
ParentFont := False;
Left := ScaleX(16);
Top := ScaleY(8);
Width := ScaleX(134);
Height := ScaleY(14);
end;
{ Label2 }
Label2 := TLabel.Create(WizardForm);
with Label2 do
begin
Parent := Panel1;
Caption := 'В какую папку вы хотите установить {#SetupSetting("AppName")}?';
Font.Color := clWhite;
Font.Height := -12;
Font.Name := 'Tahoma';
Font.Style := [];
ParentFont := False;
Left := ScaleX(24);
Top := ScaleY(24);
Width := ScaleX(385);
Height := ScaleY(14);
end;
end;
Вот обновленый пример
читать дальше »
[Setup]
AppName=My Application
AppVersion=1.5
DefaultDirName={pf}\My Application
[Files]
DestName: "WizardForm.BitmapImage1.bmp"; Source: "E:\Картинки\mostkorol2_1024.bmp"; Flags: dontcopy solidbreak
[code]
var
PageNameLabel, PageDescriptionLabel: TLabel;
MainPanel: TPanel;
BitmapImage: TBitmapImage;
procedure InitializeWizard();
begin
WizardForm.MainPanel.Hide;
MainPanel := TPanel.Create(WizardForm);
with MainPanel do
begin
Parent := WizardForm.InnerPage;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(499);
Height := ScaleY(57);
BevelOuter := bvNone;
end;
BitmapImage := TBitmapImage.Create(WizardForm);
with BitmapImage do
begin
Parent := MainPanel;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(497);
Height := ScaleY(57);
ExtractTemporaryFile('WizardForm.BitmapImage1.bmp');
Bitmap.LoadFromFile(ExpandConstant('{tmp}\WizardForm.BitmapImage1.bmp'));
end;
PageNameLabel:=TLabel.Create(WizardForm);
with PageNameLabel do begin
AutoSize:=False;
SetBounds(ScaleX(24), ScaleY(10), ScaleX(400), ScaleY(30));
Transparent:=True;
Font.Name:= 'Georgia';
Font.Size:= 8;
Font.Color:=clWhite;;
Parent:=MainPanel;
end;
PageDescriptionLabel:=TLabel.Create(WizardForm);
with PageDescriptionLabel do begin
AutoSize:=False;
SetBounds(ScaleX(40), ScaleY(26), ScaleX(389), ScaleY(50));
Wordwrap:= True;
Transparent:=True;
Font.Name:= 'Georgia';
Font.Size:= 8;
Font.Color:=clWhite;;
Parent:=MainPanel;
end;
end;
procedure CurPageChanged(CurPageID: Integer);
begin
PageNameLabel.Caption:=WizardForm.PageNameLabel.Caption
PageDescriptionLabel.Caption:=WizardForm.PageDescriptionLabel.Caption
end;
а можно чтобы только текст менялся без картинки
читать дальше »
[Setup]
AppName=My Application
AppVersion=1.5
DefaultDirName={pf}\My Application
[code]
var
PageNameLabel, PageDescriptionLabel: TLabel;
MainPanel: TPanel;
BitmapImage: TBitmapImage;
procedure InitializeWizard();
begin
WizardForm.MainPanel.Hide;
MainPanel := TPanel.Create(WizardForm);
with MainPanel do
begin
Parent := WizardForm.InnerPage;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(499);
Height := ScaleY(57);
BevelOuter := bvNone;
end;
PageNameLabel:=TLabel.Create(WizardForm);
with PageNameLabel do begin
AutoSize:=False;
SetBounds(ScaleX(24), ScaleY(10), ScaleX(400), ScaleY(30));
Transparent:=True;
Font.Name:= 'Georgia';
Font.Size:= 8;
Font.Color:=$000000;
Parent:=MainPanel;
end;
PageDescriptionLabel:=TLabel.Create(WizardForm);
with PageDescriptionLabel do begin
AutoSize:=False;
SetBounds(ScaleX(40), ScaleY(26), ScaleX(389), ScaleY(50));
Wordwrap:= True;
Transparent:=True;
Font.Name:= 'Georgia';
Font.Size:= 8;
Font.Color:=$000000;
Parent:=MainPanel;
end;
end;
procedure CurPageChanged(CurPageID: Integer);
begin
PageNameLabel.Caption:=WizardForm.PageNameLabel.Caption
PageDescriptionLabel.Caption:=WizardForm.PageDescriptionLabel.Caption
end;