You could also try with UIBezierPath,
you need to override UIView Draw method.
Here is the example, so first you need to subclass UIView,
then open up Xcode if you want, add UIView on the canvas, resize
it as you like, go to the inspector, Custom Class, and choose
your custom class.