The PlotCanvas is basically like Canvas, but we inherit some behaviors from PlotComponent as well. Some methods are redefined in here to explicitly make sure we get the right dispatch order.
draw(gc, view_bounds=None, mode='default')¶
Draws the plot component.
gc (Kiva GraphicsContext) – The graphics context to draw the component on
view_bounds (4-tuple of integers) – (x, y, width, height) of the area to draw
mode (string) –
The drawing mode to use; can be one of:
Normal, antialiased, high-quality rendering
The plot component is being rendered over something else, so it renders more quickly, and possibly omits rendering its background and certain tools
The plot component is being asked to render in direct response to realtime user interaction, and needs to make its best effort to render as fast as possible, even if there is an aesthetic cost.
Returns the size (width,height) that is preferred for this components.