Re: window on aqua without a titlebar

[email protected] (Kevin Walzer) Sun, 02 Dec 2012 23:05:07 -0500
Newsgroups perl.tcltk
Organization WordTech Communications LLC
Message-ID <[email protected]>
On 12/2/12 10:48 PM, Mike Ignatoski wrote:
> In addition, I'm using the window as a tooltip/balloon hover window, so
> when it's shown, I never want it to have the "focus".  When I deiconfy
> it on Win32, it works great, but on OS X (aqua), it shows the window and
> also grabs the focus, so I have to click on the main app to return focus.

The Tcl/Tk code on Aqua to achieve the effect you want looks something 
like this:

  if {[string equal [tk windowingsystem] aqua]}  {
	::tk::unsupported::MacWindowStyle style $top help none
     }

where $top is a toplevel window. That doesn't grab focus.

-- 
Kevin Walzer
Code by Kevin
http://www.codebykevin.com