Mercurial > hg > svgui
diff layer/RegionLayer.h @ 433:ac349afdb23f
* somewhat clearer layout in region layer
author | Chris Cannam |
---|---|
date | Thu, 16 Oct 2008 13:38:33 +0000 |
parents | 1304dbe4542e |
children | 5930f2b0b1d2 |
line wrap: on
line diff
--- a/layer/RegionLayer.h Wed Oct 15 12:08:02 2008 +0000 +++ b/layer/RegionLayer.h Thu Oct 16 13:38:33 2008 +0000 @@ -22,6 +22,8 @@ #include <QObject> #include <QColor> +#include <map> + class View; class QPainter; @@ -80,6 +82,7 @@ enum VerticalScale { AutoAlignScale, + EqualSpaced, LinearScale, LogScale, }; @@ -111,6 +114,9 @@ void setProperties(const QXmlAttributes &attributes); +protected slots: + void recalcSpacing(); + protected: void getScaleExtents(View *, float &min, float &max, bool &log) const; int getYForValue(View *v, float value) const; @@ -130,6 +136,9 @@ int m_colourMap; PlotStyle m_plotStyle; + typedef std::map<float, int> SpacingMap; + SpacingMap m_spacingMap; + void finish(RegionModel::EditCommand *command) { Command *c = command->finish(); if (c) CommandHistory::getInstance()->addCommand(c, false);