also this problem is still not fully solved in version 2.3. But we found an interesting detail. The width of the first group seems to matter. If you don't create a 4th button, or make the texts smaller the 2nd group will become invisible.
Plese see our test code below.
Qtitan::RibbonPage* pPage = ribbonBar()->addPage( "test" );
if( pPage )
{
Qtitan::RibbonGroup* pGr = pPage->addGroup( "example" );
if( pGr )
{
static const QString s [] = {
":/RibbonTest2/Resources/file-openimage.png",
":/RibbonTest2/Resources/QA-undo.png",
":/RibbonTest2/Resources/QA-redo.png",
":/RibbonTest2/Resources/QA-save.png" };
QAction* pAct = new QAction( QPixmap( s[0] ), s[0], ribbonBar()->getQuickAccessBar() );
pGr->addAction( pAct, Qt::ToolButtonTextUnderIcon );
m_pOpenAction = pAct;
pAct = new QAction( QPixmap( s[1] ), s[1], ribbonBar()->getQuickAccessBar() );
pGr->addAction( pAct, Qt::ToolButtonTextUnderIcon );
pAct = new QAction( QPixmap( s[2] ), s[2], ribbonBar()->getQuickAccessBar() );
pGr->addAction( pAct, Qt::ToolButtonTextUnderIcon );
//toggling this makes it work or not
pAct = new QAction( QPixmap( s[3] ), s[3], ribbonBar()->getQuickAccessBar() );
pGr->addAction( pAct, Qt::ToolButtonTextUnderIcon );
}
//
pGr = pPage->addGroup( "example2" );
if( pGr )
{
pGr->setVisible(false); // this doesn't work (
static const QString s [] = {
":/RibbonTest2/Resources/file-openimage.png",
":/RibbonTest2/Resources/QA-undo.png",
":/RibbonTest2/Resources/QA-redo.png",
":/RibbonTest2/Resources/QA-save.png" };
size_t n = sizeof( s ) / sizeof( s[0] );
for( size_t i = 0; i < n; ++i )
{
QAction* pAct = new QAction( QPixmap( s[i] ), s[i], ribbonBar()->getQuickAccessBar() );
pGr->addAction( pAct, Qt::ToolButtonTextUnderIcon );
if( 0 == i )
m_pOpenAction = pAct;
}
}
}