• 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
Drawing in a window with rounded corners
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Drawing in a window with rounded corners


  • Subject: Drawing in a window with rounded corners
  • From: "Daniel Weber" <email@hidden>
  • Date: Mon, 29 Sep 2008 16:21:29 -0700

Hi, I have a custom view that takes up the whole frame of my textured
window. Normally, the corners of a textured window are rounded. However,
since my custom view is rectangular, it draws over the rounded corners. I am
using Core Animation to draw in the view. I think what I need to do is clip
my drawing so the corners are transparent, but I haven't been successful.
What I've tried so far is drawing a rectangle with rounded corners that
approximates the window's rounded corners using CGContextAddArcToPoint. Then
I call CGContextClip. But it's not working, all I'm seeing is garbage at the
window corners, not transparency. Any suggestions?

Thanks,
Dan
_______________________________________________

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 in a window with rounded corners
      • From: "Michael Ash" <email@hidden>
    • Re: Drawing in a window with rounded corners
      • From: Greg Best <email@hidden>
  • Prev by Date: Re: NSWindowController retain count confusion
  • Next by Date: Re: How to count composed characters in NSString?
  • Previous by thread: Re: NSWindowController retain count confusion
  • Next by thread: Re: Drawing in a window with rounded corners
  • Index(es):
    • Date
    • Thread