When I open a QColorPicker, I click in the coloor map in the top center, and select any color (lets say red) this color appears as black in the selected color bar bottom center.
I have to move additionally the slider on the top right (see red arrow) to its top position, to approach the selected color. Why is this slider not initially set to the highest value, so I do not see black always?
In the documentation it refers to the Standard Dialogs example:
void Dialog::setColor()
{
const QColorDialog::ColorDialogOptions options = QFlag(colorDialogOptionsWidget->value());
const QColor color = QColorDialog::getColor(Qt::green, this, "Select Color", options);
if (color.isValid()) {
colorLabel->setText(color.name());
colorLabel->setPalette(QPalette(color));
colorLabel->setAutoFillBackground(true);
}
}
Note in QColorDialog::getColor
how it specifies an initial color. This should set the brightness bar for you.
http://doc.qt.io/qt-5/qcolordialog.html#getColor
QColor QColorDialog::getColor(const QColor & initial = Qt::white, QWidget * parent = 0, const QString & title = QString(), ColorDialogOptions options = 0)
Hope that helps.