code: func (im *Image) XSurfaceSet(wid xproto.Window) error {
  	if im.Subimg {
  		return fmt.Errorf("XSurfaceSet cannot be called on sub-images." +
  			"Please set the surface using the original parent image.")
  	}
  	if im.Pixmap == 0 {
  		if err := im.CreatePixmap(); err != nil {
  			return err
  		}
  	}
  
  	// Tell the surface (window) to use this pixmap.
  	xproto.ChangeWindowAttributes(im.X.Conn(), wid,
  		xproto.CwBackPixmap, []uint32{uint32(im.Pixmap)})
  	return nil
  }
docs: /*
  xgraphics/xsurface.go contains methods for the Image type that perform X
  related requests. Namely, methods that send image data start with 'X'.
  */
  // XSurfaceSet will set the given window's background to this image's pixmap.
  // Note that an image can have multiple surfaces, which is why the window
  // id still needs to be passed to XPaint. A call to XSurfaceSet simply tells
  // X that the window specified should use the pixmap in Image as its
  // background image.
  // Note that XSurfaceSet cannot be called on a sub-image. (An error will be
  // returned if you do.)
  // XSurfaceSet will also allocate an X pixmap if one hasn't been created for
  // this image yet.
  // (Generating a pixmap id can cause an error, so this call could return
  // an error.)