How to make inspector panels for custom Quartz Composer patches

…in thirteen easy steps or your money back.
This release is only compatible with Tiger (10.4).
Please see for Leopard-specific informations.




  1. Start up Interface Builder:
  2. Make a new NIB, with a “Cocoa / Empty” starting point:
  3. Make a subclass of NSObject called QCInspector. Then make a subclass of QCInspector with the class name of your patch, followed by “UI”. P5GloveUI in this case:
  4. Drag a “CustomView” into the project:
  5. Select “File’s Owner” and set its “Custom Class” to the UI subclass you created above (P5GloveUI in this case):
  6. Control-drag from “File’s Owner” to “View”, then “Connect” the view to the UI subclass’s “view” outlet:
  7. Throw a few controls onto the View if you’d like:
  8. Save the NIB in your patch’s English.lproj folder, and add it to the project:
  9. Add the QCInspector interface to your patch’s qcplugin.h:
    @interface QCInspector : NSObject
    	NSView *view;
    	QCPatch *_patch;
    	void *_unused2[4];
    + (id)viewNibName;
    + (id)viewTitle;
    - (id)init;
    - (void)didLoadNib;
    - (id)patch;
    - (void)setupViewForPatch:(id)fp8;
    - (void)resetView;
    - (id)view;
  10. Add inspectorClassWithIdentifier to your patch’s interface:


    @interface P5Glove : QCPatch
    + (Class)inspectorClassWithIdentifier:(id)fp8;
  11. Implement inspectorClassWithIdentifier:


    @implementation P5Glove : QCPatch
    + (Class)inspectorClassWithIdentifier:(id)fp8
    	return [P5GloveUI class];
  12. Add the P5GloveUI class interface and implementation to your patch’s project:


    @interface P5GloveUI : QCInspector
    + (id)viewNibName;	// IMP=0x97b89415


    @implementation P5GloveUI : QCInspector
    + (id)viewNibName
    	return @"P5GloveUI";
  13. Build and launch Quartz Composer. You’ve got an inspector:
  14. Enjoy.

Steve Mokris is a developer at Kosada, Inc.



This was a great tutorial… a couple of small details that probably wouldn’t take anybody to long to figure out but are worth mentioning (unless I’m wrong about them).

  1. I believe you need to link to the UI header file from within your patches .h file, since the inspectorClassWithIdentifier method returns the UI class.

  2. You need to link to the qcplugin.h file inside your UI Header file, so that the UI class knows what a QCInspector is.

Thanks again for this tutorial, and for your excellent template.