Katy Perry says she had a "long courtship" with now-boyfriend John Mayer "writing letters to each other" before they publicly started dating in summer 2012. Credit: Astrid Stawiarz/Getty Images

So romantic! Katy Perry and John Mayer didn't rush into their relationship when they began dating in summer 2012. The 29-year-old singer tells the Nov. 8 issue of Entertainment Weekly that she and Mayer exchanged love letters for a long time before going public.

Perry tells the magazine that her secret pen pal relationship with the 36-year-old singer was the inspiration for her "Legendary Lovers" track on new album, Prism. "I actually wrote it in an email one time, and after I wrote it I looked -- we had a long courtship before anything was [public], just writing letters to each other -- and seeing 'legendary lovers,' it sounded so nice," she reveals. "Some things float into my mind, and I process them, and [then] I make songs about them."

"I never knew I could see something so clearly looking through my third eye," Perry sings in the song. "Never knew karma could be so rewarding and bring me to your life/ Maybe this is the beginning of something so magical tonight."

Perry's relationship with Mayer began shortly after she finalized her divorce from Russell Brand in February 2012. (The "Part of Me" singer and The British actor filed for divorce from Perry in December 2011 after 14 months of marriage.) Mayer's famous ex-girlfriends include Taylor Swift, Jennifer Aniston and Jessica Simpson.

A source recently told Us Weekly that Perry and Mayer are getting serious in their relationship. They've been dating for 15 months now (with a three-month break earlier this year) and are heading towards an engagement. "Everyone knows it's just a question of when John will propose," the insider told Us.

How are they making their romance last? The couple is still sending love notes to each other. The source told Us that Perry and Mayer "realize they must be together" and they "Skype and text all day."