The Democrat who once composed music for Goku's battles has won Texas' attorney general election, ending more than three decades of Republican control.