In what century was Ophelia a popular subject for visual art?

The 19th century.