Mercurial > hg > svgui
diff view/Pane.cpp @ 1362:d79e21855aef
Add mechanism for saving/loading colour maps by name/id rather than by numerical index, for future compatibility when adding to or changing the supported colour maps. Add two new colour maps (and one old one). Write out backward-compatible numerical indices for use when reloading in older versions. Also add a mechanism to invert the colour map, though I don't think it turns out useful enough to include in the UI.
author | Chris Cannam |
---|---|
date | Thu, 18 Oct 2018 13:21:56 +0100 |
parents | 93eaff6f206d |
children | bbeffb29bf09 |
line wrap: on
line diff
--- a/view/Pane.cpp Fri Oct 12 11:17:29 2018 +0100 +++ b/view/Pane.cpp Thu Oct 18 13:21:56 2018 +0100 @@ -111,7 +111,9 @@ if (!isVisible()) return; Layer *layer = 0; - if (getLayerCount() > 0) layer = getLayer(getLayerCount() - 1); + if (getLayerCount() > 0) { + layer = getLayer(getLayerCount() - 1); + } if (!m_headsUpDisplay) { @@ -189,12 +191,8 @@ m_hthumb->setMaximumValue(count); m_hthumb->setValue(count - current); -// cerr << "set value to " << count - 1 - current << endl; -// cerr << "default value is " << m_hthumb->getDefaultValue() << endl; - if (m_hthumb->getDefaultValue() == 0) { m_hthumb->setDefaultValue(count - current); -// cerr << "set default value to " << m_hthumb->getDefaultValue() << endl; } bool haveVThumb = false;