I am trying to figure out how best to draw the top of all the other elements on the OS X screen. I do not want to interfere with the user's ability to interact with their applications, but I want to “annotate” them. I want to be able to compose up to 20 different annotations. At the top of this screenshot from Gizmodo, it’s nice to show what I want to do. http://gizmodo.com/assets/resources/2006/07/04%20Safari.jpg (sorry, I'm too new to post it as an image)
I think I need to answer:
- Should I create one window for each drawing and draw on it? If so, how do I minimize service data?
- Which window or other context should I use, given that I do not want any window decoration?
I don’t think I need the overhead of creating 20 windows, but I also don’t know that I want to create a full-screen invisible window containing my context (I assume that NSView subclasses), because I fear that will a) cause problems interacting with what is lower, and b) violate the intricacies of only redrawing if necessary (my actual drawing will most likely cover only 10% of the screen)
I have not worked with Quartz2d before, so I just can’t figure out how to get the “right” context that can be extracted from the documentation. Any help would be appreciated.
Thanks,
Who
source share