• 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
Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView


  • Subject: Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
  • From: Ken Thomases <email@hidden>
  • Date: Sun, 04 Aug 2013 12:56:06 -0500

On Aug 4, 2013, at 9:59 AM, Mills, Steve wrote:

> On Aug 4, 2013, at 9:45, "Nick Rogers" <email@hidden> wrote:
>
>> I have a column of buttons stacked up one over the other and on clicking a button I want to draw an image on it with an arrow protruding to the right. And on the right side there is a tab view and in it there is a table view.
>> So the arrow part of the image must overlap the tab view and table view and the table view is required to have normal behaviour even after this.
>>
>> Is this even possible?
>
> Create a view subclass that will draw the arrow on top. Embed the other views inside it.

I don't think that will work because the containing view will draw behind the contained views.

You can try making a view that's a sibling of both the button and the tab view and ordered on top of both.

Another approach would be to make a mostly-transparent overlay window to draw the arrow.  Make sure it ignores mouse events so clicks on the opaque parts go through.  Set it as a child window of the window containing the buttons and tab view, so it moves with it.  If the underlying window is resizable or changes its layout, you'll need to take care to keep the position of the arrow synchronized with the other controls.  (That's true of any approach you take, of course.)

Regards,
Ken


_______________________________________________

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: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
      • From: Steve Mills <email@hidden>
References: 
 >drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView (From: Nick Rogers <email@hidden>)
 >Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView (From: "Mills, Steve" <email@hidden>)

  • Prev by Date: Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
  • Next by Date: Re: Storing an NSImage File
  • Previous by thread: Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
  • Next by thread: Re: drawing outside the dirtyRect (of a NSView sub class) and overlapping NSTableView
  • Index(es):
    • Date
    • Thread