<s> from ginga . cvw import ImageViewCv <EOL> from ginga . canvas . mixins import DrawingMixin , CanvasMixin , CompoundMixin <EOL> class ImageViewCanvasError ( ImageViewCv . ImageViewCvError ) : <EOL> pass <EOL> class ImageViewCanvas ( ImageViewCv . ImageViewCv , <EOL> DrawingMixin , CanvasMixin , CompoundMixin ) : <EOL> def __init__ ( self , logger = None , rgbmap = None , settings = None , <EOL> bindmap = None , bindings = None ) : <EOL> ImageViewCv . ImageViewCv . __init__ ( self , logger = logger , <EOL> rgbmap = rgbmap , <EOL> settings = settings ) <EOL> CompoundMixin . __init__ ( self ) <EOL> CanvasMixin . __init__ ( self ) <EOL> DrawingMixin . __init__ ( self ) <EOL> self . set_canvas ( self , private_canvas = self ) <EOL> self . defer_redraw = False <EOL> def reschedule_redraw ( self , time_sec ) : <EOL> pass <EOL> def update_image ( self ) : <EOL> pass <EOL> def add_canvas ( self , tag = None ) : <EOL> DrawingCanvas = self . getDrawClass ( '<STR_LIT>' ) <EOL> canvas = DrawingCanvas ( ) <EOL> canvas . enable_draw ( True ) <EOL> canvas . ui_setActive ( True ) <EOL> canvas . setSurface ( self ) <EOL> self . add ( canvas , tag = tag ) <EOL> return canvas <EOL> def show ( self ) : <EOL> from IPython . display import Image <EOL> return Image ( data = bytes ( self . get_rgb_image_as_bytes ( format = '<STR_LIT>' ) ) , <EOL> format = '<STR_LIT>' , embed = True ) </s>
