The painter’s contemporaries saw him as a successor to Sargent, but his depictions of Black and queer subjects may stand out more today