comparison Framework/Scene2DViewport/AngleMeasureTool.cpp @ 908:2f16ad9d30ad

merge
author Alain Mazy <alain@mazy.be>
date Thu, 18 Jul 2019 09:22:08 +0200
parents 52b1c6ff10c5
children ac88989817e3
comparison
equal deleted inserted replaced
907:722ee73e6ba2 908:2f16ad9d30ad
41 // the params in the LayerHolder ctor specify the number of polyline and text 41 // the params in the LayerHolder ctor specify the number of polyline and text
42 // layers 42 // layers
43 AngleMeasureTool::AngleMeasureTool( 43 AngleMeasureTool::AngleMeasureTool(
44 MessageBroker& broker, boost::weak_ptr<ViewportController> controllerW) 44 MessageBroker& broker, boost::weak_ptr<ViewportController> controllerW)
45 : MeasureTool(broker, controllerW) 45 : MeasureTool(broker, controllerW)
46 #if ORTHANC_STONE_ENABLE_OUTLINED_TEXT == 1
46 , layerHolder_(boost::make_shared<LayerHolder>(controllerW,1,5)) 47 , layerHolder_(boost::make_shared<LayerHolder>(controllerW,1,5))
48 #else
49 , layerHolder_(boost::make_shared<LayerHolder>(controllerW, 1, 1))
50 #endif
47 , angleHighlightArea_(AngleHighlightArea_None) 51 , angleHighlightArea_(AngleHighlightArea_None)
48 { 52 {
49 RefreshScene(); 53 RefreshScene();
50 } 54 }
51 55
291 double angleDeg = RadiansToDegrees(delta); 295 double angleDeg = RadiansToDegrees(delta);
292 296
293 // http://www.ltg.ed.ac.uk/~richard/utf-8.cgi?input=00B0&mode=hex 297 // http://www.ltg.ed.ac.uk/~richard/utf-8.cgi?input=00B0&mode=hex
294 sprintf(buf, "%0.02f\xc2\xb0", angleDeg); 298 sprintf(buf, "%0.02f\xc2\xb0", angleDeg);
295 299
300 #if ORTHANC_STONE_ENABLE_OUTLINED_TEXT == 1
296 SetTextLayerOutlineProperties( 301 SetTextLayerOutlineProperties(
297 GetController()->GetScene(), layerHolder_, buf, ScenePoint2D(pointX, pointY)); 302 GetController()->GetScene(), layerHolder_, buf, ScenePoint2D(pointX, pointY), 0);
303 #else
304 SetTextLayerProperties(
305 GetController()->GetScene(), layerHolder_, buf, ScenePoint2D(pointX, pointY) , 0);
306 #endif
298 307
299 #if 0 308 #if 0
300 // TODO:make it togglable 309 // TODO:make it togglable
301 bool enableInfoDisplay = true; 310 bool enableInfoDisplay = true;
302 if (enableInfoDisplay) 311 if (enableInfoDisplay)