Allow value and reference text to be rotated by 90, 180, and 270 degrees.

This commit is contained in:
Kevin Cozens 2016-03-14 20:51:28 -04:00 committed by Wayne Stambaugh
parent 1412296398
commit f71d3fe7b6
1 changed files with 5 additions and 3 deletions

View File

@ -328,9 +328,11 @@ double TEXTE_MODULE::GetDrawRotation() const
if( module )
rotation += module->GetOrientation();
// Keep angle between -90 .. 90 deg. Otherwise the text is not easy to read
while( rotation > 900 )
rotation -= 1800;
NORMALIZE_ANGLE_POS( rotation );
// For angle = 0 .. 360 deg
while( rotation > 2700 )
rotation -= 3600;
while( rotation < -900 )
rotation += 1800;