Search code examples
inno-setuppascalscriptvcl-stylesinno-download-plugininno-tools-downloader

VCL Styles for Inno Setup having problems skinning some downloader page elements


I used VCL Styles for Inno Setup in an attempt to try to skin my installer and ran into a small issue I hope someone might be able to help with.

I need to apologize in advance. I have been muddling through these for a while, taking clips of things here and there to get it to work in my installer the way I wanted, and am by no means a guru when it comes to programming. In fact, it gives me migraines, but I have to get it done somehow. In short, my coding isn't expert by any means, but I try to get things done.

I have been using an installer I made sometime in 2008. Just recently I wanted to add to it, make it do things more automatically, have less and more insightful prompts, and look better.

I added InnoTools Downloader by Sherlock Software when i first made it, and have used that ever since with really no problems.

I just added VCL Styles, and there is an element inside InnoTools Downloader that I have absolutely no idea how to skin along with the rest of the installer. Everything else is looking great, but the small box inside the download page was gray.

enter image description here

So, I tried Inno Download Plugin by Mitrich Software. Hey, the gray box was gone, but shucks.. The error window text is light gray on white background and unreadable.

enter image description here

I did more searching and found How to apply VCL styles to DLL-based forms. When I tried to load InnoTools Downloader by Sherlock Software using:

procedure DllLoadStyle(const StyleFilename: WideString);
  external 'DllLoadStyle@files:itdownload.dll stdcall';

I just got en error: Unknown Type 'WideString'

I am using the ANSI version of Inno Setup because when I originally tried the Unicode version years and years ago, it messed up the InnoTools downloader, and I have been using ANSI ever since.

I tried changing WideString to just String, to match the formatting VCL already was using:

procedure LoadVCLStyle(VClStyleFile: String);
  external 'LoadVCLStyleA@files:VclStylesInno.dll stdcall';

But, that unfortunately gave me an error when running the installer:

Runtime Error (at -1:0):
Cannot Import dll:C:\...\Temp\is-XXXXX.tmp\itdownloaded.dll

1) I'm wondering if I'm kind of out of luck with wanting this part skinned because of both downloaders using an external .dll? 2) Is there possibly a way to direct VCL to skin that element on the page? 3) Can either of the .dll files be loaded in similar fashion to the linked page (and original VCL .dll file)? 4) Would using the Unicode version of Inno Setup give me any additional means of resolving this (As long as I don't have to rewrite a whole bunch of code on my original installers)?

I am very sorry, I'm really not understanding anything to do with new pages very well at this time. Most of what I did with my installers use MsgBox to avoid having to deal with them in situations where there are new updates and other such notifications that might require user input.

I put together a sample code taken from one of my installers if it is helpful, and can post that if requested. It is probably a big mess for any real programmer to even look at and don't want to give everyone a headache (or whiplash shaking their head in disgust), but just let me know if it would be helpful or if what I already put here is sufficient to explain what I'm running into.

If I manage to get 10 reputation, I can also post example images as well if helpful.

I can always live with it, but would really like to get that fixed and I apologize in advance if anything is unclear, as this is my first question.

Thanks in advance for any help and insight.

VCL Styles for Inno Setup 1.2.2.1 / Inno Setup 5.5.5a installed from ispack-5.5.5.exe / InnoTools Downloader 0.3.5 / Inno Download Plugin 1.4.0.

Edit: Added images (thanks for the points to do so). Ignore the error about download failed, I did that so it would stop and popup a box to capture the skinning of the window and popup.


Solution

  • The VCL Styles for Inno setup plugin only can apply the style on these inno controls

    • TNewEdit

    • TEdit

    • TPasswordEdit

    • TNewMemo

    • TNewComboBox

    • TNewListBox

    • TListBox

    • TNewButton

    • TNewCheckBox

    • TNewRadioButton

    • TSelectFolderForm

    • TFolderTreeView

    • TStartMenuFolderTreeView

    • TRichEditViewer

    • TNewStaticText

    • TNewNotebook

    • TNewNotebookPage

    • TPanel

      so you cannot apply a skin to a third-party component like the used by the InnoTools Downloader plugin. Anyway you can request such feature in the issue page of the project.