Created attachment 179700 [details] Sample document with shapes Steps to reproduce: 1) open the attached Calc doc "shapes.ods" in Android Viewer or gtktiledviewer 2) zoom in and out 3) look at how the text around the shapes is positioned Actual result: When zooming in and out, the position of shapes relative to the text changes, e.g. at some zoom levels, the text is even below the shapes. Expected result: Relative position of shapes and text should remain the same for all zoom levels. Reproducible with gtktiledviewer in a current master development build like this: ./bin/run gtktiledviewer --lo-path=$(pwd)/instdir/program /tmp/shapes.ods Screencasts will be attached. This is with git master as of commit 5d56255c22c79b72c1cedb48cfe0a200f89bdc66.
Created attachment 179701 [details] Screencast for Android Viewer
Created attachment 179702 [details] Screencast for gtktiledviewer
While looking at a different Android issue, I came across this: > sc/source/ui/view/gridwin4.cxx- // setup the SdrPage so that drawinglayer works correctly > sc/source/ui/view/gridwin4.cxx- ScDrawLayer* pModel = rDoc.GetDrawLayer(); > sc/source/ui/view/gridwin4.cxx- if (pModel) > sc/source/ui/view/gridwin4.cxx- { > sc/source/ui/view/gridwin4.cxx- bool bPrintTwipsMsgs = comphelper::LibreOfficeKit::isCompatFlagSet( > sc/source/ui/view/gridwin4.cxx: comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs); > sc/source/ui/view/gridwin4.cxx- mpLOKDrawView.reset(bPrintTwipsMsgs ? > sc/source/ui/view/gridwin4.cxx- new ScLOKDrawView( > sc/source/ui/view/gridwin4.cxx- &rDevice, > sc/source/ui/view/gridwin4.cxx- mrViewData) : > sc/source/ui/view/gridwin4.cxx- new FmFormView( > sc/source/ui/view/gridwin4.cxx- *pModel, > sc/source/ui/view/gridwin4.cxx- &rDevice)); > sc/source/ui/view/gridwin4.cxx- > sc/source/ui/view/gridwin4.cxx- mpLOKDrawView->SetNegativeX(bLayoutRTL); > sc/source/ui/view/gridwin4.cxx- mpLOKDrawView->ShowSdrPage(mpLOKDrawView->GetModel()->GetPage(nTab)); > sc/source/ui/view/gridwin4.cxx- aOutputData.SetDrawView(mpLOKDrawView.get()); > sc/source/ui/view/gridwin4.cxx- aOutputData.SetSpellCheckContext(mpSpellCheckCxt.get()); > sc/source/ui/view/gridwin4.cxx- } In a quick test, unconditionally setting comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs as below made rendering work fine in Android Viewer and gtktiledviewer. The below was just for testing, but I plan to take a closer look at some point whether setting that compat flag for both of them is the way forward. diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index 462e2e5d25af..36ed36951999 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -6482,6 +6482,9 @@ static int lo_initialize(LibreOfficeKit* pThis, const char* pAppPath, const char } } + comphelper::LibreOfficeKit::setCompatFlag( + comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs); + // What stage are we at ? if (pThis == nullptr) {
Unassigning for now, but I might come back to that at some point in time unless anybody else finds time earlier.