我应该在 Mac 首选项面板中包含哪些元素?
我对 Mac 程序的首选项窗口有疑问。我有一个带有基于 CoreData 后端的应用程序。我的程序包含一项功能,允许用户将数据库切换为不同的数据库。我不希望用户经常这样做——也许一年一两次。
现在,用户可以调整的许多选项都存储在数据库中。每次使用新数据库时都需要配置这些选项,因为它们特定于数据库本身。
尽可能确保用户很少需要重置 偏好设置。 理想情况下,偏好设置包括用户可能会进行的设置 只想改变一次。如果有用户可能想要的设置 每次他们打开您的应用程序或每次执行操作时都会发生变化 某些任务,不要将这些设置放在首选项中。相反,你 可以使用菜单项或面板中的控件为用户提供无模式 访问这些设置。
我的问题是:我的数据库级设置对于首选项窗口是否有效? “一年一次或两次”算“很少”吗?如果没有,创建第二个面板(其中许多窗格由 NSToolbar 控制)是否有任何缺点,该面板看起来就像首选项面板,但可以从不同的地方访问菜单项(例如“数据库首选项”)?
I have a question about my Mac program's preferences window. I have an application with a CoreData-based back end. My program includes a feature that allows users to switch out the database for a different one. I do not expect users to do this very often—perhaps once or twice a year.
Now, many of the options that users can tweak are stored in the database. These options need to be configured once every time that a new database is used, because they are specific to the database itself.
The Apple Human Interface Guidelines on Preferences state this:
As much as possible, ensure that users rarely need to reset
preferences. Ideally, preferences include settings that users might
want to change only once. If there are settings users might want to
change every time they open your app, or every time they perform a
certain task, don’t put these settings in preferences. Instead, you
could use a menu item or a control in a panel to gives user modeless
access to these settings.
My question is this: Are my database-level settings valid candidates for the preferences window? Does "once or twice a year" count as "rarely"? If not, are there any downsides to creating a second panel (with many panes that are controlled by an NSToolbar
) that looks just like a preferences panel but is accessed from a different menu item ("Database Preferences" for example)?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我总是在各种应用程序的“首选项”下看到数据库级设置(我想到了 1Password 和 MacJournal)。因此,首选项通常包含数据库级设置和 plist 文件中的“实际”首选项。前者(数据库级别设置)绝对重要,是实际数据。后者(plist 文件)并不那么重要,丢失这些数据不会造成太大的伤害,因为它只是用户可以轻松手动恢复的简单设置。
另一方面,我认为将两者分开并没有什么问题,特别是如果您的应用程序是多窗口(基于文档)应用程序,可以同时打开多个数据库。
但我确实认为最简单的方法是将其全部放入“首选项”中。这就是您可能应该做的,除非您有充分的理由不这样做。
直接回答您的一些问题:
— 是的,我认为是的。许多应用程序(例如 1Password 和 MacJournal)也这样做。
- 是的。
— 如果你有充分的理由将两者分开,我认为这没有什么问题。
只是我的两分钱。
I see database-level settings all the time under Preferences in various apps (1Password and MacJournal come to mind). Thus, Preferences often contains both database-level settings and "actual" preferences that go in a plist file. The former (the data-base level settings) is absolutely crucial, being the actual data. The latter (the plist file) isn't as important and losing this data shouldn't cause too much harm, as it's just simple settings the user can easily get back to manually.
On the other hand, I see nothing wrong with separating the two, especially if your app is a multi-window (document-based) app that can have many databases open at once.
But I do think it's simplest to just put it all into the Preferences. That's what you probably should do, unless you have a good reason to do otherwise.
To answer some of your questions directly:
— Yeah, I think they are. And many apps (such as 1Password and MacJournal) do this too.
— Yeah.
— If you have a good reason to separate the two, I see nothing wrong with it.
Just my two cents.