add method and pen property.

The method can change the pen type, and default is smooth.