• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Partially opaque window with opaque views
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Partially opaque window with opaque views


  • Subject: Partially opaque window with opaque views
  • From: Trygve Inda <email@hidden>
  • Date: Tue, 05 Oct 2010 10:25:45 +0000
  • Thread-topic: Partially opaque window with opaque views

Is there a way to have a window with a 50% opaque background, but several
odd-shaped views that are 100% opaque? The dock does this but seems be one
window per icon. Can I do it all as one window?

My NSWindow subclass looks like:

[self setOpaque:NO];
[self setHasShadow: YES];
[self setLevel:NSFloatingWindowLevel];
[self setAlphaValue:0.50];

This sets the alpha of the whole window to 50% (and works) but If I add a
line or replace the alpha line with: [[self contentView]
setAlphaValue:0.50];

Then the window is totally opaque... Even subviews in the main contentView.

Any way to do this w/o using multiple windows?

Trygve


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Partially opaque window with opaque views
      • From: Uli Kusterer <email@hidden>
    • Re: Partially opaque window with opaque views
      • From: Matt Gough <email@hidden>
  • Prev by Date: FSCatalogSearch miss file
  • Next by Date: NSOutlineView multi cell type binding query
  • Previous by thread: FSCatalogSearch miss file
  • Next by thread: Re: Partially opaque window with opaque views
  • Index(es):
    • Date
    • Thread