Created from a submitted patch to 2.10. Needs backport to 2.10.
Not tested on Windows yet (until CI builds it for me.)
Someone who knows Gtk might be able to excise the magic number.
I won't merge it until someone reviews it, as some controversy was in comments on #540