{"id":9,"date":"2007-09-28T10:01:04","date_gmt":"2007-09-28T18:01:04","guid":{"rendered":"http:\/\/www.installaware.com\/blog\/?p=9"},"modified":"2008-01-04T07:50:10","modified_gmt":"2008-01-04T15:50:10","slug":"installaware-goes-aero-with-vista-glass-component","status":"publish","type":"post","link":"https:\/\/www.installaware.com\/blog\/?p=9","title":{"rendered":"InstallAware goes Aero with Vista Glass component"},"content":{"rendered":"<p>Hello again. I&#8217;d promised myself to make <strong>at least one post per week<\/strong> here, but the <strong>last two weeks<\/strong>, boy, have been a <strong>hell of a time<\/strong> for me &#8211; <strong>I almost broke my leg<\/strong> and then got a real bad cold that&#8217;s still bothering me. Now I know how Walt Disney&#8217;s <strong>Donald Duck<\/strong> feels about his <strong>bad luck<\/strong>. Anyway, my leg is better, it doesn&#8217;t hurt so much anymore and I&#8217;ve decided that its <strong>time to get back on this blog and post some new stuff<\/strong>. Some cool stuff, like the <strong>Vista Glass component<\/strong> on InstallAware&#8217;s <strong>forms designer<\/strong>.<\/p>\n<p>The <strong>Vista Glass component<\/strong> gives the <strong>glass feeling (Aero)<\/strong> to your setup UI, <strong>making window regions appear &#8220;glassy&#8221;<\/strong> like Windows Media Player on Windows Vista. Although still in beta, it works like a charm. In this post, <strong>you&#8217;ll find info<\/strong> about <strong>how to use it<\/strong>, <strong>what it does<\/strong>, <strong>what the drawbacks are<\/strong>, <strong>how to overcome them<\/strong> and you&#8217;ll get a push on creating your very first InstallAware Theme with Vista Glass support. <strong>Amazing<\/strong>, isn&#8217;t it? And <strong>it gets better<\/strong>.<\/p>\n<p><strong>Getting Started<\/strong><\/p>\n<p>In order to <strong>start exploiting<\/strong> InstallAware&#8217;s Vista Glass features, you&#8217;ll want to<strong> create a new project<\/strong> (you could also use an existing project, but this is just experimentation so I suggest creating a new one). Then, in the visual designers, go to the <strong>&#8220;User Interface&#8221;<\/strong> section and click on the <strong>&#8220;Dialogs&#8221;<\/strong> option.<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/www.hostme.gr\/files\/yztzdzyyiolzahmnttyw.jpg\" \/><\/p>\n<p>You get a <strong>list of the dialogs<\/strong> in your project sorted by the order they appear during install procedure. <strong>Highlight the &#8220;Welcome&#8221; dialog<\/strong> and get a preview of it, before beginning to apply Vista Glass effects.<\/p>\n<p><a href=\"http:\/\/www.hostme.gr\/files\/dmm3mji03ydzizowygu5.jpg\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" height=\"401\" src=\"http:\/\/www.hostme.gr\/files\/dmm3mji03ydzizowygu5.jpg\" width=\"620\" \/><\/a>\u00c2\u00a0<\/p>\n<p>When you <strong>double click a dialog<\/strong>, the form designer pops up, allowing you to <strong>change anything you want<\/strong> on your form, from simply <strong>re-arranging elements<\/strong> (textboxes etc.), to <strong>creating scripted events <\/strong>and <strong>reading\/writing variables<\/strong> to interact with MSICode.<\/p>\n<p><strong>Let&#8217;s Go Glass!<\/strong><\/p>\n<p><strong>Finding<\/strong> the <strong>Vista Glass<\/strong> component is really <strong>easy<\/strong>. <strong>Click<\/strong> the <strong>&#8220;Win32&#8221;<\/strong> <strong>tab<\/strong> and the <strong>right-most control<\/strong> on the palette is <strong>&#8220;VistaGlass&#8221;<\/strong>, the one we&#8217;re looking for.<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/www.hostme.gr\/files\/tj2zkiymltzz2tgdzoim.jpg\" \/><\/p>\n<p><strong>Click the component icon<\/strong> and then click anywhere on the <strong>dialog form<\/strong>. The <strong>VistaGlass component icon appears on your dialog<\/strong>. Click it to <strong>edit <\/strong>it&#8217;s <strong>properties<\/strong>: change the <strong>&#8220;GlassEnabled&#8221; and &#8220;SheetOfGlass&#8221; properties to &#8220;True&#8221;<\/strong>. Just by doing this, you get a VistaGlass (Aero) dialog!<\/p>\n<p>\u00c2\u00a0<img decoding=\"async\" src=\"http:\/\/www.hostme.gr\/files\/ighgtoizuobw1lrlzydg.jpg\" \/><\/p>\n<p>To <strong>preview<\/strong> your achievement, click on the <strong>Test Dialog toolbar button<\/strong> (the one with the <strong>thunderbolt icon<\/strong>).<\/p>\n<p><strong>Next Steps<\/strong><\/p>\n<p>You might be wondering if <strong>it&#8217;s really that simple<\/strong>. Basically, yes! You now have full <strong>Vista Aero Glass effects on your dialog<\/strong>. Due to the beta nature of the component however, some controls <strong>render awkward<\/strong>. We can <strong>make it all look better<\/strong> with some tricks. Instead of glassing the entire dialog, lets focus on glassing a targeted region first. We need to <strong>change two properties<\/strong> for this one. The <strong>first <\/strong>is called <strong>&#8220;SheetOfGlass&#8221; &#8211; change it from &#8220;True&#8221; to &#8220;False&#8221;<\/strong>. The <strong>second<\/strong> is <strong>&#8220;GlassBottom&#8221;<\/strong>, which <strong>sets<\/strong> the <strong>pixels<\/strong> occupied by <strong>the glass effect, counting up from the bottom of the dialog. <\/strong>With the <strong>&#8220;Official Theme&#8221;<\/strong>, try setting<strong>&#8220;GlassBottom&#8221;<\/strong> to <strong>&#8220;301&#8221;<\/strong>. Now our UI looks much better!<\/p>\n<p><strong>Pro&#8217;s and Con&#8217;s<\/strong><\/p>\n<p>It&#8217;s obvious that by <strong>using VistaGlass<\/strong> on your setup UI, you&#8217;re giving your users <strong>a richer setup experience<\/strong>. They <strong>get the &#8220;wow&#8221;<\/strong> before even having used your product for the first time, giving you a <strong>clear advantage<\/strong> over your <strong>competition<\/strong> just by using the right setup tool. Also, <strong>don&#8217;t<\/strong> <strong>worry<\/strong> if your setup needs to run on <strong>versions of Windows earlier than Vista.<\/strong> The <strong>VistaGlass<\/strong> component <strong>auto-detects<\/strong> the end-user&#8217;s Windows version, and <strong>disables the glass effect<\/strong> on legacy operating systems automatically, without any error messages or other undesirable UI artifacts.<\/p>\n<p>The <strong>only issue<\/strong> is that <strong>some controls don&#8217;t render correctly<\/strong>, but you can <strong>easily overcome those issues<\/strong> (even at this beta stage). InstallAware&#8217;s <strong>flexible MSICode <\/strong>lets you <strong>do anything you want<\/strong>. For example, I&#8217;ve <strong>manually calculated the <\/strong><strong>TotalRequiredSpace value using MSICode<\/strong>, because the static label showing <strong>TotalRequiredSpace<\/strong> renders incorrectly on Glass, as a black rectangle.<\/p>\n<p>\u00c2\u00a0<a href=\"http:\/\/www.hostme.gr\/files\/5ryidy4tjt1zmnenhmjb.jpg\" target=\"_blank\"><img decoding=\"async\" src=\"http:\/\/www.hostme.gr\/files\/5ryidy4tjt1zmnenhmjb.jpg\" \/><\/a><\/p>\n<p>I used the <strong>MSIcode functions<\/strong> <strong>&#8220;Get Component Space&#8221;<\/strong> to get the total bytes required, <strong>&#8220;Mathematics&#8221; <\/strong>to convert those bytes into KB or MB, and then <strong>&#8220;Set Variable&#8221;<\/strong> to concatenate the string &#8220;KB&#8221; or &#8220;MB&#8221; at the end of the value &#8211; finally displaying the result in a regular label, which does render correctly.<\/p>\n<p><strong>Conclusion<\/strong><\/p>\n<p>I&#8217;ve <strong>said <\/strong>this <strong>before<\/strong> but I&#8217;m going to <strong>say it again<\/strong>. By <strong>leveraging the Aero Experience<\/strong> on your setups, you <strong>impress your customers<\/strong> &#8211; on every single trial download! Give them <strong>the &#8220;wow&#8221;<\/strong> feeling <strong>right from the beginning<\/strong>&#8230;with your setup! You can also <strong>create your own themes<\/strong> by <strong>using<\/strong> the VistaGlass component and building on top of empty dialogs, or based off of an existing theme. You <strong>could even replicate, for example, the look and feel of Office 2007 installations using the tab component<\/strong>!<\/p>\n<p>That&#8217;s all for today. <strong>Stay tuned<\/strong> people, <strong>more to come<\/strong>.<\/p>\n<p>Panagiotis Kefalidis<br \/>\nInstallAware CCP &#8212; DataFire Software, Greece<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hello again. I&#8217;d promised myself to make at least one post per week here, but the last two weeks, boy, have been a hell of a time for me &#8211; I almost broke my leg and then got a real bad cold that&#8217;s still bothering me. Now I know how Walt Disney&#8217;s Donald Duck feels &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.installaware.com\/blog\/?p=9\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;InstallAware goes Aero with Vista Glass component&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9,1],"tags":[],"class_list":["post-9","post","type-post","status-publish","format-standard","hentry","category-custom-dialogs","category-news"],"_links":{"self":[{"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/9","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=9"}],"version-history":[{"count":0,"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/9\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.installaware.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}