Called (by a buffer) to draw the snip.
Before this method is called, the correct font, text color, and pen colour will have been set in the drawing context for this snip already. (This is not true for get-extent or partial-offset.) The draw method must not make any other assumptions about the state of the drawing context, except that the clipping region is already set to something approrpiate. Before draw returns, it must restore any drawing context settings that it changes.
See also on-paint in wx:media-buffer%.
The snip's buffer is usually internally locked for writing and reflowing when this method is called (see also Locks).
Draws the snip into the given drawing context with the snip's top left corner at location (x, y) (in DC coordinates).
The arguments left, top, right, and bottom define a clipping region (in DC coordinates) that the snip can use to optimize drawing, but it can also ignore these arguments.
The dx and dy argument provide numbers that can be subtracted from x and y to obtain the snip's position in buffer view coordinates (as opposed to DC coordinates).
See Caret for information about draw-caret.