OGeek|极客世界-中国程序员成长平台

标题: ios - XCode4 界面生成器 : How to set name of an object? [打印本页]

作者: 菜鸟教程小白    时间: 2022-12-11 20:35
标题: ios - XCode4 界面生成器 : How to set name of an object?

这一定是一个非常愚蠢的问题。 我想用 UINibExternalObjects 加载一个 nib,但在此之前我必须更改 nib 中对象的名称。

Each placeholder object you add to a nib file must have a unique name. To assign a name to an object, select the object in Xcode and open the inspector window. The Attributes pane of the inspector contains a Name field, which you use to specify the name for your placeholder object. The name you assign should be descriptive of the object’s behavior or type, but really it can be anything you want.

很遗憾,我在任何检查员中都找不到此选项。有谁知道它在哪里?



Best Answer-推荐答案


这仅适用于您作为占位符添加到 nib 文件的“外部对象”。 (请注意,这些与“对象”不同:

enter image description here

如果您选择外部对象,那么在属性检查器中有一个“标识符”字段:

enter image description here

这是文档中提到的内容。它可能已从“名称”重命名并且文档已过时,或者它从来都不是正确的。

关于ios - XCode4 界面生成器 : How to set name of an object?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8281226/






欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://ogeek.cn/) Powered by Discuz! X3.4