Use colorLineEdit for heightmap color too

master
Unknown 2017-03-17 11:00:42 +01:00
parent 0f8fb0c5b7
commit b1bc4c5d53
3 changed files with 32 additions and 30 deletions

View File

@ -906,18 +906,6 @@ void MainWindow::on_path_OutputImage_textChanged()
ui->label_preview->setText(tr("preview: %1").arg(getOutputFileName()));
}
void MainWindow::on_selectHeightmapColor_clicked()
{
const QColorDialog::ColorDialogOptions options = QFlag(QColorDialog::DontUseNativeDialog);
const QColor color = QColorDialog::getColor(ui->colorHeightmap->text(), this, tr("select color"),options);
if (color.isValid()) {
ui->colorHeightmap->setText(color.name());
ui->colorHeightmap->setPalette(QPalette(color));
//ui->lineEdit_bgcolor->setAutoFillBackground(true);
}
}
void MainWindow::on_actionNew_Profile_triggered()
{
bool ok;

View File

@ -81,8 +81,6 @@ private slots:
void on_path_OutputImage_textChanged();
void on_selectHeightmapColor_clicked();
void on_button_cancel_clicked();
void on_actionNew_Profile_triggered();

View File

@ -936,7 +936,7 @@ Nodes higher than this level will not be drawn. This can be used to avoid floati
</widget>
</item>
<item row="2" column="1">
<widget class="QLineEdit" name="colorHeightmap">
<widget class="ColorLineEdit" name="colorHeightmap">
<property name="enabled">
<bool>false</bool>
</property>
@ -3330,8 +3330,8 @@ p, li { white-space: pre-wrap; }
<slot>forward()</slot>
<hints>
<hint type="sourcelabel">
<x>749</x>
<y>110</y>
<x>859</x>
<y>120</y>
</hint>
<hint type="destinationlabel">
<x>749</x>
@ -3346,8 +3346,8 @@ p, li { white-space: pre-wrap; }
<slot>zoomIn()</slot>
<hints>
<hint type="sourcelabel">
<x>847</x>
<y>100</y>
<x>959</x>
<y>120</y>
</hint>
<hint type="destinationlabel">
<x>846</x>
@ -3362,8 +3362,8 @@ p, li { white-space: pre-wrap; }
<slot>zoomOut()</slot>
<hints>
<hint type="sourcelabel">
<x>943</x>
<y>108</y>
<x>1059</x>
<y>120</y>
</hint>
<hint type="destinationlabel">
<x>943</x>
@ -3378,12 +3378,12 @@ p, li { white-space: pre-wrap; }
<slot>setEnabled(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>522</x>
<y>160</y>
<x>1060</x>
<y>241</y>
</hint>
<hint type="destinationlabel">
<x>522</x>
<y>104</y>
<x>659</x>
<y>120</y>
</hint>
</hints>
</connection>
@ -3398,8 +3398,8 @@ p, li { white-space: pre-wrap; }
<y>151</y>
</hint>
<hint type="destinationlabel">
<x>708</x>
<y>110</y>
<x>859</x>
<y>120</y>
</hint>
</hints>
</connection>
@ -3410,8 +3410,8 @@ p, li { white-space: pre-wrap; }
<slot>home()</slot>
<hints>
<hint type="sourcelabel">
<x>616</x>
<y>118</y>
<x>759</x>
<y>120</y>
</hint>
<hint type="destinationlabel">
<x>616</x>
@ -3419,12 +3419,28 @@ p, li { white-space: pre-wrap; }
</hint>
</hints>
</connection>
<connection>
<sender>selectHeightmapColor</sender>
<signal>clicked()</signal>
<receiver>colorHeightmap</receiver>
<slot>selectColor()</slot>
<hints>
<hint type="sourcelabel">
<x>434</x>
<y>291</y>
</hint>
<hint type="destinationlabel">
<x>379</x>
<y>292</y>
</hint>
</hints>
</connection>
</connections>
<buttongroups>
<buttongroup name="geometrymode_size_group"/>
<buttongroup name="group_tiles_tiles"/>
<buttongroup name="group_tiles_arrange"/>
<buttongroup name="group_tiles_arrange_at"/>
<buttongroup name="geometrymode_granularity_group"/>
<buttongroup name="geometrymode_size_group"/>
</buttongroups>
</ui>