This commit finalizes the refactoring of the LogicToLogic() coordinate
mapping pipeline by completely encapsulating both scaling and origin
translation within the ImplMapRes struct.
By recognizing the mathematical symmetry of the affine transformation,
origin shifts are now explicitly decoupled from the scaling logic. This
allows the complete transformation pipeline to be handled internally,
making the call sites in map.cxx significantly cleaner and less prone
to offset-related bugs.
Key changes:
- Removed the intermediate ScaleLogicX() and ScaleLogicY() methods.
- Introduced explicit LocalToAbsolute() and AbsoluteToLocal() helper
methods to handle origin offset addition and subtraction.
- Added TransformPointX() and TransformPointY(), which cleanly implement
the full pipeline: LocalToAbsolute() -> ScaleDistance() -> AbsoluteToLocal().
- Updated OutputDevice::LogicToLogic() overloads for Point and Rectangle
to use the new TransformPoint methods, successfully removing all
manual destination offset subtractions from map.cxx.
Change-Id: Ibb42f62d6904ae282dabf697b35455aec7c17677
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203680
Tested-by: Jenkins
Reviewed-by: Dan Williams <dcbw@libreoffice.org>