Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating a Composition in Code




On 02.02.2007, at 09:57, Oliver Breidenbach wrote:

One more tidbit of information: You can turn the files into ASCII XML using command line tool "plutil -convert xml1 [filename]" and edit them in a text editor. QC will also open the ASCII XML files but when you save them, it will turn them back into binary.

Yesterday I had to mass-generate some rather basic compositions with a customized string and they were actually per default in ASCII plist format.


Anyway, for both formats it should be sufficient to deserialize them using

NSString *error;
NSPropertyListFormat format;
NSData *compositionData = [NSData dataWithContentsOfFile:[path stringByAppendingPathComponent:filename]];
id composition = [NSPropertyListSerialization propertyListFromData:compositionData
mutabilityOption:NSPropertyListMutableContainersAndLeaves
format:&format
errorDescription:&error];


or the corresponding Carbon APIs...

Regards,
	Tom_E

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/email@hidden

This email sent to email@hidden
References: 
 >Re: Creating a Composition in Code (From: Joshua Ballanco <email@hidden>)
 >Re: Creating a Composition in Code (From: Oliver Breidenbach <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.