nswindow

Layering Cocoa WebView - Drawing on top?

http://stackoverflow.com/questions/1618498/webview-in-core-animation-layer The only other thread I can find is the above which doesn't necessarily fit my needs. Is there a reliable way to simply draw a view on top of a webview? I've tried to layer a regular NSView on top of WebView, and it draws right at first, but any movement in the w...

Cocoa NSWindow not updating with data

I have an NSWindow that shows up when you click either of two items (both from an NSTableView). I have a setter method that tells the window what information to display. This all works perfectly, until it comes time to display the data in the window. If I cause the window to display from one tableview, then try to have it display the ...

Snow Leopard & LSUIElement -> application not activating properly, window not "active" despite being "key"

Hi, I'm running into a few problem with a background application that uses LSUIElement=1 to hide its dock item, menu bar and prevent it from appearing in the Command-Tab application switcher. It seems to be a Snow Leopard only problem. The application places an NSStatusItem in the menu bar and pops up a menu when clicked on. Selecting...

Cocoa/Objective-C - Child window with text input without main window becoming inactive

Hello All, I have a need to spawn a window that will hover just above my main window in a cocoa application. I want this main window to allow the user to enter some text in an input box. All is well until the text input box actually gains focus. The main window becomes "deactivated." This window is borderless and is a slightly custom sh...

Drop down view in cocoa

I'm looking to create a 'drop down' view that falls in front of the main window. An example of this would be the window that drops down when you click 'Advanced' in System Preferences->Networking. If someone could point me in the right direction documentation-wise that would be great. Thanks in advance. ...

Changing color of the NSWindow titlebar

Hi, I am developing a desktop application in which I want to change the color of the title bar of the NSWindow. How exactly can I do it? Could someone help me out? Thanks and regards, Deepa ...

Detecting if the window is a key window in cocoa

I am making a application that the user will have to interact with one window and when they have that window configured the way they want it they switch to a different application then my application will begin to do other stuff which i will have defined in a method say for an example program when the main window has focus it contains a...

NSWindow display alert when attempt to close

How can I display an NSAlert when an NSWindow attempts to close. This will also have to be turned on and off. ...

Dynamically removing and attaching the border on a nswindow

How do I go about adding/removing the window border after it has been created? the window was already designed in interface builder and I would prefer to avoid writing the window purely in code as I am still a long ways before i can say i am experienced with objective-c/cocoa. Example Program: a single window with the border initially, ...

NSWindow is not displaying.

Hi, I am having a trouble try to display a NSWindow with out using Interface Builder. The initialization of the window was quite confusing since I am more familiar with iPhone (which does not have an NSWindow equivalent). So I searched Google for some code and I eventually found this: NSRect windowRect = NSMakeRect(10.0f, 10.0f, 800.0f...

Is there an NSWindow notification/delegate method like "willShowWindow"?

Hi, I cannot seem to find it in the documentation but I'm looking for a way to run a method whenever a window is displayed on screen after launch of my app or after it has been closed and then reopened again. ...

Allow specific number of NSWindow copies to be visible

I have a button in my application, when you click it it opens a new NSWindow. However, if you keep on clicking it it will open another NSWindow. How can I limit the number of visible windows? ...

NSWindows receiving mouse events without taking focus

Hello, I am trying to create a NSWindow derived window which look likes a callout window and having teh following features: - can be placed everywhere on the screen - shouln't take the focuse of the currently focused window when bringed to front - have to reveive mouse events How should I do this? Thanks and regards, ...

Showing the NSToolbar only if hovering over the NSPanel

I am making a desktop application and I want to show the NSToolbar of an NSPanel only if the mouse pointer is positioned over that NSPanel. Also, when the mouse pointer is not positioned over that NSPanel, the NSToolbar should be hidden. Can anyone help me with detecting the hovering over the NSPanel, and showing and hiding the NSToolba...

Closing panel in one source file from a separate source file

This is what I got so far. - (IBAction)HUDPanelDictionaryHide:(id)sender{ extern NSPanel HUDPanelDictionary; [HUDPanelDictionary close]; } This obviously does NOT work. The HUDPanelDictionary is declared in a separate .h and .m file for an .xib file. I need to close this panel from the other .h and .m file for another .xib ...

Set Focus to a Cocoa Window in Carbon App

Hello, I'm trying to create a Cocoa Window within an otherwise Carbon Application (it's an OpenGL API that uses AGL. Can't change it so don't comment on that). Here's a code snippit: WindowRef winref = static_cast<eq::AGLWindow*>(getOSWindow())->getCarbonWindow(); vc = [[SFAttachedViewController alloc] initWithConfig:config]; //load...

How to remove square drawn around window resize handle in an NSScrollview?

I have an NSScrollview that takes up an entire window. The scrollview has a vertical scrollbar but no horizontal scrollbar. The window color is gray. The window is resizable. Cocoa automatically draws a white square with a light gray border around the window's resize handle (right below the bottom of the vertical scroller). I would li...

Refreshing NSTableView in inactive NSWindow

I have an application with a primary window and a floating window with a tableview in it. When I modify in the primary window the input for the floating window (which makes the floating window inactive or not key) then the tableview does not show the new data in spite of calling reloadData: on the tableview. I also tried refreshing the ...

cocoa : dock like window

Hello, I am looking to create a NSWindow behaving like the dock window: - Appears when the mouse cursor stays at one edge of the screen - Does not takes the focus (the app having the focus keeps it) but reveives mouse events Any idea on how I can implement this? Thanks in advance for your help, ...

bring window to front from its id/number

Hello, I am looking for a fast way to bring a window to from from its id (window number). Do you have any idea for this? Thanks in advance for your help. Regards, ...