A Gracious Tone. Your resignation letter is not the time to air grudges, take passive_aggressive shots, or otherwise be unpleasant. Regardless of how you feel about your (soon to be former) job or your boss, this letter should be an exercise in professionalism and graciousness. An excellent way to do that is to say a simple "thank you." Even if you hated your job, you got something from it at some point. Focus on that positive bit if you need to.
State Your Intent. The whole theme of your resignation letter is the statement that, well, you resign. You don't need to play coy__the time has passed for you to fish around for a counteroffer if it's gotten this far. At this point, you've made your decision to leave, and this letter needs to reflect that.