+ int w = st->xgwa.width;
+ int h = st->xgwa.height;
+
+ /* Analysing a full-resolution image on a Retina display is too slow,
+ so scale down the source at image-load time. */
+ if (st->max_resolution > 10)
+ {
+ if (w > h && w > st->max_resolution)
+ h = st->max_resolution * h / w, w = st->max_resolution;
+ else if (h > st->max_resolution)
+ w = st->max_resolution * w / h, h = st->max_resolution;
+ }
+ /* fprintf(stderr,"%s: loading %d x %d\n", progname, w, h); */
+