Class DefaultUIAwareIcon

    • Field Detail

      • light

        protected Icon light
      • dark

        protected Icon dark
    • Constructor Detail

      • DefaultUIAwareIcon

        public DefaultUIAwareIcon()
    • Method Detail

      • createDual

        protected abstract UIAwareIcon createDual()
      • getDual

        public UIAwareIcon getDual()
        Description copied from interface: UIAwareIcon
        Return the dual version of the icon. i.e. if the current icon is light then the dual version will be dark and vice versa. Implementations of this method should respect that the appearance of the icon after invoking this method twice should be the same.
        Specified by:
        getDual in interface UIAwareIcon
        Returns:
        the dual icon.
      • loadLightIcon

        protected abstract Icon loadLightIcon()
        Load the light version of the icon. This method should never return a null value.
        Returns:
        the light icon.
      • loadDarkIcon

        protected abstract Icon loadDarkIcon()
        Load the dark version of the icon. This method should never return a null value.
        Returns:
        the dark icon.
      • getIconWidth

        public int getIconWidth()
        Specified by:
        getIconWidth in interface Icon
      • getIconHeight

        public int getIconHeight()
        Specified by:
        getIconHeight in interface Icon