Unfortunately, this looks like it cannot be supported by the library for all
possible ribbon bands. The main issue is that the content of the original band
needs to be duplicated to be shown in the popup.
Suppose the original ribbon band has a few command buttons, and a combobox.
Then, the popup ribbon band needs to have exactly the same controls - with
exactly the same behavior. While it is possible to recreate the simple
characteristics of the command buttons - such as text and priority, the rest is
more difficult - if not too difficult.
First, the icon instances cannot be reused across different command buttons.
While this can be addressed, a much bigger issue is with listeners. Application
code can register custom listeners with the model + the action listeners. In
addition, the internal UI delegates wire their own listeners for different
purposes. Since in Swing a control can only have one parent, the button will
effectively need to be cloned to be able to show it in two different places at
the same time. The listener list cannot be cloned - some of the listeners come
from the original UI delegate and should not be part of the cloned button. This
can also be addressed by overriding the tracking of listeners and somehow
differentiating between application listeners and listeners coming from UI
The same applies for core / third-party controls placed in the ribbon - where we
have even less control over the component code, and even more functionality
exposed to the applications. Here, we're talking about models, renderers,
editors, documents etc.
Given this complexity, this enhancement is marked as WONTFIX. It will be known
as a feature gap between Flamingo and Office 2007.
Interested applications will need to provide this functionality by maintaining a
separate copy of a ribbon band. A command button is added to the task bar. An
action listener is added to the command button. This action listener uses
PopupPanelManager to show the relevant (copy) ribbon band. See code in
BasicCommandButtonUI.processPopupAction for sample code on how to do this.