Lazarus

Programming => Widgetset => QT => Topic started by: Ocye on May 18, 2012, 11:59:52 am

Title: Transparency with Qt on Darwin
Post by: Ocye on May 18, 2012, 11:59:52 am
I (strech-)draw an image which transparent color is set to clWhite along with some other layers on a bitmap. That works for Windows and Linux (both Gtk2 and Qt) but not with Qt on Darwin. Is it a known bug? What can I do?
Title: Re: Transparency with Qt on Darwin
Post by: zeljko on May 20, 2012, 06:58:09 pm
qt version, lazarus version ?
Title: Re: Transparency with Qt on Darwin
Post by: Ocye on May 20, 2012, 08:14:43 pm
I have no idea how to retrieve the Qt version for Darwin. Perhaps in this way:
Quote from: otool -L /Library/Frameworks/QtCore.framework/Versions/Current/QtCore
/Library/Frameworks/QtCore.framework/Versions/Current/QtCore:
   QtCore.framework/Versions/4/QtCore (compatibility version 4.7.0, current version 4.7.4)
Quote from: system_profiler SPSoftwareDataType
System Version: Mac OS X 10.6.4 (10F569)
Kernel Version: Darwin 10.3.0
Quote from: Lazarus Help
Lazarus 1.1 r37348M FPC 2.6.0 i386-darwin-carbon

I resolved the problem by using a png instead of bmp. If you want to test the issue, a simple project is attached to this thread http://www.lazarus.freepascal.org/index.php/topic,17005.0.html
Title: Re: Transparency with Qt on Darwin
Post by: zeljko on May 21, 2012, 01:40:35 pm
I've fixed taskbar appereance for dragimagelist in qt and gtk2, but if it work for png under darwin then fine.
Title: Re: Transparency with Qt on Darwin
Post by: Ocye on May 21, 2012, 05:40:15 pm
Taskbar entry is okay now but bitmaps don't become transparent. At least those I load from resource.
To make it clear: If I load a bmp from resource and set a particular color to be transparent it isn't applied. When the resource contains a png with transparency it works as expected.
Not a big issue for me. The taskbar thing was much more annoying  8)