I have been looking for a way to make my own stationery since I heard Leopard would allow us to put stationery in Mail.app. I found a really good tutorial over at iuseapple.com He goes to really good depth on his tutorial. Take a look at the article here.
UPDATE: It looks like this article is no longer online. The link is dead and forwarding to a dead link.
I have added the text and comments from the Internet Archive Wayback Machine July 5th 2008 below.
October 29th, 2007 by steveblue
This post will outline everything someone will need who wants to start designing new Stationery for Mail in OS X Leopard. Hopefully, this will turn into an ongoing series about Stationery in Mail.
First Attempt at Skinning the Air Mail Stationery
What you will need to create new Stationery for Mail:
- OS X 10.5 Leopard
- XCode Installed
- Photoshop (or other Image Editor capable of editing .jpg and transparent .png)
- HTML / XML Editor
- Package Maker (installed w/ XCode)
Do not overwrite existing files. If you wish to the modify existing files, backup the originals before changing anything!
The default Stationery you see in Mail is stored in a folder at the following location:
If you navigate to this folder, you will notice a file called TableofContents.plist. This file contains the XML necessary for Mail.app to list the Categories of Mail Stationery.
Notice how each Category has it’s own Folder? By default there are Announcements, Birthday, Photos, Sentiments, and Stationery Folders. If you click on one of these folders, you will see it has it’s own directory structure: /Announcements/Contents/Resources. You will find the the actual stationery in the Resources folder for a specific Category.
There are two oddball files among the Stationery, another TableofContents.plist and an English.lproj Folder (I imagine for others running Leopard in other languages this folder may change, can someone confirm?). TableofContents.plist here is another XML document that lists the Category’s Stationery in a format Mail.app can understand. Does anyone know what the Stationery ID parameter in this file might be for? How can I create a new Stationary ID or a new piece of Stationery? The English.lproj folder contains a file called DisplayName.strings. In this file there is a comment that says: “Stationery category name as appears in the stationery selection pane in the New Message window after clicking Show Stationery toolbar item.”
If you go back to the Resources folder and Ctrl+Click on a .mailstationery file, you can select Show Package Contents from the menu. This will open the Stationery’s Directory Structure which is the same: /Stationary/Content/Resources/. Here you will find the files that make up a piece of Stationery in Mail.
There will most likely be the following basic files:
- bg_pattern.jpg : The Background Image
- top.jpg : Header Image
- bottom.jpg : Footer Image
- content.html : The HTML Template
- Description.plist : The XML File Necessary for Interactivity in Mail.app
- English.lproj folder : Contains DisplayName.strings (file that names the Stationery for Mail.app)
- thumbnail.png : The Thumbnail for the Selection Screen in Mail
Photo Stationery may have the following:
- Mask1.png : The Mask for Drop Zones
- placeholder1.jpg : The Placeholder Image for Drop Zones
- banner.jpg : Usually the Background for the Masked Drop Zones
- frames.png : The Template for the Drop Zones
Do not overwrite existing files. If you wish the modify existing files, backup the originals before changing anything!
- Create New Folder for “Custom” Stationery in the Resources folder, give it the Directory Structure /Content/Resources/
- In this folder, make a file called TableofContents.plist. You will need to enter XML data here for the Individual Stationery inside the “Custom” Category. Project Folders and eventually Packages will go in this folder. An English.lproj folder with DisplayName.strings (for the Category name) must be in this folder as well.
- Make a New Folder for the new Stationery and give it the same directory structure: /Content/Resources/
- This is the folder you will place the HTML template (content.html), XML template (Description.plist), all images, and the English.lproj folder with DisplayName.strings (Name of the individual Stationery)
- Use Package Maker to create a Package for the Stationery (must have .mailstationary as a filename and the correct Directory Structure)
- Backup TableofContents.plist in /System/Library/Application Support/Apple/Mail/Stationary/Apple/Contents/Resources/
- Add new lines in TableofContents.plist for the new Category
Can anyone tell me what that the Stationery ID is for in TableofContents.plist and how to create unique Stationery IDs for new Stationery and is this necessary?
If anyone ends up creating new Stationery because they read this tutorial, I would gladly post custom templates on iUseApple.com.
What did you learn in this post?