Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread G S
The Apple doc says, "If the view controller has an associated nib file, this method loads the view from the nib file. A view controller has an associated nib file if the nibName

Re: How to: NSTableView redisplay

2012-02-29 Thread Jens Alfke
On Feb 28, 2012, at 8:39 PM, Erik Stainsby wrote: > [_rules addObject: rule]; > [table reloadData]; > [table setNeedsDisplay:YES]; IIRC you need to call -noteNumberOfRowsChanged instead, if you've change the number of rows. -reloadData is just for reloading the existing rows.

Re: How to: NSTableView redisplay

2012-02-29 Thread Laurent Daudelin
On Feb 28, 2012, at 20:39, Erik Stainsby wrote: > Learning a new language makes me humble. > > NSTableView - I have an NSTableViewDataSource with an array holding the > objects to be represented in the table. > I add a new object to the array, I call [table reloadData]; and I follow that > with

Re: How to: NSTableView redisplay

2012-02-29 Thread Quincey Morris
On Feb 28, 2012, at 20:39 , Erik Stainsby wrote: > NSTableView - I have an NSTableViewDataSource with an array holding the > objects to be represented in the table. > I add a new object to the array, I call [table reloadData]; and I follow that > with [table setNeedsDisplay:YES]; > Bupkiss. Nada

Re: How to: NSTableView redisplay

2012-02-29 Thread Graham Cox
On 29/02/2012, at 5:47 PM, Jens Alfke wrote: > > On Feb 28, 2012, at 8:39 PM, Erik Stainsby wrote: > >> [_rules addObject: rule]; >> [table reloadData]; >> [table setNeedsDisplay:YES]; > > IIRC you need to call -noteNumberOfRowsChanged instead, if you've change the > number of

play time

2012-02-29 Thread Eric Slosser
I have a QTMovieView, I'd like to find out when the user clicks the control. So I subclass it, and override 'play:'. My 'play:' is never called. I couldn't find a notification or delegate method corresponding to 'movie did start playing'. I tried QTMovieStatusStringPostedNotification, but am

Re: How to support larger NSView hierarchy?

2012-02-29 Thread Steve Christensen
On Feb 27, 2012, at 10:21 PM, Quincey Morris wrote: > On Feb 27, 2012, at 20:46 , Graham Cox wrote: > >> Jeez. > > Indeed. Especially as it's usually taken as a given that large numbers of > NSViews aren't going to perform well. Trying to make the scenario work might > be quixotic at best. >

Fwd: NSPasteboardItem kPasteboardTypeFileURLPromise

2012-02-29 Thread David Riggle
I've been struggling with the new NSPasteboard APIs as well. The lack of sample code is appalling. I finally got file promises to work by incorporating some low level pasteboard manager calls. Note that NSPasteboard is not toll-free bridged with PasteboardRef, but you can go back & forth between

Re: play time

2012-02-29 Thread Eric Slosser
The secret sauce is watching QTMovieRateDidChangeNotification. On Feb 29, 2012, at 6:06 AM, Eric Slosser wrote: > I have a QTMovieView, I'd like to find out when the user clicks the > control. > > So I subclass it, and override 'play:'. My 'play:' is never called. > > I couldn't find a notif

Re: How to: NSTableView redisplay

2012-02-29 Thread Erik Stainsby
The is connected to the nib. The is not instantiated elsewhere. Content does show up after the table column headers are manipulated so the column defs are reasonable. I'll give Jens' suggestion a try but I have only seen the form below cited. I'll remove the extraneous setNeedsDisplay: call

Re: How to: NSTableView redisplay

2012-02-29 Thread Erik Stainsby
Supplemental: the table only renders once. However many objects are in the _rules array are presented when any column header is activated. Then the table freezes up. Additionally items can be added to the array; nothing more happens with the table view. Erik Stainsby erik.stain...@roaringsky

Re: Round corners of borderless NSWindow without set it transparent

