All Known Subinterfaces:
FrameworkIcons
All Known Implementing Classes:
DefaultFrameworkIcons

public interface Icons
Provides icons for ui components. The icon color follows the 'Button.foreground' color of the current Look and feel. Add icons via add(Ikon...) and retrieve them via get(Ikon).
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
    static final PropertyValue<Integer>
    The icon size, note that this will affect the size of buttons Value type: Integer Default value: 16
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(org.kordamp.ikonli.Ikon... ikons)
    Adds the given ikons to this FrameworkIcons instance.
    get(org.kordamp.ikonli.Ikon ikon)
    Retrieves the ImageIcon associated with the given ikon from this FrameworkIcons instance.
    static Icons
     
  • Field Details

    • DEFAULT_ICON_SIZE

      static final int DEFAULT_ICON_SIZE
      See Also:
    • ICON_SIZE

      static final PropertyValue<Integer> ICON_SIZE
      The icon size, note that this will affect the size of buttons
      • Value type: Integer
      • Default value: 16
  • Method Details

    • add

      void add(org.kordamp.ikonli.Ikon... ikons)
      Adds the given ikons to this FrameworkIcons instance. Retrieve an icon via get(Ikon).
      Parameters:
      ikons - the ikons to add
      Throws:
      IllegalArgumentException - in case an icon has already been associated with any of the given ikons
    • get

      ImageIcon get(org.kordamp.ikonli.Ikon ikon)
      Retrieves the ImageIcon associated with the given ikon from this FrameworkIcons instance.
      Parameters:
      ikon - the ikon
      Returns:
      the ImageIcon associated with the given ikon
      Throws:
      IllegalArgumentException - in case no icon has been associated with the given ikon
      See Also:
    • icons

      static Icons icons()
      Returns:
      a new Icons instance