librelist archives

« back to archive

Sheets and transparency

Sheets and transparency

From:
Vernon Thommeret
Date:
2011-08-14 @ 04:06
Hey,

I was wondering if using standard AppKit sheets is something that's 
supported with TwUI or if it should be implemented manually? I'm more or 
less able to host a TuiView in a sheet, but I can't seem have the sheet be
appropriately transparent without it glitching out:

https://img.skitch.com/20110814-p9iq7eq189jkqsxbf73k6s448k.png

This is the particular setup I'm using:

https://gist.github.com/bbeeea8dc4c6f2118ed4

If I switch to using a solid color for the background, it works, but isn't
ideal. I'll probably move away from a sheet for this particular solution, 
but I was curious if it's possible to pull off?

Thanks!
Vernon

Re: [twui] Sheets and transparency

From:
Loren Brichter
Date:
2011-08-14 @ 04:30
On my phone so I can't try it now - but see what happens with a 
setOpaque:NO on your tuiContainer

Loren

On Aug 14, 2011, at 12:06 AM, Vernon Thommeret <synotic@gmail.com> wrote:

> Hey,
> 
> I was wondering if using standard AppKit sheets is something that's 
supported with TwUI or if it should be implemented manually? I'm more or 
less able to host a TuiView in a sheet, but I can't seem have the sheet be
appropriately transparent without it glitching out:
> 
> https://img.skitch.com/20110814-p9iq7eq189jkqsxbf73k6s448k.png
> 
> This is the particular setup I'm using:
> 
> https://gist.github.com/bbeeea8dc4c6f2118ed4
> 
> If I switch to using a solid color for the background, it works, but 
isn't ideal. I'll probably move away from a sheet for this particular 
solution, but I was curious if it's possible to pull off?
> 
> Thanks!
> Vernon

Re: [twui] Sheets and transparency

From:
Vernon Thommeret
Date:
2011-08-14 @ 05:28
I was able to subclass TUINSView and implement (bool)isOpaque, which fixed
the glitchy drawing. There's an ab_setIsOpaque method, but it's 
deprecated. Strangely just creating the panel and showing it, it's still 
not transparent (isOpaque returns NO) but that doesn't seem like a 
TwUI-specific issue since throwing up an alert sheet is transparent, so 
I'll keep investigating.

Thanks,
Vernon

On Aug 14, 2011, at 12:30 AM, Loren Brichter wrote:

> On my phone so I can't try it now - but see what happens with a 
setOpaque:NO on your tuiContainer
> 
> Loren
> 
> On Aug 14, 2011, at 12:06 AM, Vernon Thommeret <synotic@gmail.com> wrote:
> 
>> Hey,
>> 
>> I was wondering if using standard AppKit sheets is something that's 
supported with TwUI or if it should be implemented manually? I'm more or 
less able to host a TuiView in a sheet, but I can't seem have the sheet be
appropriately transparent without it glitching out:
>> 
>> https://img.skitch.com/20110814-p9iq7eq189jkqsxbf73k6s448k.png
>> 
>> This is the particular setup I'm using:
>> 
>> https://gist.github.com/bbeeea8dc4c6f2118ed4
>> 
>> If I switch to using a solid color for the background, it works, but 
isn't ideal. I'll probably move away from a sheet for this particular sol 
ution, but I was curious if it's possible to pull off?
>> 
>> Thanks!
>> Vernon