Mercurial > hg > svgui
diff layer/LinearNumericalScale.cpp @ 1216:dc2af6616c83
Merge from branch 3.0-integration
author | Chris Cannam |
---|---|
date | Fri, 13 Jan 2017 10:29:50 +0000 |
parents | 5144d7185fb5 |
children | 0cc6ab236b0d |
line wrap: on
line diff
--- a/layer/LinearNumericalScale.cpp Fri Mar 04 12:23:31 2016 +0000 +++ b/layer/LinearNumericalScale.cpp Fri Jan 13 10:29:50 2017 +0000 @@ -20,17 +20,17 @@ #include <cmath> -#include "view/View.h" +#include "LayerGeometryProvider.h" int -LinearNumericalScale::getWidth(View *, +LinearNumericalScale::getWidth(LayerGeometryProvider *, QPainter &paint) { return paint.fontMetrics().width("-000.00") + 10; } void -LinearNumericalScale::paintVertical(View *v, +LinearNumericalScale::paintVertical(LayerGeometryProvider *v, const VerticalScaleLayer *layer, QPainter &paint, int x0, @@ -69,7 +69,7 @@ double dispval = val; if (i == n-1 && - v->height() < paint.fontMetrics().height() * (n*2)) { + v->getPaintHeight() < paint.fontMetrics().height() * (n*2)) { if (layer->getScaleUnits() != "") drawText = false; } dispval = int(rint(val / round) * round);