Preferences API 编辑
Preferences API allows you to save and read strings, numbers, booleans, and references to files to the preferences store. It is relatively easy to use, while providing a number of useful user and developer features, including support for default preferences, user overrides via user.js, and locking.
You can also create a XUL-based options window easily to allow user modify some preferences. Many applications including Firefox and Thunderbird have an additional tool for power users, about:config, which can be used to tweak the preferences without UI.
Interfaces
The preferences API is exposed as a set of XPCOM components and interfaces: nsIPrefService
, nsIPrefBranch
.
...
See also
- Code snippets:Preferences (more detailed discussion with multiple examples)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论