Implement custom paint