issue #1279 back on Mac, needs a few more tweaks to get it right.