• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: 2 NSRuleEditor questions?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 2 NSRuleEditor questions?


  • Subject: Re: 2 NSRuleEditor questions?
  • From: "Jamie Phelps" <email@hidden>
  • Date: Wed, 27 Aug 2008 08:40:42 -0500

Hi, Laurent. I realize this is quite old, but I have been wrestling with
NSRuleEditor myself for a while. The main difference between NSTableView and
NSRuleEditor is that NSRuleEditor is more accurately understood as a tree or
network whereas NSTableView is a multi-dimensional array, [rows][columns].
As you change the selections in the NSRuleEditor it re-queries the delegate
for the display values for the children. When I diagramed the architecture
of my NSRuleEditor as a tree/network, it made a lot more sense. Start with
the root as nil.
Hope this helps.

On Thu, Jun 19, 2008 at 5:42 PM, Laurent Cerveau <email@hidden> wrote:

> Hi Peter
>
>
>> The formatting dictionary is used for localization.  You can see a sample
>> at http://homepage.mac.com/gershwin/NibBasedSpotlightSearcher.zip
>>
>
> Nice! Thanks for the pointer.
>
>
>> A nil formatting dictionary should be fine.  The delegate methods are
>> probably not being called because the rule editor has no rows in it.  Try
>> hooking up a button to its addRow: method.
>>
>
> This helps! However this brings me one question.  I donot get exactly  what
> is the exact purpose of "- (NSInteger)ruleEditor:(NSRuleEditor *)editor
> numberOfChildrenForCriterion:(id)criterion
> withRowType:(NSRuleEditorRowType)rowType" if rows needs to be added with
> addRow? I have more in mind on the NSTableView paradigm where data reloading
> is the "main trigger", and here obviously this is not the case. Where is my
> mistale in "comparing" with an NSTableView datasource?
>
> Thanks
>
> laurent
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
>
> This email sent to email@hidden<email@hidden>
>



--
::::::::::::::::::::::::::::::::::::::::::::::::::::::
Jamie Phelps
PO Box 12564
Fort Worth, TX 76110
(817) 673-0036
http://www.jamiephelps.com
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: How to create rounded view for iPhone App
  • Next by Date: Re: confused about allocating and releasing objects
  • Previous by thread: NSRuleEditor with Multiple Root Criteria Yields Empty Row
  • Next by thread: CoreData, SQLite and GUID
  • Index(es):
    • Date
    • Thread