Flashing black graphics

When I access my headless Linux machine from my Windows PC, I get flashes of blacked out graphics when I move my cursor over certain objects on the GUI.

The graphics problem does not show up when I attach a monitor to the headless machine.

I have tried messing around with all of the settings but I can't seem to get it to work correctly.