Search code examples
objective-ccocoadraweraserect

Is it possible to erase drawing made by NSRectFill?


I have been using NSRectFill to draw rectangles on the screen. I would like to erase these rectangles. I can't paint over them, as the back ground behind them is textured and can't be replicated with a solid color. Is this possible?


Solution

  • I don't know much Objective-C, or Cocoa, so I can't give you details, but here's how my Windows oriented mind thinks:

    Simply request a redrawing of the window, and then don't paint the rectangles.