diff options
author | Tor Lillqvist <tml@collabora.com> | 2013-11-03 21:41:21 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@collabora.com> | 2013-11-15 16:52:04 +0100 |
commit | 84e0a5a56fcc7812577caa5dfb3ca5bb3b6ed547 (patch) | |
tree | f92032e50c57c63b90a00cb2c4c02f1110e95971 /sw | |
parent | 781e4edac5d7d2279a4d31d71a8b6b5218fb259c (diff) |
It seems that calling SetSwVisArea() has no effect
Make it optional at run-time (for now while testing) with an
environment variable.
Change-Id: I2ba1673fc51e91d0943148a0bf41351c87f272e5
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/view/viewsh.cxx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx index 1cee96568cd2..eeb1e65e8db9 100644 --- a/sw/source/core/view/viewsh.cxx +++ b/sw/source/core/view/viewsh.cxx @@ -1773,6 +1773,7 @@ void SwViewShell::PaintTile(OutputDevice *pOut, const Rectangle &rRect) extern "C" void touch_lo_draw_tile(void *context, int contextWidth, int contextHeight, MLODpxPoint tileDpxPosition, MLODpxSize tileDpxSize) { + // SAL_DEBUG("touch_lo_draw_tile(" << contextWidth << ", " << contextHeight << ", (" << tileDpxPosition.x << "," << tileDpxPosition.y << "), " << tileDpxSize.width << "x" << tileDpxSize.height << ")"); MLORipPoint tileRipPosition = MLORipPointByDpxPoint(tileDpxPosition); MLORipSize rileRipSize = MLORipSizeByDpxSize(tileDpxSize); MLORip tileRipPosX = tileRipPosition.x; @@ -1808,7 +1809,15 @@ void touch_lo_draw_tile(void *context, int contextWidth, int contextHeight, MLOD aMapMode.SetScaleX(scaleX); aMapMode.SetScaleY(scaleY); aDevice.SetMapMode(aMapMode); - SetSwVisArea( pViewShell, SwRect(Point(tilePosX, tilePosY), Size(tileWidth, tileHeight)) ); + static bool bCallSetSwVisArea = getenv("CALLSETSWVISAREA") != NULL; + if (bCallSetSwVisArea) + { + // SwRect foo = pViewShell->VisArea(); + // SAL_DEBUG("old VisArea: " << foo); + SetSwVisArea( pViewShell, SwRect(Point(tilePosX, tilePosY), Size(tileWidth, tileHeight)) ); + // foo = pViewShell->VisArea(); + // SAL_DEBUG("new VisArea: " << foo); + } // resizes the virtual device so to contain the entrie context aDevice.SetOutputSizePixel(Size(contextWidth, contextHeight)); // draw - works in logic coordinates |