javax.swing.SwingUtilities.paintComponent(g, label, null, label.getBounds());
SwingUtilities.paintComponent(g, label, null, label.getBounds());
  protected void paintVerticalLabel(Graphics g, int value, Component label)  {    Dimension dim = label.getPreferredSize();    int w = (int) dim.getWidth();    int h = (int) dim.getHeight();    int max = slider.getMaximum();    int min = slider.getMinimum();    if (value > max || value < min)      return;    int xpos = labelRect.x;    int ypos = yPositionForValue(value) - h / 2;    if (ypos < 0)      ypos = 0;    if (ypos + h > labelRect.y + labelRect.height)      h = labelRect.y + labelRect.height - ypos;    if (w > labelRect.width)      w = labelRect.width;    label.setBounds(xpos, ypos, w, h);    javax.swing.SwingUtilities.paintComponent(g, label, null, label.getBounds());  }