• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: best way to save document level settings?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: best way to save document level settings?


  • Subject: Re: best way to save document level settings?
  • From: Scott Anguish <email@hidden>
  • Date: Sun, 7 Dec 2003 00:59:59 -0500

On Dec 6, 2003, at 3:21 PM, M. Uli Kusterer wrote:

At 3:17 Uhr -0500 06.12.2003, Scott Anguish wrote:
this is a bad idea. It depends on the application wrapper being writable.

I think he meant the com.mycompany.myapplication.plist in ~/Library/Preferences/, not the Info.plist.

you could save it to the defaults on a per-document basis

This is one moment where I think you should be using resources. You could use Nathan Day's NDResourceFork wrapper class. Simply archive the dictionary containing column info and all that into an NSData, and then write that NSData to a resource in the document's resource fork using NDResourceFork.

This has the advantage that your file format doesn't change and you get to keep the data with each document. And if the resource fork is lost during transfer, it's not really that bad after all.


it also has issues though with the "other application" that he spoke of. If that app isn't modified (and if you're going to, you might as well modify the format to support it directly) and it writes the file back out.. boom, no gain.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
  • Follow-Ups:
    • Re: best way to save document level settings?
      • From: "M. Uli Kusterer" <email@hidden>
References: 
 >best way to save document level settings? (From: Donald Hall <email@hidden>)
 >Re: best way to save document level settings? (From: Scott Anguish <email@hidden>)
 >Re: best way to save document level settings? (From: "M. Uli Kusterer" <email@hidden>)

  • Prev by Date: tableviews
  • Next by Date: Re: NSComboBoxCell in NSTableView
  • Previous by thread: Re: best way to save document level settings?
  • Next by thread: Re: best way to save document level settings?
  • Index(es):
    • Date
    • Thread