Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iPhone - Creating custom objects for Interface Builder?

I am currently subclassing UIView to create custom objects, they work perfectly fine

In interface builder i drag and drop a uiview and I set the class name to my custom view, and in runtime the view will populate according to my code.

QUESTION: Is it possible to make it so that my custom view DRAWS in interface builder, And maybe drag and drop my custom view ?

like image 925
aryaxt Avatar asked Dec 10 '10 16:12

aryaxt


2 Answers

I've researched this myself a while back, as far as i know this is not possible using the iPhone SDK. When developing for the Mac SDK you can create your own IB plugins.

like image 139
aegzorz Avatar answered Oct 14 '22 18:10

aegzorz


You need to add the custom view to the Interface Builder library. Go to File -> Read Class Files... in interface builder, and select your header file to add your item to interface builder's list.

like image 24
Dan Monego Avatar answered Oct 14 '22 19:10

Dan Monego