Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#436 closed defect (fixed)

Stylization: Modify rotation calculation to use atan

Reported by: louisewatson Owned by: louisewatson
Priority: medium Milestone: 2.0
Component: Rendering Service Version: 2.0.0
Severity: major Keywords:
Cc: External ID: 1041451


When lines are labeled, some of the labels are upside down making them hard to read.

Change History (3)

comment:1 Changed 11 years ago by louisewatson

Owner: changed from Louise Watson to louisewatson
Status: newassigned

comment:2 Changed 11 years ago by louisewatson

Resolution: fixed
Status: assignedclosed

This problem was due to the fact that atan2 was being used to calculate the rotation of the line labels based on the slope of the line. Atan2 takes two parameters, dx and dy, and considers the sign of each to return values in any of the 4 quadrants.

The fix was to calculate the slope as dy/dx and pass to atan. Atan only returns values in the first two quadrants.

comment:3 Changed 11 years ago by tomfukushima

Milestone: 2.12.0
Note: See TracTickets for help on using tickets.