Fix conversion of masks into a paint layer
We should also convert the default pixel and blending mode