Reputation: 348
I'm building a web application with the Cappuccino framework, and I'm using the new Xcode integration through the XcodeCapp-Cocoa listener. When I place an NSPredicateEditor into a nib file (like MainWindow.xib), and allow it to be converted into a cib (for Cappuccino), the predicate editor is empty, and all that remains is a border and background colour where the CPScrollView is. I have tried modifying the predicate row templates, but have had no luck... Any suggestions?
Upvotes: 0
Views: 183
Reputation: 5066
As stated in my comments on @Luke Fletcher's reply to the question, my first attempt to add [aPredicateEditor setObjectValue: aPredicate]
to the code didn't work.
Here's why:
I was calling it from within my initWithCib:bundle:
method. It seems the settings you change on your CPPredicateEditor
in this function are overwritten by the settings in your cib as entered in IB. To get around this, I moved the code to awakeFromCib
and it worked fine.
However if you use bindings, the CPPredicate
object you reference in the binding will automatically be updated by the CPPredicateEditor
when making changes, while I had the problem this wasn't the case when using the setObjectValue:
method. To retrieve my changes there, I had to collect the objectValue
of the CPPredicateEditor
object.
Upvotes: 1
Reputation: 348
I discovered the answer. You actually need to give the CPPredicateEditor a predicate before it will show anything at all.
Upvotes: 1
Reputation: 1758
I suggest posting the question to our mailing list. The guy who wrote that particular component frequents there, but I dont think monitors SO.
Alternatively you could do it all in code.
Upvotes: 0