summaryrefslogtreecommitdiff
path: root/sw/source/uibase
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/uibase')
-rw-r--r--sw/source/uibase/app/appenv.cxx2
-rw-r--r--sw/source/uibase/dochdl/swdtflvr.cxx10
-rw-r--r--sw/source/uibase/docvw/srcedtw.cxx2
-rw-r--r--sw/source/uibase/ribbar/workctrl.cxx4
-rw-r--r--sw/source/uibase/shells/grfshex.cxx4
-rw-r--r--sw/source/uibase/table/chartins.cxx2
-rw-r--r--sw/source/uibase/uiview/srcview.cxx4
-rw-r--r--sw/source/uibase/uiview/viewdraw.cxx4
-rw-r--r--sw/source/uibase/uiview/viewport.cxx2
-rw-r--r--sw/source/uibase/utlui/content.cxx2
-rw-r--r--sw/source/uibase/utlui/glbltree.cxx2
-rw-r--r--sw/source/uibase/utlui/shdwcrsr.cxx2
-rw-r--r--sw/source/uibase/wrtsh/wrtsh1.cxx4
13 files changed, 22 insertions, 22 deletions
diff --git a/sw/source/uibase/app/appenv.cxx b/sw/source/uibase/app/appenv.cxx
index 9dd8145a7b0f..447205517e6e 100644
--- a/sw/source/uibase/app/appenv.cxx
+++ b/sw/source/uibase/app/appenv.cxx
@@ -344,7 +344,7 @@ void SwModule::InsertEnv( SfxRequest& rReq )
// Borders (are put together by Shift-Offset and alignment)
Size aPaperSize = pPrt->PixelToLogic( pPrt->GetPaperSizePixel(),
- MapUnit::MapTwip);
+ MapMode(MapUnit::MapTwip));
if ( !aPaperSize.Width() && !aPaperSize.Height() )
aPaperSize = SvxPaperInfo::GetPaperSize(PAPER_A4);
if ( aPaperSize.Width() > aPaperSize.Height() )
diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx
index 1f206ea72bd4..f46c7767e5b8 100644
--- a/sw/source/uibase/dochdl/swdtflvr.cxx
+++ b/sw/source/uibase/dochdl/swdtflvr.cxx
@@ -831,7 +831,7 @@ int SwTransferable::PrepareForCopy( bool bIsCut )
// --> OD #i98753#
// set size of embedded object at the object description structure
- m_aObjDesc.maSize = OutputDevice::LogicToLogic( m_pWrtShell->GetObjSize(), MapUnit::MapTwip, MapUnit::Map100thMM );
+ m_aObjDesc.maSize = OutputDevice::LogicToLogic(m_pWrtShell->GetObjSize(), MapMode(MapUnit::MapTwip), MapMode(MapUnit::Map100thMM));
// <--
PrepareOLE( m_aObjDesc );
AddFormat( SotClipboardFormatId::OBJECTDESCRIPTOR );
@@ -979,7 +979,7 @@ int SwTransferable::PrepareForCopy( bool bIsCut )
//Now adjust it. Thus in GetData the first query can still
//be answered with delayed rendering.
Size aSz( OLESIZE );
- m_aObjDesc.maSize = OutputDevice::LogicToLogic( aSz, MapUnit::MapTwip, MapUnit::Map100thMM );
+ m_aObjDesc.maSize = OutputDevice::LogicToLogic(aSz, MapMode(MapUnit::MapTwip), MapMode(MapUnit::Map100thMM));
PrepareOLE( m_aObjDesc );
AddFormat( SotClipboardFormatId::OBJECTDESCRIPTOR );
@@ -1072,7 +1072,7 @@ int SwTransferable::CopyGlossary( SwTextBlocks& rGlossary, const OUString& rStr
//Now adjust it. Thus in GetData the first query can still
//be answered with delayed rendering.
Size aSz( OLESIZE );
- m_aObjDesc.maSize = OutputDevice::LogicToLogic( aSz, MapUnit::MapTwip, MapUnit::Map100thMM );
+ m_aObjDesc.maSize = OutputDevice::LogicToLogic(aSz, MapMode(MapUnit::MapTwip), MapMode(MapUnit::Map100thMM));
PrepareOLE( m_aObjDesc );
AddFormat( SotClipboardFormatId::OBJECTDESCRIPTOR );
@@ -1882,7 +1882,7 @@ bool SwTransferable::PasteOLE( TransferableDataHelper& rData, SwWrtShell& rSh,
{
aSize = aObjDesc.maSize; //always 100TH_MM
MapUnit aUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( aObjDesc.mnViewAspect ) );
- aSize = OutputDevice::LogicToLogic( aSize, MapUnit::Map100thMM, aUnit );
+ aSize = OutputDevice::LogicToLogic(aSize, MapMode(MapUnit::Map100thMM), MapMode(aUnit));
awt::Size aSz;
try
{
@@ -3101,7 +3101,7 @@ void SwTransferable::SetDataForDragAndDrop( const Point& rSttPos )
//be answered with delayed rendering.
m_aObjDesc.maDragStartPos = rSttPos;
m_aObjDesc.maSize = OutputDevice::LogicToLogic( Size( OLESIZE ),
- MapUnit::MapTwip, MapUnit::Map100thMM );
+ MapMode(MapUnit::MapTwip), MapMode(MapUnit::Map100thMM));
PrepareOLE( m_aObjDesc );
AddFormat( SotClipboardFormatId::OBJECTDESCRIPTOR );
}
diff --git a/sw/source/uibase/docvw/srcedtw.cxx b/sw/source/uibase/docvw/srcedtw.cxx
index abbc045031ae..5d6a131bfcbb 100644
--- a/sw/source/uibase/docvw/srcedtw.cxx
+++ b/sw/source/uibase/docvw/srcedtw.cxx
@@ -988,7 +988,7 @@ void SwSrcEditWindow::SetFont()
//font height is stored in point and set in twip
aSize.Height() =
officecfg::Office::Common::Font::SourceViewFont::FontHeight::get() * 20;
- aFont.SetFontSize(m_pOutWin->LogicToPixel(aSize, MapUnit::MapTwip));
+ aFont.SetFontSize(m_pOutWin->LogicToPixel(aSize, MapMode(MapUnit::MapTwip)));
GetTextEngine()->SetFont( aFont );
m_pOutWin->SetFont(aFont);
}
diff --git a/sw/source/uibase/ribbar/workctrl.cxx b/sw/source/uibase/ribbar/workctrl.cxx
index 71eca1387699..fe285abb58bc 100644
--- a/sw/source/uibase/ribbar/workctrl.cxx
+++ b/sw/source/uibase/ribbar/workctrl.cxx
@@ -458,7 +458,7 @@ SwZoomBox_Impl::SwZoomBox_Impl(vcl::Window* pParent, sal_uInt16 nSlot)
, bRelease(true)
{
SetHelpId(HID_PVIEW_ZOOM_LB);
- SetSizePixel(LogicToPixel(Size(30, 86), MapUnit::MapAppFont));
+ SetSizePixel(LogicToPixel(Size(30, 86), MapMode(MapUnit::MapAppFont)));
EnableAutocomplete( false );
const char* const aZoomValues[] =
{ RID_SVXSTR_ZOOM_25 , RID_SVXSTR_ZOOM_50 ,
@@ -612,7 +612,7 @@ SwJumpToSpecificBox_Impl::SwJumpToSpecificBox_Impl(vcl::Window* pParent, sal_uIn
: NumericField(pParent, WB_HIDE | WB_BORDER)
, nSlotId(nSlot)
{
- SetSizePixel(LogicToPixel(Size(16, 12), MapUnit::MapAppFont));
+ SetSizePixel(LogicToPixel(Size(16, 12), MapMode(MapUnit::MapAppFont)));
}
void SwJumpToSpecificBox_Impl::Select()
diff --git a/sw/source/uibase/shells/grfshex.cxx b/sw/source/uibase/shells/grfshex.cxx
index a8f92194cbb9..1f8f9928a021 100644
--- a/sw/source/uibase/shells/grfshex.cxx
+++ b/sw/source/uibase/shells/grfshex.cxx
@@ -110,9 +110,9 @@ bool SwTextShell::InsertMediaDlg( SfxRequest const & rReq )
if( aPrefSize.Width() && aPrefSize.Height() )
{
if( pWindow )
- aSize = pWindow->PixelToLogic( aPrefSize, MapUnit::MapTwip );
+ aSize = pWindow->PixelToLogic(aPrefSize, MapMode(MapUnit::MapTwip));
else
- aSize = Application::GetDefaultDevice()->PixelToLogic( aPrefSize, MapUnit::MapTwip );
+ aSize = Application::GetDefaultDevice()->PixelToLogic(aPrefSize, MapMode(MapUnit::MapTwip));
}
else
aSize = Size( 2835, 2835 );
diff --git a/sw/source/uibase/table/chartins.cxx b/sw/source/uibase/table/chartins.cxx
index bc778aa90eea..283449964c5f 100644
--- a/sw/source/uibase/table/chartins.cxx
+++ b/sw/source/uibase/table/chartins.cxx
@@ -70,7 +70,7 @@ Point SwGetChartDialogPos( const vcl::Window *pParentWin, const Size& rDialogSiz
pParentWin->OutputToAbsoluteScreenPixel( aObjPixel.BottomRight() ) );
tools::Rectangle aDesktop = pParentWin->GetDesktopRectPixel();
- Size aSpace = pParentWin->LogicToPixel( Size( 8, 12 ), MapUnit::MapAppFont );
+ Size aSpace = pParentWin->LogicToPixel(Size(8, 12), MapMode(MapUnit::MapAppFont));
bool bLayoutRTL = ::GetActiveView()->GetWrtShell().IsTableRightToLeft();
bool bCenterHor = false;
diff --git a/sw/source/uibase/uiview/srcview.cxx b/sw/source/uibase/uiview/srcview.cxx
index 7988493a7579..0c0a78b628bd 100644
--- a/sw/source/uibase/uiview/srcview.cxx
+++ b/sw/source/uibase/uiview/srcview.cxx
@@ -683,10 +683,10 @@ sal_Int32 SwSrcView::PrintSource(
pOutDev->Push();
TextEngine* pTextEngine = aEditWin->GetTextEngine();
- pOutDev->SetMapMode( MapUnit::Map100thMM );
+ pOutDev->SetMapMode(MapMode(MapUnit::Map100thMM));
vcl::Font aFont( aEditWin->GetOutWin()->GetFont() );
Size aSize( aFont.GetFontSize() );
- aSize = aEditWin->GetOutWin()->PixelToLogic( aSize, MapUnit::Map100thMM );
+ aSize = aEditWin->GetOutWin()->PixelToLogic(aSize, MapMode(MapUnit::Map100thMM));
aFont.SetFontSize( aSize );
aFont.SetColor( COL_BLACK );
pOutDev->SetFont( aFont );
diff --git a/sw/source/uibase/uiview/viewdraw.cxx b/sw/source/uibase/uiview/viewdraw.cxx
index a85c8ffc2cc0..04cc5e8d57f2 100644
--- a/sw/source/uibase/uiview/viewdraw.cxx
+++ b/sw/source/uibase/uiview/viewdraw.cxx
@@ -176,9 +176,9 @@ void SwView::ExecDraw(SfxRequest& rReq)
if( aPrefSize.Width() && aPrefSize.Height() )
{
if( pWin )
- aSize = pWin->PixelToLogic( aPrefSize, MapUnit::MapTwip );
+ aSize = pWin->PixelToLogic(aPrefSize, MapMode(MapUnit::MapTwip));
else
- aSize = Application::GetDefaultDevice()->PixelToLogic( aPrefSize, MapUnit::MapTwip );
+ aSize = Application::GetDefaultDevice()->PixelToLogic(aPrefSize, MapMode(MapUnit::MapTwip));
}
else
aSize = Size( 2835, 2835 );
diff --git a/sw/source/uibase/uiview/viewport.cxx b/sw/source/uibase/uiview/viewport.cxx
index eb3bcbdd8ae3..cdad0962be46 100644
--- a/sw/source/uibase/uiview/viewport.cxx
+++ b/sw/source/uibase/uiview/viewport.cxx
@@ -953,7 +953,7 @@ void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize, bool )
Size aSize( rSize );
aSize.Width() -= (aBorder.Left() + aBorder.Right());
aSize.Height() -= (aBorder.Top() + aBorder.Bottom());
- Size aObjSizePixel = GetWindow()->LogicToPixel( aObjSize, MapUnit::MapTwip );
+ Size aObjSizePixel = GetWindow()->LogicToPixel(aObjSize, MapMode(MapUnit::MapTwip));
SfxViewShell::SetZoomFactor( Fraction( aSize.Width(), aObjSizePixel.Width() ),
Fraction( aSize.Height(), aObjSizePixel.Height() ) );
}
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx
index 4c932466493b..d690701a176f 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -897,7 +897,7 @@ void SwContentTree::dispose()
Size SwContentTree::GetOptimalSize() const
{
- return LogicToPixel(Size(110, 112), MapUnit::MapAppFont);
+ return LogicToPixel(Size(110, 112), MapMode(MapUnit::MapAppFont));
}
OUString SwContentTree::GetEntryAltText( SvTreeListEntry* pEntry ) const
diff --git a/sw/source/uibase/utlui/glbltree.cxx b/sw/source/uibase/utlui/glbltree.cxx
index 34f7ce07f756..17b29d4f1945 100644
--- a/sw/source/uibase/utlui/glbltree.cxx
+++ b/sw/source/uibase/utlui/glbltree.cxx
@@ -216,7 +216,7 @@ void SwGlobalTree::dispose()
Size SwGlobalTree::GetOptimalSize() const
{
- return LogicToPixel(Size(110, 112), MapUnit::MapAppFont);
+ return LogicToPixel(Size(110, 112), MapMode(MapUnit::MapAppFont));
}
sal_Int8 SwGlobalTree::ExecuteDrop( const ExecuteDropEvent& rEvt )
diff --git a/sw/source/uibase/utlui/shdwcrsr.cxx b/sw/source/uibase/utlui/shdwcrsr.cxx
index 40c6931482fd..8180141cafbb 100644
--- a/sw/source/uibase/utlui/shdwcrsr.cxx
+++ b/sw/source/uibase/utlui/shdwcrsr.cxx
@@ -73,7 +73,7 @@ void SwShadowCursor::DrawCursor( const Point& rPt, long nHeight, sal_uInt16 nMod
pWin->Push();
- pWin->SetMapMode( MapUnit::MapPixel );
+ pWin->SetMapMode(MapMode(MapUnit::MapPixel));
pWin->SetRasterOp( RasterOp::Xor );
pWin->SetLineColor( Color( aCol.GetColor() ^ COL_WHITE ) );
diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx
index 898cbf57ab7d..ac5debe9ec49 100644
--- a/sw/source/uibase/wrtsh/wrtsh1.cxx
+++ b/sw/source/uibase/wrtsh/wrtsh1.cxx
@@ -647,7 +647,7 @@ void SwWrtShell::CalcAndSetScale( svt::EmbeddedObjectRef& xObj,
MapUnit aUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( nAspect ) );
// TODO/LATER: needs complete VisArea?!
- Size aSize( OutputDevice::LogicToLogic( aRect.SVRect(), MapUnit::MapTwip, aUnit ).GetSize() );
+ Size aSize( OutputDevice::LogicToLogic(aRect.SVRect(), MapMode(MapUnit::MapTwip), MapMode(aUnit)).GetSize() );
awt::Size aSz;
aSz.Width = aSize.Width();
aSz.Height = aSize.Height();
@@ -752,7 +752,7 @@ void SwWrtShell::CalcAndSetScale( svt::EmbeddedObjectRef& xObj,
{
const MapMode aTmp( MapUnit::MapTwip );
MapUnit aUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( nAspect ) );
- _aVisArea = OutputDevice::LogicToLogic( _aVisArea, aUnit, aTmp);
+ _aVisArea = OutputDevice::LogicToLogic(_aVisArea, MapMode(aUnit), aTmp);
Size aObjArea;
if ( pFlyPrtRect )
aObjArea = pFlyPrtRect->SSize();