2012-02-29 Thread Corbin Dunn
On Feb 28, 2012, at 12:54 PM, Andrea3000 wrote: > Il giorno 28/feb/2012, alle ore 20:20, Corbin Dunn ha scritto: > >> >> On Feb 27, 2012, at 11:51 PM, Andrea3000 wrote: >>> >>> When the window is small it's as fast as if it were opaque but when it >>> occupies quite all the screen (1920x108

Re: Round corners of borderless NSWindow without set it transparent

2012-02-29 Thread Andrea3000
Il giorno 28/feb/2012, alle ore 21:54, Andrea3000 ha scritto: > Il giorno 28/feb/2012, alle ore 20:20, Corbin Dunn ha scritto: >> >> Did you sample it or use Instruments? What is slow? > > The resize is slow. > When the window is small I can resize it as fast as I want and the resize > animat

Re: iBook integration

2012-02-29 Thread Fritz Anderson
On 28 Feb 2012, at 11:12 PM, Jamie Daniel wrote: > Has anyone information on embedding iBook viewing in an iOS application? To my knowledge (and to the extent of my search of the documentation — try it yourself), it's not possible. I can think of many reasons it will never be possible, but I ca

Re: Round corners of borderless NSWindow without set it transparent

2012-02-29 Thread Andrea3000
Il giorno 29/feb/2012, alle ore 17:56, Corbin Dunn ha scritto: > > On Feb 28, 2012, at 12:54 PM, Andrea3000 wrote: > >> Il giorno 28/feb/2012, alle ore 20:20, Corbin Dunn ha scritto: >> >>> >>> On Feb 27, 2012, at 11:51 PM, Andrea3000 wrote: When the window is small it's as fast

Re: Xcode - An Apple Embarrassment

2012-02-29 Thread Matt Neuburg
> > On 28 feb 2012, at 22:26, Lee Ann Rucker wrote: > > > Plus there's no [...] jump to documentation. > > > Is too! > > Option+DoubleClick > *No*. I've said it before (right here) and I'll say it again; this is *not* jumping to the documentation, and it is *not* doing what Xcode 3 di

Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread Matt Neuburg
> Date: Tue, 28 Feb 2012 22:36:38 -0800 > From: G S > To: cocoa-dev > > > So I did override loadView, simply to write to a log and then call [super > loadView]. If you override loadView you must *not* call super. To put it another way, don't implement loadView unless you mean it (i.e. you in

Placeholder text on a multi-line NSTextField

2012-02-29 Thread Geoff Beier
I've opened radar #10954811 about the appearance of placeholder text in a multi-line NSTextField. If the placeholder is sufficiently long, when a user clicks the field and starts typing, only the first line of placeholder text gets cleared until the edit is finished. I ran across this while pickin

Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread David Duncan
On Feb 28, 2012, at 10:36 PM, G S wrote: > So I did override loadView, simply to write to a log and then call [super > loadView]. In the log, I verified that the controller's loadView method IS > being called after the overlapping view is dismissed. I also verified that > the object's nibName pr

How do IB inspector fields relate to the actual objects?

2012-02-29 Thread Howard Moon
Hi, I've added a Panel to a nib for an audio plug-in I'm working on, and am having trouble determining how the IB Inspector settings relate to the actual objects, such as an NSPanel. In the Inspector, there are several Style Mask checkboxes: Utility HUD Non Act

Autolayout: How to force calling [NSView baselineOffsetFromBottom] again?

2012-02-29 Thread Manfred Schwind
Hi, I have a view hierarchy using Cocoa Autolayout (new in Lion) loaded from a nib. After the nib is loaded, I do some additional configuration for some views (mostly in awakeFromNib). Specifically I have a NSTextField subclass and the additional configuration causes my custom baselineOffsetFrom

Re: Round corners of borderless NSWindow without set it transparent

2012-02-29 Thread Fritz Anderson
On 29 Feb 2012, at 11:14 AM, Andrea3000 wrote: > I've used Instruments and the only relevant thing that I've noticed is that > when the window is opaque and I resize it like a mad, WindowServer process > jumps to 30% of CPU usage at its max but when the window is transparent and I > resize it

