Re: "Highlight" a window of another application
Re: "Highlight" a window of another application
- Subject: Re: "Highlight" a window of another application
- From: Uli Kusterer <email@hidden>
- Date: Thu, 24 Feb 2011 11:33:05 +0100
On 24.02.2011, at 10:44, eveningnick eveningnick wrote:
> I need to somehow "impact" a particular window for the user, make it bold,
> change it's shadow color or add some kind of a frame around it - to remind
> the user that only this particular window is being 'grabbed'.
> Does WindowServer allow to perform such kind of operations on any level?
> What APIs should i look at?
Use the CGWindow APIs to find out stuff about windows of other applications (or failing that, the Accessibility APIs can be abused).
> Also i am wondering if there is a way to create a "transparent window" - a
> window, that has a frame and a title bar, but whose insides are transparent
> - you can click with a mouse button on it and your click will "go" to the
> other window,
Yes, if you create a borderless window, you can create it at the right size, in a layer that floats above other windows, make it transparent to clicks if so desired, and draw all sorts of markers in it. IIRC this is how e.g. KNAppGuide draws its coach marks around UI elements, and how Apple's screen capture code does the Cmd-Shift-4 rubberband selection and the highlighting of individual windows if you hit the space key while in Cmd-Shift-4 mode.
Cheers,
-- Uli Kusterer
"The Witnesses of TeachText are everywhere..."
http://www.lookandfeelcast.com
_______________________________________________
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