Commit 99f78112 authored by NICLAUSSE Nicolas's avatar NICLAUSSE Nicolas

fix setting of color map

parent 76a34cec
......@@ -304,6 +304,8 @@ void dtkVisualizationDecoratorWithClut::restoreSettings(void)
d->colormap_editor->blockSignals(true);
d->colormap_editor->setValue(d->default_color_map);
d->colormap_editor->blockSignals(false);
this->setColorMap(d->colormap_editor->value());
d->show_scalar_bar->blockSignals(true);
d->show_scalar_bar->setChecked(d->default_show_scalar_bar);
d->show_scalar_bar->blockSignals(false);
......@@ -341,7 +343,9 @@ void dtkVisualizationDecoratorWithClut::touch(void)
d->max_range->setText(QString::number(range[1]));
d->max_range->blockSignals(false);
d->colormap_editor->blockSignals(true);
d->colormap_editor->setValue(d->color_transfer_functions[d->current_field_name]);
d->colormap_editor->blockSignals(false);
this->setColorMap(d->colormap_editor->value());
}
......@@ -434,6 +438,8 @@ void dtkVisualizationDecoratorWithClut::setColorMap(const QMap<double, QColor>&
color.blue() / 255.);
}
d->colormap_editor->setValue(new_colormap);
d->color_function->ClampingOn();
d->color_function->Modified();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment