James Buchanan? Not trans, apparently. But very possibly gay.
http://www.washingtonblade.com/2011/10/04/james-buchanan-america's-first-gay-president/James Buchanan: America's first gay president?By Timothy Cwiek
Washington Blade, October 4, 2011
"More than 150 years before America elected its first black president, Barack Obama, it most likely had its first gay president, James Buchanan (1791-1868). Buchanan, a Democrat from Lancaster County, Pa., was the 15th president of the United States, and a lifelong bachelor. He served as president from 1857-61, tumultuous years leading up to the Civil War.
. . .
"[Historian James W.] Loewen also said a letter Buchanan wrote to a friend after [his constant companion, Senator William Rufus]King went to France shows the depth of his feeling for King.
'I am now solitary and alone, having no companion in the house with me,' Buchanan wrote. 'I have gone a wooing to several gentlemen, but have not succeeded with any one of them. I feel that it is not good for man to be alone; and should not be astonished to find myself married to some old maid who can nurse me when I am sick provide good dinners for me when I am well, and not expect from me any very ardent or romantic affection.' "