• 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: Nib XML format question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Nib XML format question


  • Subject: Re: Nib XML format question
  • From: Keith Wilson <email@hidden>
  • Date: Sun, 5 Mar 2006 13:14:06 +1100

Hi Julien.

An alternative is to use NibReporter - refer web page at http:// nibreporter.berlios.de/

Keith from DownUnder


On 05/03/2006, at 8:08 AM, Julien Silland wrote:

Hi everyone,

Since I'm-not-sure-when, Apple offers the developers the possibility of saving their nib files to a XML based text format (IB -> save as…, then open keyedobjects.nib in the nib's bundle). I have recently been looking into it and I was wondering if there is any advantage that can be taken of this format. Is it documented by Apple ? I couldn't find anything related to this at developer.apple.com... Second of all: it looks like Apple didn't took advantage of having an XML format. The main part of the file (which is a plist by the way) is an array that contains an unsorted set of all the objects used in the nib. Each bucket of the array can either be :

- a string that represents either a class name, a selector, a font name, a point/size/rect, a menu title, a plain string, etc...
- a dictionary per object that stores the connections and a lot of other informations, pointing to another bucket, and so on, until you end up to a string.


Basically, I think Apple stores the graph of objects and the connections between them, and does that by flattening the graph in a random order and storing the result in an array. The result is that instead of having a tree-like structure, one has to deal with a flat structure, moving back and forth between records that link to each others, which is a bit annoying when trying to read a very large file and then trying to automate the process.

Someone also told me that nibs stored in XML format take longer to load, although I couldn't verify this by myself.

I'm not asking for tips on how to read the file (although if anyone succeeded in doing that, it would be great to give me pointers), or if I even should be trying to read the file. The fact that the file is in XML should allow anyone to try poking around it. What I would like to know is if there is any advantage for developers to store theirs nibs as XML ? Why does XML export exist in the first place if it is this hard to make use of it ? _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40bigpond.net.au


This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: Nib XML format question
      • From: "Scotty's Lists" <email@hidden>
References: 
 >Nib XML format question (From: Julien Silland <email@hidden>)

  • Prev by Date: Re: unreliability of NSWorkspace selectFile
  • Next by Date: Re: how to debug notification that's never received?
  • Previous by thread: Re: Nib XML format question
  • Next by thread: Re: Nib XML format question
  • Index(es):
    • Date
    • Thread