VMware Cloud Community
AnonymousDefaul
Enthusiast
Enthusiast

Retina images in Installbuilder for Qt

Hi-


I am trying to create a retina-compatible installer with InstallBuilder for Qt, using custom splash, logo, and left-column images. I've created pngs with 2x the intended size (ending with @2x in the name), and set <enableRetinaDisplayImages> to 1. However, the images just display at twice the desired size.


What is the correct approach for using custom retina images in InstallBuilder for Qt?


Thanks!

Labels (1)
Reply
0 Kudos
9 Replies
AnonymousDefaul
Enthusiast
Enthusiast

Hi Tom,

The images ending with the suffix  or ' @2x.png or '  need to be placed next to the regular size images when building the project. Also, the XML should reference the regular size image. Please find below an example:

Having a directory `test_project/images`, it should include the files:

  • leftImage.png
  • leftImage@2x.png

Then the project XML should use them like:

<project>    ...
   <enableRetinaDisplayImages>1</enableRetinaDisplayImages>    <leftImage>path/to/test_project/images/leftImage.png</leftImage>
   ...
</project>

Could you check if configuring the project this way works for you?

Looking forward to your feedback,

Alejandro

AnonymousDefaul
Enthusiast
Enthusiast

Hi Alejandro-

Thanks, that did the trick!

I have a second question:

The documentation suggests that the leftImage be sized 163x314. When I build using the regular InstallBuilder, the full image is displayed correctly, but in the Qt version the top and bottom of the image is cut off (the area is 163 x 296). Is there a way to force the Qt installer to display the full leftImage?

Thanks,

Tom

Reply
0 Kudos
AnonymousDefaul
Enthusiast
Enthusiast

Hi  Tom,

I'm glad you managed to solve the issue.

Regarding the different size of the left image in Qt installers, thanks for reporting the issue. I've been able to reproduce and opened a ticket in our bug-tracking system for checking it. As a workaround, I suggest resizing the installer window by setting the project property `<height>`. Would that work for you?

Regards,

Alejandro

Reply
0 Kudos
AnonymousDefaul
Enthusiast
Enthusiast

Hi Alejandro-

Yes, as I workaround I've already made the installer window slightly taller. The issue seems to be that Qt installers have a taller bottom navigation bar than the normal installers, but the overall size of the installer window is the same - so it covers the bottom of the image.

-Tom

Reply
0 Kudos
TobiasDngi
Contributor
Contributor

Hi,

I have the same issue regarding the cut off left image when building with the QT version of Installbuilder. Now four years have passed and the issue isn't fixed. Why is that? Is there any chance that it will be fixed in an upcoming version? If not the documentation should mention that there ist a different height needed for QT builds to prevent people from building wrong images. And higher installer windows aren't looking as pleasant as the slim ones.

Best regards,

Tobias

Reply
0 Kudos
michieldhont_
Hot Shot
Hot Shot

Hi @TobiasDngi ,

We will investigate it. Could you send a screenshot?

Regards,

Michiel

Reply
0 Kudos
TobiasDngi
Contributor
Contributor

Hi Michiel,

This one for you.

Best regards

Tobias

CutOff_LeftImage.png

Reply
0 Kudos
michieldhont_
Hot Shot
Hot Shot

Hi @TobiasDngi ,

Could you attach the image you are using, or a dummy image with the same size and DPI?

Regards,

Michiel

Reply
0 Kudos
TobiasDngi
Contributor
Contributor

Hi Michiel,

please see the attached image.

Best regards,

Tobias

 

Reply
0 Kudos