I don't understand what this does or how this works, but anyway it solved the problem:
Following up on the error message reported by theozh in the comments, I stumbeld on this bug report, https://sourceforge.net/p/gnuplot/bugs/2746/. Following the advice, I set the environment variable PANGOCAIRO_BACKEND to "fc" (and restarted gnuplot). Then the problem disappeared.
(On windows, I set the enviromnent variable via the Start menu, search for "environment", and it find a subentry of the control center where you set the environment variables (also PATH etc.). Here, you can add PANGOCAIRO_BACKEND witrh value fc.)