blogs.conchango.com

welcome to the conchango blogging site
Welcome to blogs.conchango.com Sign in | Join | Help
in Search

Stuart Preston's Blog

Mostly about Visual Studio Team System, Team Foundation Server, Engineering Practices and Application Lifecycle Management.

WiX Tips and Tricks: Part 4 - "Squished" bitmap sizing and WiX v2.0.3309

If you followed my custom WiX UI walkthrough yesterday and used "dark" to create a baseline UI you may notice that you get "squished banner graphics" on your dialogs.  The reason for this appears to be that the "Width" and "Height" attributes on the dialog bitmap are larger than the dialog.  Note the units are not pixels, they are "Installer Units" (see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/installer_units.asp if you are interested in the explanation!).

Example - BrowseDlg:

<Dialog Id="BrowseDlg" Width="370" Height="270" Title="[ProductName]">
   <!-- the Width attribute on the following element will cause resizing of the resource -->
   <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="374" Height="44" TabSkip="no" Text="WixUI_Bmp_Banner" />
   <!-- lots more controls in here too -->
</Dialog>

Simply change the width attribute to "370" and that will ensure that the resource won't be resized.  For reference, my own installers typically have a BannerBitmap that is 494 x 59 pixels and the large dialog bitmap size (for the Welcome dialogs) of 494 x 313 pixels.
Published 16 December 2005 12:10 by Stuart.Preston

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

No Comments

Leave a Comment

(required) 
(optional)
(required) 
Submit
Powered by Community Server (Personal Edition), by Telligent Systems