summaryrefslogtreecommitdiff
path: root/drawinglayer/source/primitive2d
diff options
context:
space:
mode:
Diffstat (limited to 'drawinglayer/source/primitive2d')
-rw-r--r--drawinglayer/source/primitive2d/controlprimitive2d.cxx6
-rw-r--r--drawinglayer/source/primitive2d/metafileprimitive2d.cxx20
-rw-r--r--drawinglayer/source/primitive2d/sceneprimitive2d.cxx2
3 files changed, 14 insertions, 14 deletions
diff --git a/drawinglayer/source/primitive2d/controlprimitive2d.cxx b/drawinglayer/source/primitive2d/controlprimitive2d.cxx
index 1367692b8f3c..6a62af0ad014 100644
--- a/drawinglayer/source/primitive2d/controlprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/controlprimitive2d.cxx
@@ -135,8 +135,8 @@ namespace drawinglayer
{ // #i93162# For painting the control setting a Zoom (using setZoom() at the xControlView)
// is needed to define the font size. Normally this is done in
// ViewObjectContactOfUnoControl::createPrimitive2DSequence by using positionControlForPaint().
- // For some reason the difference between MAP_TWIPS and MAP_100TH_MM still plays
- // a role there so that for Draw/Impress/Calc (the MAP_100TH_MM users) i need to set a zoom
+ // For some reason the difference between MapUnit::MapTwipS and MapUnit::Map100thMM still plays
+ // a role there so that for Draw/Impress/Calc (the MapUnit::Map100thMM users) i need to set a zoom
// here, too. The factor includes the needed scale, but is calculated by pure comparisons. It
// is somehow related to the twips/100thmm relationship.
bool bUserIs100thmm(false);
@@ -160,7 +160,7 @@ namespace drawinglayer
if(pWindow)
{
- if(MAP_100TH_MM == pWindow->GetMapMode().GetMapUnit())
+ if(MapUnit::Map100thMM == pWindow->GetMapMode().GetMapUnit())
{
bUserIs100thmm = true;
}
diff --git a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
index f83939a65cd4..de1c22bba9b0 100644
--- a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
@@ -104,7 +104,7 @@ namespace
public:
PropertyHolder()
: maTransformation(),
- maMapUnit(MAP_100TH_MM),
+ maMapUnit(MapUnit::Map100thMM),
maLineColor(),
maFillColor(),
maTextColor(COL_BLACK),
@@ -2661,14 +2661,14 @@ namespace
case MetaActionType::MAPMODE :
{
/** CHECKED, WORKS WELL */
- // the most necessary MapMode to be interpreted is MAP_RELATIVE,
+ // the most necessary MapMode to be interpreted is MapUnit::MapRelative,
// but also the others may occur. Even not yet supported ones
// may need to be added here later
const MetaMapModeAction* pA = static_cast<const MetaMapModeAction*>(pAction);
const MapMode& rMapMode = pA->GetMapMode();
basegfx::B2DHomMatrix aMapping;
- if(MAP_RELATIVE == rMapMode.GetMapUnit())
+ if(MapUnit::MapRelative == rMapMode.GetMapUnit())
{
aMapping = getTransformFromMapMode(rMapMode);
}
@@ -2676,21 +2676,21 @@ namespace
{
switch(rMapMode.GetMapUnit())
{
- case MAP_100TH_MM :
+ case MapUnit::Map100thMM :
{
- if(MAP_TWIP == rPropertyHolders.Current().getMapUnit())
+ if(MapUnit::MapTwip == rPropertyHolders.Current().getMapUnit())
{
- // MAP_TWIP -> MAP_100TH_MM
+ // MapUnit::MapTwip -> MapUnit::Map100thMM
const double fTwipTo100thMm(127.0 / 72.0);
aMapping.scale(fTwipTo100thMm, fTwipTo100thMm);
}
break;
}
- case MAP_TWIP :
+ case MapUnit::MapTwip :
{
- if(MAP_100TH_MM == rPropertyHolders.Current().getMapUnit())
+ if(MapUnit::Map100thMM == rPropertyHolders.Current().getMapUnit())
{
- // MAP_100TH_MM -> MAP_TWIP
+ // MapUnit::Map100thMM -> MapUnit::MapTwip
const double f100thMmToTwip(72.0 / 127.0);
aMapping.scale(f100thMmToTwip, f100thMmToTwip);
}
@@ -2733,7 +2733,7 @@ namespace
// convert to target MapUnit if not pixels
aFontSize = OutputDevice::LogicToLogic(
- aFontSize, MAP_PIXEL, rPropertyHolders.Current().getMapUnit());
+ aFontSize, MapUnit::MapPixel, rPropertyHolders.Current().getMapUnit());
aCorrectedFont.SetFontSize(aFontSize);
rPropertyHolders.Current().setFont(aCorrectedFont);
diff --git a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
index b87df2739280..d863d21eb7a5 100644
--- a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
@@ -124,7 +124,7 @@ namespace
aRetval = BitmapEx(aContent, aAlpha);
// #i101811# set PrefMapMode and PrefSize at newly created Bitmap
- aRetval.SetPrefMapMode(MAP_PIXEL);
+ aRetval.SetPrefMapMode(MapUnit::MapPixel);
aRetval.SetPrefSize(Size(nWidth, nHeight));
}