#5404 Make horizontal legend use more than 4 columns if possible

This commit is contained in:
Gaute Lindkvist 2020-02-07 15:19:16 +01:00
parent 487b55046e
commit 25616e3aa7

View File

@ -175,7 +175,7 @@ void RiuMultiPlotPage::insertPlot( RiuQwtPlotWidget* plotWidget, size_t index )
int legendColumns = 1;
if ( m_plotDefinition->legendsHorizontal() )
{
legendColumns = 4; // unlimited
legendColumns = 0; // unlimited
}
legend->setMaxColumns( legendColumns );
legend->horizontalScrollBar()->setVisible( false );
@ -618,7 +618,7 @@ void RiuMultiPlotPage::reinsertPlotWidgets()
int legendColumns = 1;
if ( m_plotDefinition->legendsHorizontal() )
{
legendColumns = 4; // unlimited
legendColumns = 0; // unlimited
}
legends[visibleIndex]->setMaxColumns( legendColumns );
QFont legendFont = legends[visibleIndex]->font();