[Libreoffice-commits] core.git: editeng/source
Dennis Francis (via logerrit)
logerrit at kemper.freedesktop.org
Thu Jul 9 09:29:46 UTC 2020
editeng/source/editeng/impedit.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 3a57c2b6478dfb9d5ffd3245aeafdd747afb69da
Author: Dennis Francis <dennis.francis at collabora.com>
AuthorDate: Fri Jun 5 18:10:12 2020 +0530
Commit: Dennis Francis <dennis.francis at collabora.com>
CommitDate: Thu Jul 9 11:28:55 2020 +0200
scPrintTwipsMsgs: Use top-left of output-area as the refpoint
We can't use the transformed version of editeng origin, since it need
not be in client view area depending on text alignment, which is
unusable as far as the clients are concerned. Top-left corner of
output-area is always guaranteed to be in client view area independent
of text-alignment settings.
Change-Id: I5bd20d2b52e146371de4b605bf7934b7e7d6fc5a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98131
Tested-by: Jenkins
Reviewed-by: Dennis Francis <dennis.francis at collabora.com>
diff --git a/editeng/source/editeng/impedit.cxx b/editeng/source/editeng/impedit.cxx
index 43165fefc1a0..e235d4eb74a4 100644
--- a/editeng/source/editeng/impedit.cxx
+++ b/editeng/source/editeng/impedit.cxx
@@ -1277,7 +1277,7 @@ void ImpEditView::ShowCursor( bool bGotoCursor, bool bForceVisCursor )
// Get rectangle in window-coordinates from editeng(doc) coordinates.
aCursorRectPureLogical = mpLOKSpecialPositioning->GetWindowPos(aCursorRectPureLogical, eDevUnit);
// Lets use the editeng(doc) origin as the refpoint.
- const Point aCursorOrigin = mpLOKSpecialPositioning->GetWindowPos(Point(0, 0), eDevUnit);
+ const Point aCursorOrigin = mpLOKSpecialPositioning->GetOutputArea().TopLeft();
// Get the relative coordinates w.r.t aCursorOrigin.
aCursorRectPureLogical.Move(-aCursorOrigin.X(), -aCursorOrigin.Y());
aMessageParams.put("relrect", aCursorRectPureLogical.toString());
More information about the Libreoffice-commits
mailing list