Re: Rec: fiction where main chracter is a ruler
Any of the Tom Clancy novels after Jack Ryan becomes president. Several of Clive Cussler's books feature heads of state prominently, with Night Probe immediately coming to mind. Hesse's Siddhartha. Edgcomb Pinchon's Zapata the Unconquerable.
For TV/movie series, Battlestar Galactica, naturally (albeit with three presidents over the course of the series), or The West Wing.
Deposed heads of state appear as major characters in Nabokov's Pale Fire (at least in the footnotes, where most of the story unfolds), and Tom Robbins' Still Life With Woodpecker.