If You Want to Do More Than Just the Basics with Your Resignation Letter. You can always write more, and craft a longer resignation letter, but the truth is that it isn't necessary. You can add a portion of the note where you thank your manager or boss for the opportunities and time you have had together, or add that you hope to keep in touch, but in reality, if you really feel this way you probably should make an effort and find an opportunity to say these things in person (rather than getting an email).
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.