Re: KVO on objects in NSArrayController

2011-09-02 Thread Jerry Krinock
On 2011 Sep 02, at 22:22, Trygve Inda wrote: >> Briefly, you can configure the checkbox cell (either in IB or >> programmatically) to have an action… > I think this sounds like a much better option than trying to use KVO. Indeed it is, *if* you literally want the notification, as you said in yo

Re: Custom Cell Bindings

2011-09-02 Thread Seth Willits
On Sep 2, 2011, at 9:52 PM, Quincey Morris wrote: > TBH, I'm not sure I understand the question exactly. We might need an example > of the sort of objects you're dealing with. > > However, I think you're laboring under a misapprehension. The object values > which are displayed in a table view *

Re: KVO on objects in NSArrayController

2011-09-02 Thread Trygve Inda
> On Sep 2, 2011, at 19:01 , Trygve Inda wrote: > >> I have an array of objects (of class MyObject) managed by an >> NSArrayController and displayed in an NSTable (via bindings). >> >> One property of MyObject is a BOOL "marked". >> >> I need to be notified whenever the user toggles a "marked" c

Re: Custom Cell Bindings

2011-09-02 Thread Quincey Morris
On Sep 2, 2011, at 17:12 , Seth Willits wrote: > Say I have a custom NSCell subclass (or maybe NSActionCell) which implements > some custom UI for manipulating some immutable value type which I can't use > any of the standard cell subclasses for. If this cell is the data cell in a > table colum

Re: KVO on objects in NSArrayController

2011-09-02 Thread Quincey Morris
On Sep 2, 2011, at 19:01 , Trygve Inda wrote: > I have an array of objects (of class MyObject) managed by an > NSArrayController and displayed in an NSTable (via bindings). > > One property of MyObject is a BOOL "marked". > > I need to be notified whenever the user toggles a "marked" checkbox in

Re: KVO on objects in NSArrayController

