RRUZ / vcl-styles-plugins

Skin plugins for third party installers and apps
https://theroadtodelphi.wordpress.com/
172 stars 46 forks source link

Graphic error #35

Open nizcoz opened 7 years ago

nizcoz commented 7 years ago

When i load any skin with inno setup i see this problem:

http://i65.tinypic.com/23iv045.png

I could not solve it by resizing the image

RRUZ commented 7 years ago

Try attaching a sample script to reproduce your issue.

nizcoz commented 7 years ago

define VCLStylesSkinPath "{localappdata}\VCLStylesSkin"

[Setup] AppName=MyApp AppVerName=MyApp DefaultDirname={pf}\MyApp WizardSmallImageFile=C:\Users\Nico\Documents\Inno\Script Inno\Image\small.bmp

[files]

Source: Styles\Skin.vsf; DestDir: {#VCLStylesSkinPath}; Flags: uninsneveruninstall Source: Styles\VclStyles.dll; DestDir: {#VCLStylesSkinPath}; Flags: uninsneveruninstall

[code] // Import the LoadVCLStyle function from VclStylesInno.DLL procedure LoadVCLStyle(VClStyleFile: String); external 'LoadVCLStyleW@files:VclStyles.dll stdcall setuponly'; procedure LoadVCLStyle_UnInstall(VClStyleFile: String); external 'LoadVCLStyleW@{#VCLStylesSkinPath}\VclStyles.dll stdcall uninstallonly'; // Import the UnLoadVCLStyles function from VclStylesInno.DLL procedure UnLoadVCLStyles; external 'UnLoadVCLStyles@files:VclStyles.dll stdcall setuponly'; procedure UnLoadVCLStyles_UnInstall; external 'UnLoadVCLStyles@{#VCLStylesSkinPath}\VclStyles.dll stdcall uninstallonly';

function InitializeSetup(): Boolean; begin ExtractTemporaryFile('skin.vsf'); LoadVCLStyle(ExpandConstant('{tmp}\skin.vsf')); Result := True;

end;

var PageNameLabel, PageDescriptionLabel: TLabel;

procedure InitializeWizard(); begin WizardForm.WizardSmallBitmapImage.SetBounds(ScaleX(0), ScaleY(0), WizardForm.MainPanel.Width, WizardForm.MainPanel.Height);

PageNameLabel:= TLabel.Create(WizardForm) with WizardForm.PageNameLabel do PageNameLabel.SetBounds(Left, Top, Width, Height); PageNameLabel.Transparent:= True; PageNameLabel.Font:= WizardForm.PageNameLabel.Font; PageNameLabel.Font.Color:= clWhite; //цвет надписи PageNameLabel.Parent:= WizardForm.MainPanel;

PageDescriptionLabel:= TLabel.Create(WizardForm) with WizardForm.PageDescriptionLabel do PageDescriptionLabel.SetBounds(Left, Top, Width, Height); PageDescriptionLabel.Transparent:= True; PageDescriptionLabel.Font:= WizardForm.PageDescriptionLabel.Font; PageDescriptionLabel.Font.Color:= clWhite; //цвет надписи PageDescriptionLabel.Parent:= WizardForm.MainPanel;

WizardForm.PageNameLabel.Hide; WizardForm.PageDescriptionLabel.Hide; end;

procedure CurPageChanged(CurPageID: Integer); begin PageNameLabel.Caption:= WizardForm.PageNameLabel.Caption; PageDescriptionLabel.Caption:= WizardForm.PageDescriptionLabel.Caption; end;

procedure DeinitializeSetup(); begin

UnLoadVCLStyles; end;