summaryrefslogtreecommitdiff
path: root/sc/source/ui/docshell
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/docshell')
-rw-r--r--sc/source/ui/docshell/docsh3.cxx6
-rw-r--r--sc/source/ui/docshell/sizedev.cxx4
2 files changed, 5 insertions, 5 deletions
diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx
index a0b4bf3858e5..b2cdf855982c 100644
--- a/sc/source/ui/docshell/docsh3.cxx
+++ b/sc/source/ui/docshell/docsh3.cxx
@@ -377,15 +377,15 @@ void ScDocShell::CalcOutputFactor()
MapMode aOldMode = pRefDev->GetMapMode();
vcl::Font aOldFont = pRefDev->GetFont();
- pRefDev->SetMapMode(MapUnit::MapPixel);
+ pRefDev->SetMapMode(MapMode(MapUnit::MapPixel));
pPattern->GetFont(aDefFont, SC_AUTOCOL_BLACK, pRefDev); // font color doesn't matter here
pRefDev->SetFont(aDefFont);
- nPrinterWidth = pRefDev->PixelToLogic( Size( pRefDev->GetTextWidth(aTestString), 0 ), MapUnit::Map100thMM ).Width();
+ nPrinterWidth = pRefDev->PixelToLogic(Size(pRefDev->GetTextWidth(aTestString), 0), MapMode(MapUnit::Map100thMM)).Width();
pRefDev->SetFont(aOldFont);
pRefDev->SetMapMode(aOldMode);
ScopedVclPtrInstance< VirtualDevice > pVirtWindow( *Application::GetDefaultDevice() );
- pVirtWindow->SetMapMode(MapUnit::MapPixel);
+ pVirtWindow->SetMapMode(MapMode(MapUnit::MapPixel));
pPattern->GetFont(aDefFont, SC_AUTOCOL_BLACK, pVirtWindow); // font color doesn't matter here
pVirtWindow->SetFont(aDefFont);
nWindowWidth = pVirtWindow->GetTextWidth(aTestString);
diff --git a/sc/source/ui/docshell/sizedev.cxx b/sc/source/ui/docshell/sizedev.cxx
index 4cf8e4e0000f..c5b7e416c83c 100644
--- a/sc/source/ui/docshell/sizedev.cxx
+++ b/sc/source/ui/docshell/sizedev.cxx
@@ -34,7 +34,7 @@ ScSizeDeviceProvider::ScSizeDeviceProvider( ScDocShell* pDocSh )
bOwner = false;
aOldMapMode = pDevice->GetMapMode();
- pDevice->SetMapMode( MapUnit::MapPixel ); // GetNeededSize needs pixel MapMode
+ pDevice->SetMapMode(MapMode(MapUnit::MapPixel)); // GetNeededSize needs pixel MapMode
// printer has right DigitLanguage already
}
else
@@ -44,7 +44,7 @@ ScSizeDeviceProvider::ScSizeDeviceProvider( ScDocShell* pDocSh )
bOwner = true;
}
- Point aLogic = pDevice->LogicToPixel( Point(1000,1000), MapUnit::MapTwip );
+ Point aLogic = pDevice->LogicToPixel(Point(1000,1000), MapMode(MapUnit::MapTwip));
nPPTX = aLogic.X() / 1000.0;
nPPTY = aLogic.Y() / 1000.0;