class_docstr: A Tkinter-compatible bitmap image.  This can be used everywhere Tkinter
  expects an image object.
  
  The given image must have mode "1".  Pixels having value 0 are treated as
  transparent.  Options, if any, are passed on to Tkinter.  The most commonly
  used option is ``foreground``, which is used to specify the color for the
  non-transparent parts.  See the Tkinter documentation for information on
  how to specify colours.
  
  :param image: A PIL image.
code: def __init__(self, image=None, **kw):
      # Tk compatibility: file or data
      if image is None:
          image = _get_image_from_kw(kw)
  
      self.__mode = image.mode
      self.__size = image.size
  
      if _pilbitmap_check():
          # fast way (requires the pilbitmap booster patch)
          image.load()
          kw["data"] = f"PIL:{image.im.id}"
          self.__im = image  # must keep a reference
      else:
          # slow but safe way
          kw["data"] = image.tobitmap()
      self.__photo = tkinter.BitmapImage(**kw)
  
imports: from __future__ import annotations
  import tkinter
  from io import BytesIO
  from .None import Image
label_desc: Use image node_id 1 to create a new BitmapImage object  with example: obj = BitmapImage(image)