“压平编译的 xib 文件”是什么意思?项目构建选项“do”
“将 XIB 文件编译为扁平化文件 (非包装)NIB 文件。后 扁平化,产生的NIB更 紧凑但不再可编辑 界面生成器。当这个选项 被禁用,生成的 NIB 文件 在界面中保持可编辑 建设者。”
这是该选项的描述,似乎是我能找到的唯一官方参考。事实上,我也找不到太多非官方的信息——我唯一一次看到人们谈论这个设置是在关于本地化的难度,
解释一下,我会减轻一些负担。
我不知道“扁平化(非包装)”是什么意思。如果有人能 这对我的代码有确切的影响,这里的短期目标是试图弄清楚这是否“弥补”了容器视图,其唯一目的是在界面生成器中移动分组数据,然后执行这些视图。扁平化”应用到它上,仍然会导致设备加载时的运行时延迟。一个下午的仪器就在我面前,但我过去做这样的测试时得到了一些好坏参半的结果,
感谢您的任何见解。
"Compiles a XIB file into flattened
(non-wrapper) NIB file. After
flattening, the resulting NIB is more
compact but no longer editable by
Interface Builder. When this option
is disabled, the resulting NIB file
remains editable in Interface
Builder."
This is the description of the option, and seems to be the only official reference that I can find. And in fact, I can't find much unofficial either -- the only times I see people talking about this setting is in regards to the difficulty of localization.
I don't know what "flattened (non-wrapper)" means. If anyone can shed some light on this, it'd take a load off my mind.
While I'd like to know the exact effect this has on my code, the short-term goal here is trying to figure out if this 'makes up' for container views. Views whose sole purpose is shifting grouped data around in interface builder. Do those views, after having this 'flattening' applied to it, still cause delays at run time on the device in loading. An afternoon with instruments is ahead of me, but I've had some mixed results doing tests like this in the past.
Thanks for any insight.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在构建过程中,界面构建器文件默认被压缩/扁平化。这样做的优点主要是减少了最终尺寸,也许加载速度也稍快一些。
在 iOS 3.2 之前,XIB 文件始终是扁平化的。直到 3.2 之后,这才作为一个选项公开,可能是为了适应某些开发人员的工作流程。
来自 iOS 3.2 发行说明:
Interface builder files are compacted/flattened by default during the build process. The advantage of this is mainly a reduced final size, perhaps slightly faster loading as well.
Before iOS 3.2, XIB files were always flattened. Only after 3.2 was this exposed as an option, probably to fit the workflow of some developers.
From the iOS 3.2 release notes: