In the OnMouseMove() mf of a Win32 custom control which I am re-writing for Qt, there is some code that looks like this:

Qt Code:
  1. //----- Get the original erase area -----//
  2. getMarkerRgn(&oldrgn);
  4. //----- Draw the markers -----//
  5. :
  6. :
  7. getMarkerRgn(&newrgn);
  9. erasergn.CreateRectRgn(0,0,0,0); //Dummy rgn
  10. erasergn.CombineRgn(&oldrgn, &newrgn, RGN_DIFF);
  12. dc.FillRgn(&erasergn, &brush); // Background colour brush
To copy to clipboard, switch view to plain text mode 

The idea being to erase the previously drawn markers after the new ones are drawn

What should I be doing in Qt?

PS is there any Qt equivalent of the Windows OnEraseBackGround() ?
PPS only three weeks Qt experience so far so please be gentle!

Many thanks