Create distributable slideshow screen savers

Jan 26, '10 07:30:00AM

Contributed by: renaultssoftware

I like to create slideshow screen savers, and I do so using OS X's .slideSaver package format. The advantage of using this format is that you can redistribute your slideshow among friends or family -- that's why I tried my hand at it. Now, making a screen saver is a bit less easy in 10.6 because you have to add the LANG.lproj folders, but here's the rundown for creating these packages.

To make a slideshow screen saver, you do not need a separate application to compile. All you need will be right here. (You might want Property List Editor from the XCode developer tools to build the .plist files, but you can use TextEdit to do that.)

First, create a folder in any convenient place. Title it the name of the screen saver (Car Pictures, for example) and press Return.

To understand the package contents, you must have three files in that folder: an Info.plist file to identify it, a version.plist file to identify the version, and a folder called Resources to hold the pictures. Start by opening the screen saver's folder, and create the Resources folder.

Now, it's time to create (in TextEdit or Property List Editor) the Info.plist file to identify your screen saver. Edit capitalized entries except for BNDL under CFBundlePackageType. If you do not have Plist Editor, you can put the following in a blank TextEdit file:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>CFBundleDevelopmentRegion</key>
	<string>English</string>
	<key>CFBundleGetInfoString</key>
	<string>SOME CARS IN A CAR SHOW</string>
	<key>CFBundleIdentifier</key>
	<string>com.BIGAPPLEMACGEEK.screensaver.CARPICTURES
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundleName</key>
	<string>CARPICTURES</string>
	<key>CFBundlePackageType</key>
	<string>BNDL</string>
	<key>CFBundleShortVersionString</key>
	<string>1.1</string>
	<key>CFBundleSignature</key>
	<string>????</string>
	<key>CFBundleVersion</key>
	<string>1.1</string>
</dict>
</plist>
Under CFBundleGetInfoString, write a description (for example, the company picnic of 2009 or something). Make up something unique for the capital bits of CFBundleIdentifier, and give your project a name under the CFBundleName key. Save this at the top level of the screen saver folder you created.

Next, create a version.plist file in the screen saver folder. This one has the following contents:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>BuildVersion</key>
	<string>400</string>
	<key>CFBundleShortVersionString</key>
	<string>1.1</string>
	<key>CFBundleVersion</key>
	<string>1.1</string>
	<key>ProjectName</key>
	<string>SlideShows</string>
	<key>SourceVersion</key>
	<string>90000</string>
</dict>
</plist>
Now navigate into the Resources folder in the screen saver's folder; your pictures go here. In the Info.plist file above, note the CFBundleName name you used (CARPICTURES in the example) and:
  1. Drag the pictures you want to use into the Resources folder; it seems to work best with JPG files.
  2. Rename each file with the CFBundleName name and a number (01, 02, 03, etc.) suffixed to determine order. In the example above, that would be CARPICTURES01.jpg, CARPICTURES02.jpg, etc. It is recommended that you use 001 when over a hundred pictures are to be used.
  3. Create a folder named English.lproj in Resources. Inside that folder, create an InfoPlist.strings file (it can be blank, if you like; info keys can be added and localized to French.lproj, Spanish.lproj, etc.)
Now, append .slideSaver to the screen saver folder you created. If a confirmation box appears, click Add to confirm. Your folder should now look like a document with a blue, swirling icon in the top half and a SAVER banner on the bottom. You can double-click it, put it in either the top-level or user-level Library » Screen Savers folder, and/or distribute it.

It's better to test it first for bugs before distributing. Make sure that clicking Options in System Preferences (below the preview) displays a sheet with standard options.

[robg adds: I haven't tested this one.]

Comments (11)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20100120180846475