苹果如何使info.plist显示其“信息属性列表”? [英] How does Apple make the info.plist display its "Information Property List"?

查看:779
本文介绍了苹果如何使info.plist显示其“信息属性列表”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的plists只是从根开始。他们的包含有用的东西的数组,你可以选择来调整配置。
我正在查找的具体info.plist是在一个iphone项目。
我已经研究了这一点,(不是很多),但是没有检测到解决方案的气味。

My plists simply start with "Root". Theirs contains arrays of useful stuff you can select to tweak the configuration. The specific info.plist I am looking at is in an iphone project. I have researched this a little bit, (not alot) but haven't even detected a smell of solution.

有什么机制把这一起?我可以将它弯曲到我的意志吗?

What mechanism is putting this together? Can I bend it to my will?

为了澄清,我不是指简单地编辑plist,而是使用属性列表编辑器定义下拉列表中

To clarify, I am not referring to simply editing the plist, but using the Property List Editor to define the drop down lists in the left hand column, like Apple's info.list behaves.

通常我的plists会在编辑器中显示3列。键,类型和值。
Info.plist有2,它是如何设置的,它的行为是不同的属性列表编辑器?

Normally my plists will display in the editor with 3 columns. Key, Type and Value. Info.plist has 2, how is it setup so its behaviour is different in the Property List Editor?

这个链接在苹果定义正在使用的键Info.plist。

This link at apple defines the keys being used in the Info.plist.

属性列表键参考

推荐答案

列表编辑器由Apple称为属性列表结构定义提供。这是一个基于XML的文件,它为特定类型的属性列表定义特定的键和值。属性列表编辑器使用此属性将人类可读名称与特定属性列表键,以及合理的默认值,类型信息等相关联。

The names you see in the drop down menus in Property List Editor are provided by what Apple calls a "property list structure definition". This is an XML based file that defines specific keys and values for a particular type of property list. Property List Editor uses this to associate human readable names with particular property list keys, as well as sensible default values, type information, and so on.

属性列表编辑器在使用定义时隐藏类型列,因为它从结构定义自动获取类型信息。如果需要,您仍然可以使用编辑>值类型手动更改类型。您还可以手动更改属性列表编辑器通过视图>属性列表类型使用的定义。

Property List Editor hides the "Type" column when using a definition, because it gets the type information automatically from the structure definition. You can still use Edit > Value Type to change the type manually if you wish. You can also manually change the definition Property List Editor is using via View > Property List Type.

Xcode包含一个内置的Info.plist文件定义,这就是为什么您在打开Info.plist文件时自动查看自定义。如果您对结构定义的定义感兴趣,可以在/Developer/Platform/MacOSX.platform/Developer/Library/Xcode/Plug-ins中查看内置定义。我不相信有这种格式的官方文件,但它不是太难找到看例子。

Xcode includes a built-in definition for Info.plist files, which is why you see the customization automatically when opening up an Info.plist file. If you're interested in how the structure definitions are defined, you can take a look in /Developer/Platform/MacOSX.platform/Developer/Library/Xcode/Plug-ins for the built-in definitions. I don't believe there's any official documentation for this format, but it's not too hard to pick up looking at the examples.

这篇关于苹果如何使info.plist显示其“信息属性列表”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