Re: How do IB inspector fields relate to the actual objects?

2012-02-29 Thread Ken Thomases
On Feb 29, 2012, at 1:03 PM, Howard Moon wrote: > I've added a Panel to a nib for an audio plug-in I'm working on, and am > having trouble determining how the IB Inspector settings relate to the actual > objects, such as an NSPanel. In the Inspector, there are several Style Mask > checkb

Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread G S
Thanks guys. The problem happens with no override of loadView. I only overrode it to verify that it was being called after the memory warning, and to verify that nibName was set. In viewDidLoad, I just instantiate a data collection and progress indicator. _

Re: Round corners of borderless NSWindow without set it transparent

2012-02-29 Thread Andrea3000
Il giorno 29/feb/2012, alle ore 21:26, Fritz Anderson ha scritto: > On 29 Feb 2012, at 11:14 AM, Andrea3000 wrote: > >> I've used Instruments and the only relevant thing that I've noticed is that >> when the window is opaque and I resize it like a mad, WindowServer process >> jumps to 30% of

Re: Placeholder text on a multi-line NSTextField

2012-02-29 Thread Ross Carter
Use the delegate method control:textShouldBeginEditing: to set the placeholder string to nil when editing begins, and control:textShouldEndEditing: to restore the placeholder if the text field is empty? On Feb 29, 2012, at 1:23 PM, Geoff Beier wrote: > I've opened radar #10954811 about the app

Re: Xcode - An Apple Embarrassment

2012-02-29 Thread Matt Neuburg
On Wed, 29 Feb 2012 09:28:31 -0800, Matt Neuburg said: >> >> On 28 feb 2012, at 22:26, Lee Ann Rucker wrote: >> >> > Plus there's no [...] jump to documentation. >> >> >> Is too! >> >> Option+DoubleClick >> > >*No*. Sorry, wrong list. m. -- matt neuburg, phd = m...@tidbits.com,

Re: How do IB inspector fields relate to the actual objects?

2012-02-29 Thread Matt Neuburg
On Wed, 29 Feb 2012 11:03:31 -0800, Howard Moon said: >Hi, > > I've added a Panel to a nib for an audio plug-in I'm working on, and am > having trouble determining how the IB Inspector settings relate to the actual > objects, such as an NSPanel. In the Inspector, there are several Style M

Re: How do IB inspector fields relate to the actual objects?

2012-02-29 Thread Howard Moon
Thanks, Ken! On Feb 29, 2012, at 1:39 PM, Ken Thomases wrote: > On Feb 29, 2012, at 1:03 PM, Howard Moon wrote: > >> I've added a Panel to a nib for an audio plug-in I'm working on, and am >> having trouble determining how the IB Inspector settings relate to the >> actual objects, such as

Re: How to: NSTableView redisplay

2012-02-29 Thread Graham Cox
On 01/03/2012, at 3:49 AM, Erik Stainsby wrote: > Supplemental: the table only renders once. However many objects are in the > _rules array are presented when any column header is activated. Then the > table freezes up. Additionally items can be added to the array; nothing more > happens wit

Modal only to another window?

2012-02-29 Thread Howard Moon
HI, I have a an audio plug-in, run inside a host application, that provides me a window in which my plug-in's UI is drawn. What I would like to do is to make a modal window, but one that in ONLY modal in relation to my plug-in window. Is that possible? It's easy on Windows, but I don

Re: Placeholder text on a multi-line NSTextField

2012-02-29 Thread Geoff Beier
Thanks. That got me pointed in the right direction. Setting the placeholder string to nil in control:textShouldBeginEditing clears the stray second line away nicely. Setting it back in control:textShouldEndEditing appears to prevent editing from actually ending. Setting it back in the control's act

Re: How do IB inspector fields relate to the actual objects?

2012-02-29 Thread koko
Uncheck 'Visible At Launch' in the attributes Inspector with the Window selected. No it will not display until you tell it. So you might do NSWindow *w = [NSWindowController window] This wil cause your willDidLoad method to be called then you might [w makeKeyAndOrderFront]; and if you want

Localizing MainMenu.xib?

2012-02-29 Thread Marc Respass
Hi All, My application is completely localized (though only two languages) everywhere except the menu bar. I'm not sure what the best approach is to localize the main menu. Some items like undo/redo are localized for me. Others are not. I admit that I am a little surprised that standard system

Re: How do IB inspector fields relate to the actual objects?

2012-02-29 Thread Keary Suska
On Feb 29, 2012, at 12:03 PM, Howard Moon wrote: > Hi, > > I've added a Panel to a nib for an audio plug-in I'm working on, and am > having trouble determining how the IB Inspector settings relate to the actual > objects, such as an NSPanel. In the Inspector, there are several Style Mask

Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread G S
Well, I've verified that the view controller has the correct name of the nib when it tries to reload the view after a memory warning. So this seems like a pretty big Cocoa bug, which unfortunately only one (remote) person on our team can reproduce reliably. I know Instagram encountered this same

Re: Xcode - An Apple Embarrassment

2012-02-29 Thread Wade Tregaskis
> *No*. I've said it before (right here) and I'll say it again; this is *not* > jumping to the documentation, and it is *not* doing what Xcode 3 did. It > switches to the documentation window and it enters the double-clicked word > into the search field, and it does the search, but it doesn'

Re: How are views supposed to reload after being nillified by memory warnings?

2012-02-29 Thread Roland King
well in viewDidLoad take a look at view and the view hierarchy, where is it, what size is it, what alpha is it etc etc. On Mar 1, 2012, at 5:38 AM, G S wrote: > Thanks guys. > > The problem happens with no override of loadView. I only overrode it to > verify that it was being called after the

getting 'page visit notification' from HelpViewer.app

2012-02-29 Thread Eric Slosser
I want to know when a user visits a page in my app's help book. Is there a supported way? Since the pages are HTML, I'm thinking that perhaps I could put magic URLs on each page, like , then use Info.plist to tell the system that my app supports the "foo" protocol. Is there a better way? The

Re: iBook integration

2012-02-29 Thread John Joyce
On Mar 1, 2012, at 2:12 AM, Fritz Anderson wrote: > On 28 Feb 2012, at 11:12 PM, Jamie Daniel wrote: > >> Has anyone information on embedding iBook viewing in an iOS application? > > To my knowledge (and to the extent of my search of the documentation — try it > yourself), it's not possible. I

Re: Modal only to another window?

2012-02-29 Thread Charles Srstka
On Feb 29, 2012, at 5:05 PM, Howard Moon wrote: > I have a an audio plug-in, run inside a host application, that provides > me a window in which my plug-in's UI is drawn. What I would like to do is to > make a modal window, but one that in ONLY modal in relation to my plug-in > window.

Re: Modal only to another window?

2012-02-29 Thread Graham Cox
On 01/03/2012, at 10:05 AM, Howard Moon wrote: > HI, > > I have a an audio plug-in, run inside a host application, that provides > me a window in which my plug-in's UI is drawn. What I would like to do is to > make a modal window, but one that in ONLY modal in relation to my plug-in >

Re: Localizing MainMenu.xib?

2012-02-29 Thread John Pannell
Hi Marc- Matt Gemmell has a localized nibs package that includes the standard main menu nib in a variety of languages... http://mattgemmell.com/source/ It is about 3/4 the way down the page... hope this helps! John On Feb 29, 2012, at 4:32 PM, Marc Respass wrote: > Hi All, > > My applicatio

Re: Xcode - An Apple Embarrassment

2012-02-29 Thread Alex Zavatone
On Feb 29, 2012, at 7:41 PM, Wade Tregaskis wrote: >> *No*. I've said it before (right here) and I'll say it again; this is *not* >> jumping to the documentation, and it is *not* doing what Xcode 3 did. It >> switches to the documentation window and it enters the double-clicked word >> into th