New topic: Figureshape Fill does not work in Windows
<http://forums.realsoftware.com/viewtopic.php?t=48032> Page 1 of 1 [ 4 posts ] Previous topic | Next topic Author Message kermit Post subject: Figureshape Fill does not work in WindowsPosted: Sat Jun 01, 2013 1:52 am Joined: Mon May 30, 2011 12:56 am Posts: 701 Using 2012R2 Windows Home Prem 7 In the paint event of a canvas, I create a figureshape by adding an array of points I set the color to &cFF0000 I add the points I set the .Fill to 50 Then g.drawshape thefigureshape And it is solid, not transparent. Any value lower than 50, its invisible, over 50 it is solid. The same code on the Mac gives me a properly transparent shape. ANyone know why that might be? Top Karen Post subject: Re: Figureshape Fill does not work in WindowsPosted: Sat Jun 01, 2013 10:11 am Joined: Fri Sep 30, 2005 8:53 am Posts: 1002 Set app.UseGDIPlus to true - Karen Top kermit Post subject: Re: Figureshape Fill does not work in WindowsPosted: Sun Jun 02, 2013 1:22 am Joined: Mon May 30, 2011 12:56 am Posts: 701 Thanks Karen. Seems odd to have to resort to that, but it got me there. It works now. Couple of interesting points that make me still think this is a bug: a) In another part of the application, I have identical code on another canvs, and it work perfectly without GDIPlus (yes, checked very carefully) b) I tried GDIPlus around my code at one point and it didnt make any difference. What I have now, (and it didn't work until I did things this way, I could start removing things until it stops working again, but I wasted a day on this already) in the Paint event of my canvas, I create a new picture of the same size as the canvas. Set app.GDIPlus to true Draw all my painting on the new picture g.drawpicture my new picture to the graphics contaxt of the paint event GDIPlus = false exit sub Top Markus Winter Post subject: Re: Figureshape Fill does not work in WindowsPosted: Sun Jun 02, 2013 2:08 am Joined: Sun Feb 19, 2006 4:00 pm Posts: 1282 Location: Heidelberg, Germany kermit wrote:Seems odd to have to resort to that, but it got me there. Windows did not support true transparency, you had to fake it. That changed with GDIplus. So it's not odd but was a limitation of Windows. Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 4 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]
