ahmadosama added a comment.
As far as I know rotating m_page->m_rects should rotate annotations on the page, the annotations seem to work well when rotating them. When rotating the highlights I tried to replace: (*hlIt)->transform( RotationJob::rotationMatrix( oldRotation, m_rotation ) ); with (*hlIt)->transform( matrix ); but highlights were rotated correctly only from the original orientation. I am thinking of creating another function to get the rotation matrix for the highlights, or modify the Okular::buildRotationMatrix as follows Okular::buildRotationMatrix(Rotation oldRotation = Rotation0, Rotation newRotation) I am still going through the code to find a better way to solve this bug. REPOSITORY R223 Okular REVISION DETAIL https://phabricator.kde.org/D11901 To: ahmadosama, #okular Cc: aacid, ngraham, #okular, michaelweghorn
