Fixed paint algorithm order

Paint clipping was being applied before transformations; it is now
applied after