Fixed bug where a pen which was on can be turned off.