New topic: Icon Image and Mask rolled into one PNG file using Photoshop
<http://forums.realsoftware.com/viewtopic.php?t=31361> Page 1 of 1 [ 6 posts ] Previous topic | Next topic Author Message fwRoller Post subject: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Tue Dec 01, 2009 8:40 pm Joined: Thu Aug 10, 2006 10:56 am Posts: 125 Location: Allentown, PA Does REALbasic support icons that have masks built-in? I've successfully used pairs (one for image and one for mask) of icon files but would like to merge them into one, just as you would for a website. PNG and other graphic formats support this feature but I've not had any luck getting them to work with REALbasic, even though they look good in a web browser. If REALbasic does support a single graphic image that has a built-in mask for an icon, please explain the procedure to go from a single layer PNG to one that has as mask. Top thommcgrath Post subject: Re: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Tue Dec 01, 2009 9:39 pm Site Admin Joined: Tue May 06, 2008 1:07 pm Posts: 322 Location: Greater Hartford Area, CT PNG is supported, just use OpenAsPicture. _________________ -- Thom McGrath IT Developer, REAL Software Top fwRoller Post subject: Re: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Tue Dec 01, 2009 9:45 pm Joined: Thu Aug 10, 2006 10:56 am Posts: 125 Location: Allentown, PA Sorry, I should have been more thorough in my explanation. I'm using the icons for the Icon property of the Application class, so they won't be opened programmatically. They're in sizes of 256, 128, 48, 32, and 16. Each size has a pair of image files, one for the image and one for the mask. I would like to combine them so that there is one image file for each resolution that contains both the image and mask. Top thommcgrath Post subject: Re: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Tue Dec 01, 2009 9:57 pm Site Admin Joined: Tue May 06, 2008 1:07 pm Posts: 322 Location: Greater Hartford Area, CT I might be mistaken, but I recall something about being able to PNG files into that view, or use copy/paste. I'm not certain though, Norman would know better, as he deals with the IDE code more than I do. Try it and see. If that doesn't work, maybe Norman will speak up and confirm this one way or another. _________________ -- Thom McGrath IT Developer, REAL Software Top npalardy Post subject: Re: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Tue Dec 01, 2009 10:19 pm Joined: Sat Dec 24, 2005 8:18 pm Posts: 5454 Location: Canada, Alberta, Near Red Deer PNG's with alpha channels should work fine for app icons and be automagically separated into the image and mask We did that a couple revisions ago _________________ My web site Great White Software RBLibrary.com REALbasic learning Top fwRoller Post subject: Re: Icon Image and Mask rolled into one PNG file using PhotoshopPosted: Wed Dec 02, 2009 4:22 pm Joined: Thu Aug 10, 2006 10:56 am Posts: 125 Location: Allentown, PA After some retries it does work, but is very flaky. Here are some easily repeatable examples in REALbasic 2009r5. In a new project that has no icons already assigned, open the Edit Icon dialog box from the Icon row in the properties pane of the Application. Right clicking on the 256 x 256 row, which is already highlighted, doesn't work. The same is true for Image, Mask, and Preview. The first (and sometimes consecutive) right click doesn't work when the dialog box is first opened. That's issue number one. Click Cancel to close the Edit Icon dialog box and then open it again. Left click on Preview then right click on the 256 x 256 row and add your appropriately sized PNG with an alpha channel. It automagically gets separated into an image and mask but only Preview is populated, not Image or Mask until you click on another row in the Icon Variations listbox and then back on the 256 x 256 row. That's issue number two. Click Cancel to close the Edit Icon dialog box and then open it again. Left click on either Image or Mask then right click on the 256 x 256 row and add your appropriately sized PNG with an alpha channel. It does NOT get separated. What does happen is that you get either the image or the mask, depending on whether you previously clicked on Image or Mask, but you won't get both. That's issue number three. There is more flakiness to be found if you attempt to add and change icons for all of the icon variations. The behavior is not intuitive and that's the biggest issue of all. All of this was tested in REALbasic 2009r5 on Mac OS X 10.6.2, Windows 7 Ultimate, and Ubuntu 9.10. If anyone else has found inconsistencies or non-intuitive behavior and is willing to document it, then please do in this thread. I'll follow up by using the Feedback system to formally document the issues hoping that they'll get addressed. Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 6 posts ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
