Class ComboBoxListCellRenderer<T>

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JLabel
javax.swing.DefaultListCellRenderer
com.inductiveautomation.plaf.ComboListCellRenderer
com.inductiveautomation.ignition.designer.gui.cellrenderer.ComboBoxListCellRenderer<T>
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, ListCellRenderer<Object>, SwingConstants

public class ComboBoxListCellRenderer<T> extends com.inductiveautomation.plaf.ComboListCellRenderer
If a JComboBox contains combo items that need to be rendered to a specific String. This class can help facilitate that task.
See Also:
  • Constructor Details

    • ComboBoxListCellRenderer

      public ComboBoxListCellRenderer(Class<T> clazz, Function<T,String> converter)
  • Method Details

    • getListCellRendererComponent

      public Component getListCellRendererComponent(JList<?> list, Object value, int index, boolean isSelected, boolean cellHasFocus)
      Specified by:
      getListCellRendererComponent in interface ListCellRenderer<T>
      Overrides:
      getListCellRendererComponent in class com.inductiveautomation.plaf.ComboListCellRenderer