code: def show(self, fmt=None):
          
          # force any delayed redraws
          # TODO: this really needs to be addressed in get_rgb_image_as_bytes()
          # of the various superclasses, as it affects other backends as well
          self.redraw_now()
  
          from IPython.display import Image
  
          if fmt is None:
              # what format are we using for the Jupyter image--use that
              fmt = self.jp_img.format
  
          return Image(data=bytes(self.get_rgb_image_as_bytes(format=fmt)),
                       format=fmt, embed=True)
docs: Capture the window of a viewer.