From 97ae63fa3914ac9894a319c0c75eeeffe96b16e9 Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 3 May 2014 20:21:13 +1000 Subject: Replacing the int-based constructors for Point and PRectangle with FromInts static methods as there were too many failures with mixed types and not-quite matching types. --- src/Indicator.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Indicator.cxx') diff --git a/src/Indicator.cxx b/src/Indicator.cxx index ba20dd941..63735d480 100644 --- a/src/Indicator.cxx +++ b/src/Indicator.cxx @@ -20,7 +20,7 @@ using namespace Scintilla; static PRectangle PixelGridAlign(const PRectangle &rc) { // Move left and right side to nearest pixel to avoid blurry visuals - return PRectangle(int(rc.left + 0.5), int(rc.top), int(rc.right + 0.5), int(rc.bottom)); + return PRectangle::FromInts(int(rc.left + 0.5), int(rc.top), int(rc.right + 0.5), int(rc.bottom)); } void Indicator::Draw(Surface *surface, const PRectangle &rc, const PRectangle &rcLine) { @@ -148,7 +148,7 @@ void Indicator::Draw(Surface *surface, const PRectangle &rc, const PRectangle &r } else if (style == INDIC_DOTS) { int x = static_cast(rc.left); while (x < static_cast(rc.right)) { - PRectangle rcDot(x, ymid, x+1, ymid+1); + PRectangle rcDot = PRectangle::FromInts(x, ymid, x + 1, ymid + 1); surface->FillRectangle(rcDot, fore); x += 2; } -- cgit v1.2.3