We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
qgis
Learn more about funding links in repositories.
Report abuse
There was an error while loading. Please reload this page.
1 parent 659bfe8 commit ea9d97bCopy full SHA for ea9d97b
src/app/qgsrasterlayerproperties.cpp
@@ -1869,6 +1869,15 @@ void QgsRasterLayerProperties::refreshHistogram()
1869
int myBandCountInt = mRasterLayer->bandCount();
1870
QList<QColor> myColors;
1871
myColors << Qt::black << Qt::red << Qt::green << Qt::blue << Qt::magenta << Qt::darkRed << Qt::darkGreen << Qt::darkBlue;
1872
+
1873
+ while ( myColors.size() <= myBandCountInt )
1874
+ {
1875
+ myColors <<
1876
+ QColor( 1 + ( int )( 255.0 * rand() / ( RAND_MAX + 1.0 ) ),
1877
+ 1 + ( int )( 255.0 * rand() / ( RAND_MAX + 1.0 ) ),
1878
+ 1 + ( int )( 255.0 * rand() / ( RAND_MAX + 1.0 ) ) );
1879
+ }
1880
1881
//
1882
//now draw actual graphs
1883
0 commit comments