How to create an Interface Builder plugin in XCode5+?

心不动则不痛 提交于 2019-12-03 13:07:45

问题


I need make an Object Library, an Interface Builder plugin like Mapkit so that user can drag my Custom Object and add to UIView.

As property, i want to show and configure it with my basic properties.

Any idea how to do this?

thanks.


回答1:


In Xcode 4.0, Apple has removed support for using custom Interface Builder palettes provided by IBPlugins in the Interface Builder editor. Xibs/Nibs that use such plugins will still compile but they cannot be edited. You'll need to install Xcode 3 (in a separate folder so as not to overwrite 4) and use it to edit xibs with custom palettes.

This is all in Xcode 4's release notes. Stay tuned to prerelease release notes for more updates on this matter.

Update for Xcode 6

Plugins are no longer necessary. See @IBDesignable and @IBInspectable. :-)




回答2:


You need to create an Interface Builder plugin for that; the static library has nothing Interface Builder knows how to work with.



来源:https://stackoverflow.com/questions/6568817/how-to-create-an-interface-builder-plugin-in-xcode5

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!