generic draw method