James Stewart of Traquair (d. 9 Mar 1607) m. Catherine Kerr (d. 28 Feb. 1606) [SP VIII:401] was half-3rd cousin -1 to Mary "Queen of Scots." Their common ancestor appears to be Robert III, King of Scotland.
James was the youngest son of William Stewart of Traquair and Christian Hay, William being the eldest son of James Stewart of Traquair and Christian Rutherford. This James, in turn, was an illegitimate son of Sir James Stewart, Earl of Buchan and Margaret Murray [SP VIII:399-401].
Hope this helps.