A source told the magazine the romance couldn't survive the long distance and the couple ended it this month.
Segel recently signed up for a ninth and final season of the TV sitcom "How I Met Your Mother," which will keep him in Los Angeles.
Williams lives with Matilda, her 7-year-old daughter, in Brooklyn. The little girl's father is the late actor Heath Ledger, who died in 2007 of an accidental drug overdose.
Rosie O'Donnell unveils nearly 50-pound weight loss
Justin Bieber crashes Drake Bell's album release party