We're hiring!

We're actively seeking developers & designers for our new Detroit location. Learn more

Visualizing XIB/NIB Files

I have been using Interface Builder to instantiate and establish connections between all of the objects in an iPhone application Atomic has been working on. At the end of the project I wanted to visualize the entire application structure and the relationships between all of the objects. Alas, there were no obvious tools or applications that I could find to do this.

As a result I created a ruby script that parses an interface builder file, builds a dot graph structure, and writes it out as an image. The script can be freely downloaded here. There are a few external dependencies that will need to be installed for it to be fully functional.

  • Port install graphiz (port install graphviz).
  • Gem install the Ruby Graphing Library (gem install rgl).
  • Ruby Cocoa must also be installed, which should be available for everyone who has MacOS X Leapord.

Graphviz is only required for writing out the image. The script also writes out a dot graph file which can be opened by Omnigraffle.

Below are two graph images from two different iPhone projects:

Large Project

Small Project

This entry was posted in Tools. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">