From 04dcb8867feae425e57aabe17c6337bfe7740e86 Mon Sep 17 00:00:00 2001 From: Sylvie Lamy-Thepaut Date: Tue, 21 Nov 2023 13:51:13 +0000 Subject: [PATCH] Opencharts : Symbol Plotting by property --- src/visualisers/SymbolPlotting.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/visualisers/SymbolPlotting.cc b/src/visualisers/SymbolPlotting.cc index cd890898..362f29e8 100644 --- a/src/visualisers/SymbolPlotting.cc +++ b/src/visualisers/SymbolPlotting.cc @@ -200,8 +200,10 @@ void SymbolPlotting::by_property(Data& data, BasicGraphicsObjectContainer& out) height = height*property_height_scaling_factor_*factor; symbol->setHeight(height); + + PaperPoint xy = transformation(UserPoint(point->longitude(), point->latitude())); - symbol->push_back(transformation(PaperPoint(point->longitude(), point->latitude()))); + symbol->push_back(xy); out.push_back(symbol); @@ -251,7 +253,7 @@ void SymbolPlotting::operator()(Data& data, BasicGraphicsObjectContainer& out) { try { - const Transformation& transformation = out.transformation(); + // If we need to connect the symbols with a line, we need all the poinst // to enable proper clipping of the line! Othewise wee just nedde to get the point @@ -267,6 +269,7 @@ void SymbolPlotting::operator()(Data& data, BasicGraphicsObjectContainer& out) { points.setToFirst(); while (points.more()) { + PaperPoint xy = transformation(points.current()); (*this)(xy, out); points.advance();