code: func GetFormat(X *xgbutil.XUtil, depth byte) *xproto.Format {
  	for _, pixForm := range X.Setup().PixmapFormats {
  		if pixForm.Depth == depth {
  			return &pixForm
  		}
  	}
  	return nil
  }
docs: // GetFormat searches SetupInfo for a Format matching the depth provided.