Seeking documentation – AppleScript applets containing Open/Save dialogs auto-create preferences

I've just found that AppleScript applets which generate Open or Save dialogs (e.g. via NSPathControl's NSPathStylePopUp) automatically create a preference file in the user's home preferences folder. The file has the same name as the applet's ID (e.g. com.apple.script.id.myapplet.plist).

The file might contain value-key pairs for NSNavLastRootDirectory, NSNavPanelExpandedSizeForOpenMode, NSWindow Frame NSNavPanelAutosaveName etc.

I have Googled and search but have not been able to find documentation on this. Is there any documentation which explains this behaviour and provides advice on how to use it ?

Thanks.

Such preferences are typically managed by NSUserDefaults, so the location and format of these files is not considered API. Moreover, many of the preferences contained within these files are managed by system frameworks, and those are not considered API either.

What is your goal here? The open and save panels do expose a lot of APIs to control how they’re presented — for example, you can tell the panels to open at a specific directory — so, if you can explain more about your goal, it’s possible that there’s an API that will help with that.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

I'm trying to understand more about that preferences file.

OK, I’m going to quote myself here:

the location and format of these files is not considered API. Moreover, many of the preferences contained within these files are managed by system frameworks, and those are not considered API either.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Seeking documentation – AppleScript applets containing Open/Save dialogs auto-create preferences
 
 
Q