docs: def set_monitor_callback(cbfun):
      """
      Sets the monitor configuration callback.
  
      Wrapper for:
          GLFWmonitorfun glfwSetMonitorCallback(GLFWmonitorfun cbfun);
      """
      global _monitor_callback
      previous_callback = _monitor_callback
      if cbfun is None:
          cbfun = 0
      c_cbfun = _GLFWmonitorfun(cbfun)
      _monitor_callback = (cbfun, c_cbfun)
      cbfun = c_cbfun
      _glfw.glfwSetMonitorCallback(cbfun)
      if previous_callback is not None and previous_callback[0] != 0:
          return previous_callback[0]