Change the example over to autodetection of display type.