Class BasicRibbonUI

    • Field Detail

      • ribbon

        protected JRibbon ribbon
        The associated ribbon.
      • bandScrollablePanel

        protected JScrollablePanel<javax.swing.JPanel> bandScrollablePanel
      • applicationMenuButton

        protected JCommandButton applicationMenuButton
      • anchoredButtons

        private java.awt.Container anchoredButtons
      • ribbonChangeListener

        private javax.swing.event.ChangeListener ribbonChangeListener
        Change listener.
      • propertyChangeListener

        private java.beans.PropertyChangeListener propertyChangeListener
        Property change listener.
      • ribbonComponentListener

        private java.awt.event.ComponentListener ribbonComponentListener
    • Constructor Detail

      • BasicRibbonUI

        protected BasicRibbonUI()
        Creates a new basic ribbon UI delegate.
    • Method Detail

      • installUI

        public void installUI​(javax.swing.JComponent c)
        Overrides:
        installUI in class javax.swing.plaf.ComponentUI
      • uninstallUI

        public void uninstallUI​(javax.swing.JComponent c)
        Overrides:
        uninstallUI in class javax.swing.plaf.ComponentUI
      • installListeners

        protected void installListeners()
        Installs listeners on the associated ribbon.
      • uninstallListeners

        protected void uninstallListeners()
        Uninstalls listeners from the associated ribbon.
      • installDefaults

        protected void installDefaults()
        Installs defaults on the associated ribbon.
      • uninstallDefaults

        protected void uninstallDefaults()
        Uninstalls defaults from the associated ribbon.
      • installComponents

        protected void installComponents()
        Installs subcomponents on the associated ribbon.
      • createApplicationMenuButton

        private JCommandButton createApplicationMenuButton()
      • createTaskToggleButtonsHostPanelLayoutManager

        private java.awt.LayoutManager createTaskToggleButtonsHostPanelLayoutManager()
      • createBandHostPanelLayoutManager

        private java.awt.LayoutManager createBandHostPanelLayoutManager()
      • uninstallComponents

        protected void uninstallComponents()
        Uninstalls subcomponents from the associated ribbon.
      • update

        public void update​(java.awt.Graphics g,
                           javax.swing.JComponent c)
        Overrides:
        update in class javax.swing.plaf.ComponentUI
      • paint

        public void paint​(java.awt.Graphics g,
                          javax.swing.JComponent c)
        Overrides:
        paint in class javax.swing.plaf.ComponentUI
      • paintMinimizedRibbonSeparator

        protected abstract void paintMinimizedRibbonSeparator​(java.awt.Graphics g)
      • paintBackground

        protected abstract void paintBackground​(java.awt.Graphics g)
        Paints the ribbon background.
        Parameters:
        g - Graphics context.
      • getContextualTaskGroupBounds

        public java.awt.Rectangle getContextualTaskGroupBounds​(RibbonContextualTaskGroup group)
        Description copied from class: RibbonUI
        Returns the bounds of the specified contextual task group.
        Specified by:
        getContextualTaskGroupBounds in class RibbonUI
        Parameters:
        group - Contextual task group.
        Returns:
        The bounds of the specified contextual task group.
      • getBandGap

        private int getBandGap()
        Returns the layout gap for the bands in the associated ribbon.
        Returns:
        The layout gap for the bands in the associated ribbon.
      • getTabButtonGap

        protected int getTabButtonGap()
        Returns the layout gap for the tab buttons in the associated ribbon.
        Returns:
        The layout gap for the tab buttons in the associated ribbon.
      • createLayoutManager

        protected java.awt.LayoutManager createLayoutManager()
        Invoked by installUI to create a layout manager object to manage the JRibbon.
        Returns:
        a layout manager object
      • syncSelectedTask

        private void syncSelectedTask()
      • syncRibbonState

        private void syncRibbonState()
      • getCurrentlyShownRibbonTasks

        private java.util.List<RibbonTask> getCurrentlyShownRibbonTasks()
        Returns the list of currently shown ribbon tasks. This method is for internal use only.
        Returns:
        The list of currently shown ribbon tasks.
      • getAnchoredCommandButtons

        public java.util.List<JCommandButton> getAnchoredCommandButtons()
      • handleMouseWheelEvent

        public void handleMouseWheelEvent​(java.awt.event.MouseWheelEvent e)
        Specified by:
        handleMouseWheelEvent in class RibbonUI
      • scrollAndRevealTaskToggleButton

        private void scrollAndRevealTaskToggleButton​(JCommandButton taskToggleButton)