2011-09-02 Thread Jerry Krinock
On 2011 Sep 02, at 19:01, Trygve Inda wrote: > What is the best way to do this? Do I need to add an observer to every > object in the array (there are about 8,000 of them). If you want to use KVO, yes. I recall some sample code, written by mmalc. I forgot if it was on stepwise.com (which mean

Re: Introductions to OOP?

2011-09-02 Thread Ian Joyner
To understand the why of OO there is Bertrand Meyer's book Object-Oriented Software Construction: http://docs.eiffel.com/book/method/object-oriented-software-construction-2nd-edition It is big, but maybe the most complete and easy-to-read book on the subject. But you have to hang up any addicti

KVO on objects in NSArrayController

2011-09-02 Thread Trygve Inda
I have an array of objects (of class MyObject) managed by an NSArrayController and displayed in an NSTable (via bindings). One property of MyObject is a BOOL "marked". I need to be notified whenever the user toggles a "marked" checkbox in my NSTable. What is the best way to do this? Do I need to

Custom Cell Bindings

2011-09-02 Thread Seth Willits
Say I have a custom NSCell subclass (or maybe NSActionCell) which implements some custom UI for manipulating some immutable value type which I can't use any of the standard cell subclasses for. If this cell is the data cell in a table column, binding the column's content to an array controller

Re: Possible causes of "attempted layout while textStorage is editing"?

2011-09-02 Thread Martin Wierschin
>> On 01/09/2011, at 8:52 PM, jonat...@mugginsoft.com wrote: >> >> Is it possible that the user is editing the textview when this code is >> triggered? >> From the looks of the trace you react directly to the mouseDown event in >> another view which might not give NSTextView opportunity to concl

Re: Introductions to OOP? [was: Re: Large over 100K pixel high ruler scroll view]

2011-09-02 Thread koko
Just stay away from th e1986 Byte Magazine article describing OOP ... pretty funny actually. -koko On Sep 2, 2011, at 11:04 AM, Jens Alfke wrote: > > On Sep 1, 2011, at 9:26 PM, Julie Porter wrote: > >> Again I am impressed with the help I received here. Hopefully others will >> be able to

Re: NSOutlineView - Items only displays when user scrolls in outline view

2011-09-02 Thread Gilles Celli
Michael & Graham: thanks for the reply I agree that my Item class and its structure for the outline view has to be reworked...I'll let you know since I'm on vacancy for one week… -Gilles On 2 sept. 2011, at 14:35, Michael Babin wrote: > On Sep 2, 2011, at 7:15 AM, Gilles Celli wrote: > >> I'

Re: Introductions to OOP? [was: Re: Large over 100K pixel high ruler scroll view]

2011-09-02 Thread Andreas Mayer
Am 02.09.2011 um 19:04 schrieb Jens Alfke: > I’d like to be able to point people to a good introduction, either online or > in a book, but unfortunately I don’t know of any. Can anyone recommend > something? How about Apple's documentation? Object-Oriented Programming with Objective-C http://

Re: Introductions to OOP? [was: Re: Large over 100K pixel high ruler scroll view]

2011-09-02 Thread Jens Alfke
On Sep 2, 2011, at 10:32 AM, Bruno Candido Volpato da Cunha wrote: > Jens, please take a look at this site: > http://www.codeproject.com/KB/architecture/OOP_Concepts_and_manymore.aspx Thanks for the link. I’m not thrilled by the writing style (it’s awkward and has a lot of grammatical errors; I

Introductions to OOP? [was: Re: Large over 100K pixel high ruler scroll view]

2011-09-02 Thread Jens Alfke
On Sep 1, 2011, at 9:26 PM, Julie Porter wrote: > Again I am impressed with the help I received here. Hopefully others will > be able to read these threads and learn from the experience of others. Julie: You’re welcome! Gang: One result of this is that I’m realizing how difficult it is to ex

Re: Core Data Xcode 4 question

2011-09-02 Thread Roland King
yeah I run a custom step which runs mogenerator. It's great. I love that it splits the files into the auto generated piece and the customized piece. I would love for Xcode to generate classes the same way. On Sep 2, 2011, at 10:02 PM, Sean McBride wrote: > On Thu, 1 Sep 2011 17:56:43 -0400, An

Re: Core Data Xcode 4 question

2011-09-02 Thread Sean McBride
On Thu, 1 Sep 2011 17:56:43 -0400, Andrew Kinnie said: >Last I looked at mogenerator, it didn't support Xcode 4. There's no need for Xcode at all. You just point mogenerator to an .xcdatamodel file and voila! -- Sean McBride, B. Eng

Re: NSOutlineView - Items only displays when user scrolls in outline view

2011-09-02 Thread Graham Cox
On 02/09/2011, at 10:48 PM, Gilles Celli wrote: > Yes forgot to say that I've a data source for the outline view…. > > My OvItem.h class looks like this: Yes, but how and when does that structure get established? That's what matters here - obviously the data structure needs to be ready when t

Re: NSOutlineView - Items only displays when user scrolls in outline view

2011-09-02 Thread Gilles Celli
Yes forgot to say that I've a data source for the outline view…. My OvItem.h class looks like this: #import @interface OvItem : NSObject { NSString *title; NSMutableArray *children; BOOL isParent; } @property (nonatomic, readwrite, copy) NSString *title; @property

Re: NSOutlineView - Items only displays when user scrolls in outline view

2011-09-02 Thread Michael Babin
On Sep 2, 2011, at 7:15 AM, Gilles Celli wrote: > I've setup a Document based application with an NSOutlineView which displays > Parent-Item along with its children…with XCode 4 on OS X Lion. > > When launching the application, the outline view shows the Root title…only if > I refresh the outl

NSOutlineView - Items only displays when user scrolls in outline view

2011-09-02 Thread Gilles Celli
Hello, I've setup a Document based application with an NSOutlineView which displays Parent-Item along with its children…with XCode 4 on OS X Lion. When launching the application, the outline view shows the Root title…only if I refresh the outline view the children are displayed too. I've also

Re: Core Data Xcode 4 question

2011-09-02 Thread Andrew Kinnie
Thanks. I will give that a try. I have used EOGenerator many times (mostly automatically). My only concern now is not overwriting the exiting concrete classes. But I can handle that pretty easily. All in all, I love the idea, though I wish the automatic plugin worked in Xcode 4. On Sep 1

Re: determine whether an ancillary program/task can run

2011-09-02 Thread Rainer Brockerhoff
On 02/09/2011, at 00:13, Ken Thomases wrote: > On Sep 1, 2011, at 6:42 PM, Rainer Brockerhoff wrote: > >> On 01/09/2011, at 20:17, cocoa-dev-requ...@lists.apple.com wrote: >>> From: Martin Wierschin >>> Date: 1 de setembro de 2011 19:11:24 BRT >>> To: Dave DeLong >>> Cc: Cocoa Dev List >>> >

Re: NSScrollView animation (animate scroll point)

2011-09-02 Thread Daniel Vollmer
'lo, On 2 Sep 2011, at 06:54, Indragie Karunaratne wrote: > This has been asked a few times before, but not after Lion was released so I > figured I'd ask again. Is there any way to animate the scroll point of an > NSScrollView? I figure that animation must be possible somehow, considering > t

Re: Overwhelming Options

2011-09-02 Thread Jeremy Hughes
Quincey Morris (1/9/11, 21:42) said: >If it should happen that there was a practical need to change the column >display frequently (dozens of times per day), choosing individual >columns from a context menu would get very old very fast. In that case, >the only practical choice might be an array of

Re: Replacement for MethodReplacement?

2011-09-02 Thread Jean-Daniel Dupas
Le 2 sept. 2011 à 01:48, James Walker a écrit : > The sample code page > > describes it as > > "Objective C 2.0 compatible class_poseAs() replacement. This demonstrates how > to replace a method in