Understanding the Canvas class