Chapter 25. The Defaults System
Native Mac OS X applications store their preferences in the
. This is made up of each
application’s property list
plist) file, which is an XML file consisting of
key/value pairs that define the preferences for an application or
service of the operating system.
If an application has a
every time you change its preferences, the changes are saved back to
plist file. Also included in the defaults
database system are the changes you make to your system via the
panels found in System Preferences
As an administrator, you may need to access your or another
user’s preferences. This is done from the Terminal
command. This chapter covers Mac OS
X’s preferences system, including the format and
location of application and system preference files, how they work,
and how to view and adjust their settings using the Property List
User-defined property lists
are stored in
~/Library/Preferences, and the appropriate
plist is called up when an application launches.
Property lists can contain literal preferences set through the
application’s ApplicationPreferences dialog, or
subtler things such as window coordinates or the state of an option
(such as whether to display the battery menu extra in the menu bar,
as shown in Example 25-1).
Example 25-1. The com.apple.menuextra.battery.plist file
<?xml version="1.0" encoding="UTF-8"?> ...