title: Custom binned colorbar: can't set tick labels
body: <p>I'am trying to create my own binned colorbar, but I can't set my own tick labels, that remain fixed.</p>
  <pre><code>plt.figure(figsize = (10, 1))
  
  cmapor = plt.get_cmap('jet')
  cmap = mcolors.ListedColormap([ i for i in cmapor(np.linspace(0, 1, 5))])
  bounds = np.linspace(0, 1, 6)[:-1]
  labels = ['0', '2.5', '5', '7.5', '10']
  cb2 = mcolorbar.ColorbarBase(plt.gca(), cmap = cmap, orientation = 'horizontal', spacing='proportional', extendfrac='auto')
  cb2.ax.set_xticks = bounds
  cb2.ax.set_xticklabels = labels
  
  plt.tight_layout()
  plt.show()
  </code></pre>
  <p>gives <a href="https://i.stack.imgur.com/YHyzH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YHyzH.png" alt="enter image description here" /></a></p>
  <p>I would like to have no tick label on the last one, and the other ones labeled as mentioned in <code>labels</code>.</p>
  <p>Note also that the ticks for 0.2 and 0.4 are not perfectly centered on the separation between the colors .. ?</p>