On Wed, Aug 8, 2012 at 4:25 AM, Mojca Miklavec wrote:
> On Wed, Aug 8, 2012 at 1:28 AM, Ethan A Merritt wrote:
>> On Tuesday, August 07, 2012 07:08:06 am Mojca Miklavec wrote:
>>
>>> Gnuplot needs a patch to make transparency work though:
>>> - AQUA_hasAlphaSupport = [AQTAdapter
>>> respondsToSelector:@selector(setColorRed:green:blue:alpha:)];
>>> + AQUA_hasAlphaSupport = [adapter
>>> respondsToSelector:@selector(setColorRed:green:blue:alpha:)];
>>
>> Otherwise it needs to be wrapped in some version check.
>
> This *is* the version check (or rather: feature check).
>
> All the wrappers for transparency follow later. The problem is that
> all wrappers assume that transparency is not supported based on the
> result of this wrong check, and thus transparency is never used at
> all.
An alternative way would also be to do that check during configuration
and then replace
if (AQUA_hasAlphaSupport)
[adapter setColorRed:r green:g blue:b alpha:a];
else
[adapter setColorRed:r green:g blue:b];
by
#ifdef HAS_AQUATERM_TRANSPARENCY
[adapter setColorRed:r green:g blue:b alpha:a];
#else
[adapter setColorRed:r green:g blue:b];
#endif
to avoid compiler warnings when old AquaTerm is used, but that's
probably too big hammer for a too tiny problem anyway (and compiler
warnings will go away once people upgrade aquaterm).
Mojca
|