summaryrefslogtreecommitdiff
path: root/sc/source/ui
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui')
-rw-r--r--sc/source/ui/inc/output.hxx7
-rw-r--r--sc/source/ui/miscdlgs/autofmt.cxx4
-rw-r--r--sc/source/ui/view/gridwin4.cxx4
-rw-r--r--sc/source/ui/view/output.cxx3
4 files changed, 10 insertions, 8 deletions
diff --git a/sc/source/ui/inc/output.hxx b/sc/source/ui/inc/output.hxx
index 2237b7daa560..8165bfda86d0 100644
--- a/sc/source/ui/inc/output.hxx
+++ b/sc/source/ui/inc/output.hxx
@@ -252,6 +252,11 @@ private:
bool AdjustAreaParamClipRect(OutputAreaParam& rAreaParam);
+ // Check for and set cell rotations at OutputData to have it available
+ // in the svx tooling to render the borders. Moved to private section
+ // and the single call to end of constructor to be sure this always happens
+ void SetCellRotations();
+
public:
/**
* @param nNewScrX: X-Offset in the output device for the table
@@ -308,8 +313,6 @@ public:
// with logic MapMode set!
void DrawEdit(bool bPixelToLogic);
-
- void SetCellRotations();
void DrawRotated(bool bPixelToLogic); // logical
void DrawClear();
diff --git a/sc/source/ui/miscdlgs/autofmt.cxx b/sc/source/ui/miscdlgs/autofmt.cxx
index e5276b3f8803..399edd9b25b6 100644
--- a/sc/source/ui/miscdlgs/autofmt.cxx
+++ b/sc/source/ui/miscdlgs/autofmt.cxx
@@ -250,7 +250,7 @@ void ScAutoFmtPreview::DrawString(vcl::RenderContext& rRenderContext, size_t nCo
Size aStrSize;
sal_uInt16 nFmtIndex = GetFormatIndex( nCol, nRow );
- const basegfx::B2DRange cellRange(maArray.GetCellRange( nCol, nRow ));
+ const basegfx::B2DRange cellRange(maArray.GetCellRange( nCol, nRow, true ));
Point aPos = Point(basegfx::fround(cellRange.getMinX()), basegfx::fround(cellRange.getMinY()));
sal_uInt16 nRightX = 0;
bool bJustify = pCurData->GetIncludeJustify();
@@ -374,7 +374,7 @@ void ScAutoFmtPreview::DrawBackground(vcl::RenderContext& rRenderContext)
rRenderContext.SetLineColor();
rRenderContext.SetFillColor( pItem->GetColor() );
- const basegfx::B2DRange aCellRange(maArray.GetCellRange( nCol, nRow ));
+ const basegfx::B2DRange aCellRange(maArray.GetCellRange( nCol, nRow, true ));
rRenderContext.DrawRect(
tools::Rectangle(
basegfx::fround(aCellRange.getMinX()), basegfx::fround(aCellRange.getMinY()),
diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx
index 9387c1e6d79c..92b0eee6cc96 100644
--- a/sc/source/ui/view/gridwin4.cxx
+++ b/sc/source/ui/view/gridwin4.cxx
@@ -696,10 +696,6 @@ void ScGridWindow::DrawContent(OutputDevice &rDevice, const ScTableInfo& rTableI
pContentDev->SetMapMode(aCurrentMapMode);
}
- // check for and set cell rotations at OutputData to have it available
- // in the svx tooling to render the borders
- aOutputData.SetCellRotations();
-
if ( rDoc.HasBackgroundDraw( nTab, aDrawingRectLogic ) )
{
pContentDev->SetMapMode(MapMode(MapUnit::MapPixel));
diff --git a/sc/source/ui/view/output.cxx b/sc/source/ui/view/output.cxx
index 6cfa4c2861b1..6e0fa1a77e5c 100644
--- a/sc/source/ui/view/output.cxx
+++ b/sc/source/ui/view/output.cxx
@@ -214,6 +214,9 @@ ScOutputData::ScOutputData( OutputDevice* pNewDev, ScOutputType eNewType,
bTabProtected = mpDoc->IsTabProtected( nTab );
bLayoutRTL = mpDoc->IsLayoutRTL( nTab );
+
+ // always needed, so call at the end of the constructor
+ SetCellRotations();
}
ScOutputData::~ScOutputData()