Filling regions of an image in a seamless manner is an important task for editing digital images. We propose to address it by using an example- based image generation technique. Such techniques have recently proved very effective in the context of unconstrained texture synthesis. We show that they can also be surprisingly effective to fill large regions in images, even within complex mixes of textures and structures. We combine this approach with a block-based architecture within an interactive image editing tool, named PatchWorks. This tool performs faster and better than earlier pixel-based counterparts, and faster than most recent related techniques with similar capabilities. The ease of use and versatility of our system is illustrated on a number of real image editing tasks.