setHorizontalAlignment(LEFT);
  public Component getListCellRendererComponent(JList list, Object value,                                                int index, boolean isSelected,                                                boolean cellHasFocus)  {    String s = value.toString();    setText(s);    setOpaque(true);    if (isSelected)      {        setBackground(list.getSelectionBackground());        setForeground(list.getSelectionForeground());      }    else      {        setBackground(list.getBackground());        setForeground(list.getForeground());      }    setEnabled(list.isEnabled());    setFont(list.getFont());    // Use focusCellHighlightBorder when renderer has focus and     // noFocusBorder otherwise        if (cellHasFocus)      setBorder(UIManager.getBorder("List.focusCellHighlightBorder"));    else      setBorder(noFocusBorder);    return this;  }