diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-09-20 16:41:39 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-10-05 06:51:20 +0000 |
commit | 954f752cf10fc6a8777af2a6a93e496688464687 (patch) | |
tree | 0fc776cdcb6ad9b1d2b9673ac044bb5b4f496972 /reportdesign/source/ui/misc/UITools.cxx | |
parent | c1e18e05a53c1d55afe36a887ca25f74f3f1d32d (diff) |
convert MapUnit to scoped enum
I left a prefix on the names "Map" so that I would not have to re-arrange
each name too much, since I can't start identifiers with digits like "100thMM"
And remove RSC_EXTRAMAPUNIT, which doesn't seem to be doing anything anymore.
Change-Id: I5187824aa87e30caf5357b51b5384b5ab919d224
Reviewed-on: https://gerrit.libreoffice.org/29096
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'reportdesign/source/ui/misc/UITools.cxx')
-rw-r--r-- | reportdesign/source/ui/misc/UITools.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/reportdesign/source/ui/misc/UITools.cxx b/reportdesign/source/ui/misc/UITools.cxx index 101b30173c7f..5ddd32dead06 100644 --- a/reportdesign/source/ui/misc/UITools.cxx +++ b/reportdesign/source/ui/misc/UITools.cxx @@ -239,7 +239,7 @@ namespace aFontItem.PutValue( uno::makeAny( aControlFont ), 0 ); _rItemSet.Put(aFontItem); - _rItemSet.Put(SvxFontHeightItem(OutputDevice::LogicToLogic(Size(0, (sal_Int32)aFont.GetFontHeight()), MAP_POINT, MAP_TWIP).Height(),100,_nFontHeight)); + _rItemSet.Put(SvxFontHeightItem(OutputDevice::LogicToLogic(Size(0, (sal_Int32)aFont.GetFontHeight()), MapUnit::MapPoint, MapUnit::MapTwip).Height(),100,_nFontHeight)); lang::Locale aLocale; switch(_nWhich) { @@ -390,7 +390,7 @@ namespace if ( SfxItemState::SET == _rItemSet.GetItemState( _nFontHeight,true,&pItem) && dynamic_cast< const SvxFontHeightItem *>( pItem ) != nullptr) { const SvxFontHeightItem* pFontItem = static_cast<const SvxFontHeightItem*>(pItem); - aNewFont.SetFontHeight(OutputDevice::LogicToLogic(Size(0, pFontItem->GetHeight()), MAP_TWIP, MAP_POINT).Height()); + aNewFont.SetFontHeight(OutputDevice::LogicToLogic(Size(0, pFontItem->GetHeight()), MapUnit::MapTwip, MapUnit::MapPoint).Height()); } if ( SfxItemState::SET == _rItemSet.GetItemState( _nPosture,true,&pItem) && dynamic_cast< const SvxPostureItem *>( pItem ) != nullptr) { @@ -703,7 +703,7 @@ bool openCharDialog( const uno::Reference<report::XReportControlFormat >& _rxRep }; SfxItemPool* pPool( new SfxItemPool(OUString("ReportCharProperties"), ITEMID_FONT,ITEMID_WEIGHT_COMPLEX, aItemInfos, pDefaults) ); - // not needed for font height pPool->SetDefaultMetric( MAP_100TH_MM ); // ripped, don't understand why + // not needed for font height pPool->SetDefaultMetric( MapUnit::Map100thMM ); // ripped, don't understand why pPool->FreezeIdRanges(); // the same bool bSuccess = false; try |