[Libreoffice-commits] core.git: 6 commits - dbaccess/source drawinglayer/source editeng/source framework/source include/tools include/vcl reportdesign/source rsc/inc rsc/source sd/source sfx2/source svtools/source svx/source sw/source toolkit/source vcl/source vcl/workben

Noel Grandin noel at peralex.com
Fri Jul 24 00:53:13 PDT 2015


 dbaccess/source/ui/control/opendoccontrols.cxx           |    2 
 drawinglayer/source/primitive2d/metafileprimitive2d.cxx  |    4 
 drawinglayer/source/primitive2d/wallpaperprimitive2d.cxx |   28 ++---
 editeng/source/items/frmitems.cxx                        |   50 ++++-----
 framework/source/layoutmanager/helpers.cxx               |   10 -
 framework/source/layoutmanager/toolbarlayoutmanager.cxx  |   20 +--
 framework/source/uielement/popuptoolbarcontroller.cxx    |    2 
 include/tools/wintypes.hxx                               |   12 +-
 include/vcl/splitwin.hxx                                 |    2 
 include/vcl/toolbox.hxx                                  |    2 
 include/vcl/wall.hxx                                     |   51 ++-------
 reportdesign/source/ui/report/DesignView.cxx             |    2 
 rsc/inc/rscdb.hxx                                        |    2 
 rsc/source/parser/rscicpx.cxx                            |    8 -
 sd/source/ui/app/optsitem.cxx                            |   31 +----
 sd/source/ui/dlg/dlgass.cxx                              |    2 
 sd/source/ui/dlg/navigatr.cxx                            |    3 
 sd/source/ui/inc/navigatr.hxx                            |    1 
 sd/source/ui/inc/optsitem.hxx                            |   14 --
 sfx2/source/dialog/backingwindow.cxx                     |    2 
 sfx2/source/dialog/splitwin.cxx                          |   28 ++---
 sfx2/source/doc/frmdescr.cxx                             |    2 
 sfx2/source/sidebar/SidebarController.cxx                |    8 -
 svtools/source/contnr/ivctrl.cxx                         |    4 
 svtools/source/dialogs/roadmapwizard.cxx                 |    2 
 svtools/source/dialogs/wizdlg.cxx                        |   26 ++--
 svx/source/form/fmshimp.cxx                              |   44 +++-----
 svx/source/inc/fmshimp.hxx                               |   23 +++-
 svx/source/mnuctrls/clipboardctl.cxx                     |    2 
 sw/source/ui/index/cnttab.cxx                            |    2 
 sw/source/uibase/ribbar/workctrl.cxx                     |    4 
 toolkit/source/awt/vclxwindows.cxx                       |    6 -
 toolkit/source/controls/unocontrolmodel.cxx              |    2 
 toolkit/source/helper/imagealign.cxx                     |   80 +++++++--------
 vcl/source/control/button.cxx                            |   78 +++++++-------
 vcl/source/control/morebtn.cxx                           |    2 
 vcl/source/gdi/pdfwriter_impl.cxx                        |   24 ++--
 vcl/source/gdi/wall.cxx                                  |   32 +++---
 vcl/source/outdev/outdevstate.cxx                        |    2 
 vcl/source/outdev/wallpaper.cxx                          |   26 ++--
 vcl/source/window/builder.cxx                            |    6 -
 vcl/source/window/dockingarea.cxx                        |   24 ++--
 vcl/source/window/menubarwindow.cxx                      |    6 -
 vcl/source/window/splitwin.cxx                           |   74 ++++++-------
 vcl/source/window/tabdlg.cxx                             |   10 -
 vcl/source/window/toolbox.cxx                            |   80 +++++++--------
 vcl/source/window/toolbox2.cxx                           |   10 -
 vcl/workben/vcldemo.cxx                                  |    2 
 48 files changed, 407 insertions(+), 450 deletions(-)

New commits:
commit 9582380ebc2dd241ee90951c3b28d420e140bcde
Author: Noel Grandin <noel at peralex.com>
Date:   Fri Jul 24 09:41:55 2015 +0200

    convert ImageAlign to enum class
    
    Change-Id: I22e2e66a1f0b230403ad1d9c1f5b7f34a6ee6ea5

diff --git a/dbaccess/source/ui/control/opendoccontrols.cxx b/dbaccess/source/ui/control/opendoccontrols.cxx
index 05d9480..35792db 100644
--- a/dbaccess/source/ui/control/opendoccontrols.cxx
+++ b/dbaccess/source/ui/control/opendoccontrols.cxx
@@ -177,7 +177,7 @@ namespace dbaui
         SetModeImage( GetCommandIcon( ".uno:Open", m_sModule ) );
         EnableImageDisplay( true );
         EnableTextDisplay( true );
-        SetImageAlign( IMAGEALIGN_LEFT );
+        SetImageAlign( ImageAlign::Left );
         SetStyle( GetStyle() | WB_CENTER );
     }
 
diff --git a/include/tools/wintypes.hxx b/include/tools/wintypes.hxx
index 01a04d9..781865d 100644
--- a/include/tools/wintypes.hxx
+++ b/include/tools/wintypes.hxx
@@ -287,10 +287,10 @@ WinBits const WB_EXT_DOCMODIFIED =      0x00000002;
 
 enum class WindowAlign { Left, Top, Right, Bottom };
 
-enum ImageAlign { IMAGEALIGN_LEFT, IMAGEALIGN_TOP, IMAGEALIGN_RIGHT, IMAGEALIGN_BOTTOM,
-                  IMAGEALIGN_LEFT_TOP, IMAGEALIGN_LEFT_BOTTOM, IMAGEALIGN_TOP_LEFT,
-                  IMAGEALIGN_TOP_RIGHT, IMAGEALIGN_RIGHT_TOP, IMAGEALIGN_RIGHT_BOTTOM,
-                  IMAGEALIGN_BOTTOM_LEFT, IMAGEALIGN_BOTTOM_RIGHT, IMAGEALIGN_CENTER };
+enum class ImageAlign { Left, Top, Right, Bottom,
+                  LeftTop, LeftBottom, TopLeft,
+                  TopRight, RightTop, RightBottom,
+                  BottomLeft, BottomRight, Center };
 
 enum class SymbolAlign { LEFT, RIGHT };
 
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index 3373ade..9a1f0c7 100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -418,7 +418,7 @@ AssistentDlgImpl::AssistentDlgImpl( vcl::Window* pWindow, const Link<>& rFinishL
         );
         mpPage1OpenPB->EnableImageDisplay(true);
         mpPage1OpenPB->EnableTextDisplay(true);
-        mpPage1OpenPB->SetImageAlign(IMAGEALIGN_LEFT);
+        mpPage1OpenPB->SetImageAlign(ImageAlign::Left);
         mpPage1OpenPB->SetStyle(mpPage1OpenPB->GetStyle() | WB_CENTER);
     }
 
diff --git a/toolkit/source/controls/unocontrolmodel.cxx b/toolkit/source/controls/unocontrolmodel.cxx
index c33e862..c3e2a9a 100644
--- a/toolkit/source/controls/unocontrolmodel.cxx
+++ b/toolkit/source/controls/unocontrolmodel.cxx
@@ -228,7 +228,7 @@ bool UnoControlModel::ImplHasProperty( sal_uInt16 nPropId ) const
             case BASEPROPERTY_DECIMALACCURACY:      aDefault <<= (sal_Int16) 2; break;
             case BASEPROPERTY_LINECOUNT:            aDefault <<= (sal_Int16) 5; break;
             case BASEPROPERTY_ALIGN:                aDefault <<= (sal_Int16) PROPERTY_ALIGN_LEFT; break;
-            case BASEPROPERTY_IMAGEALIGN:           aDefault <<= (sal_Int16) 1 /*ImageAlign::TOP*/; break;
+            case BASEPROPERTY_IMAGEALIGN:           aDefault <<= (sal_Int16) 1 /*ImageAlign::Top*/; break;
             case BASEPROPERTY_IMAGEPOSITION:        aDefault <<= (sal_Int16) 12 /*ImagePosition::Centered*/; break;
             case BASEPROPERTY_PUSHBUTTONTYPE:       aDefault <<= (sal_Int16) 0 /*PushButtonType::STANDARD*/; break;
             case BASEPROPERTY_MOUSE_WHEEL_BEHAVIOUR:aDefault <<= (sal_Int16) awt::MouseWheelBehavior::SCROLL_FOCUS_ONLY; break;
diff --git a/toolkit/source/helper/imagealign.cxx b/toolkit/source/helper/imagealign.cxx
index 75440a2..8f97ec4 100644
--- a/toolkit/source/helper/imagealign.cxx
+++ b/toolkit/source/helper/imagealign.cxx
@@ -34,19 +34,19 @@ namespace toolkit
         sal_Int16 nReturn = AboveCenter;
         switch ( _eVCLAlign )
         {
-        case IMAGEALIGN_LEFT:           nReturn = LeftCenter; break;
-        case IMAGEALIGN_TOP:            nReturn = AboveCenter;  break;
-        case IMAGEALIGN_RIGHT:          nReturn = RightCenter; break;
-        case IMAGEALIGN_BOTTOM:         nReturn = BelowCenter; break;
-        case IMAGEALIGN_LEFT_TOP:       nReturn = LeftTop; break;
-        case IMAGEALIGN_LEFT_BOTTOM:    nReturn = LeftBottom; break;
-        case IMAGEALIGN_TOP_LEFT:       nReturn = AboveLeft; break;
-        case IMAGEALIGN_TOP_RIGHT:      nReturn = AboveRight; break;
-        case IMAGEALIGN_RIGHT_TOP:      nReturn = RightTop; break;
-        case IMAGEALIGN_RIGHT_BOTTOM:   nReturn = RightBottom; break;
-        case IMAGEALIGN_BOTTOM_LEFT:    nReturn = BelowLeft; break;
-        case IMAGEALIGN_BOTTOM_RIGHT:   nReturn = BelowRight; break;
-        case IMAGEALIGN_CENTER:         nReturn = Centered; break;
+        case ImageAlign::Left:           nReturn = LeftCenter; break;
+        case ImageAlign::Top:            nReturn = AboveCenter;  break;
+        case ImageAlign::Right:          nReturn = RightCenter; break;
+        case ImageAlign::Bottom:         nReturn = BelowCenter; break;
+        case ImageAlign::LeftTop:       nReturn = LeftTop; break;
+        case ImageAlign::LeftBottom:    nReturn = LeftBottom; break;
+        case ImageAlign::TopLeft:       nReturn = AboveLeft; break;
+        case ImageAlign::TopRight:      nReturn = AboveRight; break;
+        case ImageAlign::RightTop:      nReturn = RightTop; break;
+        case ImageAlign::RightBottom:   nReturn = RightBottom; break;
+        case ImageAlign::BottomLeft:    nReturn = BelowLeft; break;
+        case ImageAlign::BottomRight:   nReturn = BelowRight; break;
+        case ImageAlign::Center:         nReturn = Centered; break;
         default:
             OSL_FAIL( "translateImagePosition: unknown IMAGEALIGN value!" );
         }
@@ -55,22 +55,22 @@ namespace toolkit
 
     ImageAlign translateImagePosition( sal_Int16 _eUNOAlign )
     {
-        ImageAlign nReturn = IMAGEALIGN_TOP;
+        ImageAlign nReturn = ImageAlign::Top;
         switch ( _eUNOAlign )
         {
-        case LeftCenter:  nReturn = IMAGEALIGN_LEFT; break;
-        case AboveCenter: nReturn = IMAGEALIGN_TOP;  break;
-        case RightCenter: nReturn = IMAGEALIGN_RIGHT; break;
-        case BelowCenter: nReturn = IMAGEALIGN_BOTTOM; break;
-        case LeftTop:     nReturn = IMAGEALIGN_LEFT_TOP; break;
-        case LeftBottom:  nReturn = IMAGEALIGN_LEFT_BOTTOM; break;
-        case AboveLeft:   nReturn = IMAGEALIGN_TOP_LEFT; break;
-        case AboveRight:  nReturn = IMAGEALIGN_TOP_RIGHT; break;
-        case RightTop:    nReturn = IMAGEALIGN_RIGHT_TOP; break;
-        case RightBottom: nReturn = IMAGEALIGN_RIGHT_BOTTOM; break;
-        case BelowLeft:   nReturn = IMAGEALIGN_BOTTOM_LEFT; break;
-        case BelowRight:  nReturn = IMAGEALIGN_BOTTOM_RIGHT; break;
-        case Centered:    nReturn = IMAGEALIGN_CENTER; break;
+        case LeftCenter:  nReturn = ImageAlign::Left; break;
+        case AboveCenter: nReturn = ImageAlign::Top;  break;
+        case RightCenter: nReturn = ImageAlign::Right; break;
+        case BelowCenter: nReturn = ImageAlign::Bottom; break;
+        case LeftTop:     nReturn = ImageAlign::LeftTop; break;
+        case LeftBottom:  nReturn = ImageAlign::LeftBottom; break;
+        case AboveLeft:   nReturn = ImageAlign::TopLeft; break;
+        case AboveRight:  nReturn = ImageAlign::TopRight; break;
+        case RightTop:    nReturn = ImageAlign::RightTop; break;
+        case RightBottom: nReturn = ImageAlign::RightBottom; break;
+        case BelowLeft:   nReturn = ImageAlign::BottomLeft; break;
+        case BelowRight:  nReturn = ImageAlign::BottomRight; break;
+        case Centered:    nReturn = ImageAlign::Center; break;
         default:
             OSL_FAIL( "translateImagePosition: unknown css.awt.ImagePosition value!" );
         }
@@ -82,23 +82,23 @@ namespace toolkit
         sal_Int16 nReturn = TOP;
         switch ( _eAlign )
         {
-        case IMAGEALIGN_LEFT_TOP:
-        case IMAGEALIGN_LEFT:
-        case IMAGEALIGN_LEFT_BOTTOM:    nReturn = LEFT; break;
+        case ImageAlign::LeftTop:
+        case ImageAlign::Left:
+        case ImageAlign::LeftBottom:    nReturn = LEFT; break;
 
-        case IMAGEALIGN_TOP_LEFT:
-        case IMAGEALIGN_TOP:
-        case IMAGEALIGN_TOP_RIGHT:      nReturn = TOP; break;
+        case ImageAlign::TopLeft:
+        case ImageAlign::Top:
+        case ImageAlign::TopRight:      nReturn = TOP; break;
 
-        case IMAGEALIGN_RIGHT_TOP:
-        case IMAGEALIGN_RIGHT:
-        case IMAGEALIGN_RIGHT_BOTTOM:   nReturn = RIGHT; break;
+        case ImageAlign::RightTop:
+        case ImageAlign::Right:
+        case ImageAlign::RightBottom:   nReturn = RIGHT; break;
 
-        case IMAGEALIGN_BOTTOM_LEFT:
-        case IMAGEALIGN_BOTTOM:
-        case IMAGEALIGN_BOTTOM_RIGHT:   nReturn = BOTTOM; break;
+        case ImageAlign::BottomLeft:
+        case ImageAlign::Bottom:
+        case ImageAlign::BottomRight:   nReturn = BOTTOM; break;
 
-        case IMAGEALIGN_CENTER:         nReturn = TOP; break;
+        case ImageAlign::Center:         nReturn = TOP; break;
         default:
             OSL_FAIL( "getCompatibleImageAlign: unknown IMAGEALIGN value!" );
         }
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index a106461..f5dd84c 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -82,7 +82,7 @@ public:
 };
 
 ImplCommonButtonData::ImplCommonButtonData() : maFocusRect(), mnSeparatorX(0), mnButtonState(DrawButtonFlags::NONE),
-mbSmallSymbol(false), maImage(), meImageAlign(IMAGEALIGN_TOP), meSymbolAlign(SymbolAlign::LEFT)
+mbSmallSymbol(false), maImage(), meImageAlign(ImageAlign::Top), meSymbolAlign(SymbolAlign::LEFT)
 {
 }
 
@@ -333,21 +333,21 @@ void Button::ImplDrawAlignedImage(OutputDevice* pDev, Point& rPos,
 
         if (bDrawText)
         {
-            if ((eImageAlign == IMAGEALIGN_LEFT_TOP)     ||
-                (eImageAlign == IMAGEALIGN_LEFT )        ||
-                (eImageAlign == IMAGEALIGN_LEFT_BOTTOM)  ||
-                (eImageAlign == IMAGEALIGN_RIGHT_TOP)    ||
-                (eImageAlign == IMAGEALIGN_RIGHT)        ||
-                (eImageAlign == IMAGEALIGN_RIGHT_BOTTOM))
+            if ((eImageAlign == ImageAlign::LeftTop)     ||
+                (eImageAlign == ImageAlign::Left )        ||
+                (eImageAlign == ImageAlign::LeftBottom)  ||
+                (eImageAlign == ImageAlign::RightTop)    ||
+                (eImageAlign == ImageAlign::Right)        ||
+                (eImageAlign == ImageAlign::RightBottom))
             {
                 aRect.Right() -= (aImageSize.Width() + nImageSep);
             }
-            else if ((eImageAlign == IMAGEALIGN_TOP_LEFT)    ||
-                     (eImageAlign == IMAGEALIGN_TOP)         ||
-                     (eImageAlign == IMAGEALIGN_TOP_RIGHT)   ||
-                     (eImageAlign == IMAGEALIGN_BOTTOM_LEFT) ||
-                     (eImageAlign == IMAGEALIGN_BOTTOM)      ||
-                     (eImageAlign == IMAGEALIGN_BOTTOM_RIGHT))
+            else if ((eImageAlign == ImageAlign::TopLeft)    ||
+                     (eImageAlign == ImageAlign::Top)         ||
+                     (eImageAlign == ImageAlign::TopRight)   ||
+                     (eImageAlign == ImageAlign::BottomLeft) ||
+                     (eImageAlign == ImageAlign::Bottom)      ||
+                     (eImageAlign == ImageAlign::BottomRight))
             {
                 aRect.Bottom() -= (aImageSize.Height() + nImageSep);
             }
@@ -373,56 +373,56 @@ void Button::ImplDrawAlignedImage(OutputDevice* pDev, Point& rPos,
 
         // Now calculate the output area for the image and the text according to the image align flags
 
-        if ((eImageAlign == IMAGEALIGN_LEFT) ||
-            (eImageAlign == IMAGEALIGN_RIGHT))
+        if ((eImageAlign == ImageAlign::Left) ||
+            (eImageAlign == ImageAlign::Right))
         {
             aImagePos.Y() = rPos.Y() + (aMax.Height() - aImageSize.Height()) / 2;
             aTextPos.Y()  = rPos.Y() + (aMax.Height() - aTSSize.Height()) / 2;
         }
-        else if ((eImageAlign == IMAGEALIGN_LEFT_BOTTOM) ||
-                 (eImageAlign == IMAGEALIGN_RIGHT_BOTTOM))
+        else if ((eImageAlign == ImageAlign::LeftBottom) ||
+                 (eImageAlign == ImageAlign::RightBottom))
         {
             aImagePos.Y() = rPos.Y() + aMax.Height() - aImageSize.Height();
             aTextPos.Y()  = rPos.Y() + aMax.Height() - aTSSize.Height();
         }
-        else if ((eImageAlign == IMAGEALIGN_TOP) ||
-                 (eImageAlign == IMAGEALIGN_BOTTOM))
+        else if ((eImageAlign == ImageAlign::Top) ||
+                 (eImageAlign == ImageAlign::Bottom))
         {
             aImagePos.X() = rPos.X() + (aMax.Width() - aImageSize.Width()) / 2;
             aTextPos.X()  = rPos.X() + (aMax.Width() - aTSSize.Width()) / 2;
         }
-        else if ((eImageAlign == IMAGEALIGN_TOP_RIGHT) ||
-                 (eImageAlign == IMAGEALIGN_BOTTOM_RIGHT))
+        else if ((eImageAlign == ImageAlign::TopRight) ||
+                 (eImageAlign == ImageAlign::BottomRight))
         {
             aImagePos.X() = rPos.X() + aMax.Width() - aImageSize.Width();
             aTextPos.X()  = rPos.X() + aMax.Width() - aTSSize.Width();
         }
 
-        if ((eImageAlign == IMAGEALIGN_LEFT_TOP) ||
-            (eImageAlign == IMAGEALIGN_LEFT)     ||
-            (eImageAlign == IMAGEALIGN_LEFT_BOTTOM))
+        if ((eImageAlign == ImageAlign::LeftTop) ||
+            (eImageAlign == ImageAlign::Left)     ||
+            (eImageAlign == ImageAlign::LeftBottom))
         {
             aTextPos.X() = rPos.X() + aImageSize.Width() + nImageSep;
         }
-        else if ((eImageAlign == IMAGEALIGN_RIGHT_TOP) ||
-                 (eImageAlign == IMAGEALIGN_RIGHT)     ||
-                 (eImageAlign == IMAGEALIGN_RIGHT_BOTTOM))
+        else if ((eImageAlign == ImageAlign::RightTop) ||
+                 (eImageAlign == ImageAlign::Right)     ||
+                 (eImageAlign == ImageAlign::RightBottom))
         {
             aImagePos.X() = rPos.X() + aTSSize.Width() + nImageSep;
         }
-        else if ((eImageAlign == IMAGEALIGN_TOP_LEFT) ||
-                 (eImageAlign == IMAGEALIGN_TOP)      ||
-                 (eImageAlign == IMAGEALIGN_TOP_RIGHT))
+        else if ((eImageAlign == ImageAlign::TopLeft) ||
+                 (eImageAlign == ImageAlign::Top)      ||
+                 (eImageAlign == ImageAlign::TopRight))
         {
             aTextPos.Y() = rPos.Y() + aImageSize.Height() + nImageSep;
         }
-        else if ((eImageAlign == IMAGEALIGN_BOTTOM_LEFT) ||
-                 (eImageAlign == IMAGEALIGN_BOTTOM)      ||
-                 (eImageAlign == IMAGEALIGN_BOTTOM_RIGHT))
+        else if ((eImageAlign == ImageAlign::BottomLeft) ||
+                 (eImageAlign == ImageAlign::Bottom)      ||
+                 (eImageAlign == ImageAlign::BottomRight))
         {
             aImagePos.Y() = rPos.Y() + aTSSize.Height() + nImageSep;
         }
-        else if (eImageAlign == IMAGEALIGN_CENTER)
+        else if (eImageAlign == ImageAlign::Center)
         {
             aImagePos.X() = rPos.X() + (aMax.Width()  - aImageSize.Width()) / 2;
             aImagePos.Y() = rPos.Y() + (aMax.Height() - aImageSize.Height()) / 2;
@@ -593,15 +593,15 @@ bool Button::set_property(const OString &rKey, const OString &rValue)
 {
     if (rKey == "image-position")
     {
-        ImageAlign eAlign = IMAGEALIGN_LEFT;
+        ImageAlign eAlign = ImageAlign::Left;
         if (rValue == "left")
-            eAlign = IMAGEALIGN_LEFT;
+            eAlign = ImageAlign::Left;
         else if (rValue == "right")
-            eAlign = IMAGEALIGN_RIGHT;
+            eAlign = ImageAlign::Right;
         else if (rValue == "top")
-            eAlign = IMAGEALIGN_TOP;
+            eAlign = ImageAlign::Top;
         else if (rValue == "bottom")
-            eAlign = IMAGEALIGN_BOTTOM;
+            eAlign = ImageAlign::Bottom;
         SetImageAlign(eAlign);
     }
     else
diff --git a/vcl/source/control/morebtn.cxx b/vcl/source/control/morebtn.cxx
index 999c3c3..ec91329 100644
--- a/vcl/source/control/morebtn.cxx
+++ b/vcl/source/control/morebtn.cxx
@@ -48,7 +48,7 @@ void MoreButton::ImplInit( vcl::Window* pParent, WinBits nStyle )
     ShowState();
 
     SetSymbolAlign(SymbolAlign::RIGHT);
-    SetImageAlign(IMAGEALIGN_RIGHT); //Resoves: fdo#31849 ensure button remains vertically centered
+    SetImageAlign(ImageAlign::Right); //Resoves: fdo#31849 ensure button remains vertically centered
     SetSmallSymbol(true);
 
     if ( ! ( nStyle & ( WB_RIGHT | WB_LEFT ) ) )
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 9a5a5b5..f16d439 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -1375,7 +1375,7 @@ VclPtr<vcl::Window> VclBuilder::makeObject(vcl::Window *pParent, const OString &
             xButton = extractStockAndBuildMenuButton(pParent, rMap);
             m_pParserState->m_aButtonMenuMaps.push_back(ButtonMenuMap(id, sMenu));
         }
-        xButton->SetImageAlign(IMAGEALIGN_LEFT); //default to left
+        xButton->SetImageAlign(ImageAlign::Left); //default to left
         setupFromActionName(xButton, rMap, m_xFrame);
         xWindow = xButton;
     }
@@ -1387,7 +1387,7 @@ VclPtr<vcl::Window> VclBuilder::makeObject(vcl::Window *pParent, const OString &
         if (!sWrap.isEmpty())
             nBits |= WB_WORDBREAK;
         VclPtr<RadioButton> xButton = VclPtr<RadioButton>::Create(pParent, nBits);
-        xButton->SetImageAlign(IMAGEALIGN_LEFT); //default to left
+        xButton->SetImageAlign(ImageAlign::Left); //default to left
         xWindow = xButton;
     }
     else if (name == "GtkCheckButton")
@@ -1405,7 +1405,7 @@ VclPtr<vcl::Window> VclBuilder::makeObject(vcl::Window *pParent, const OString &
             xCheckBox = VclPtr<CheckBox>::Create(pParent, nBits);
         if (bIsTriState)
             xCheckBox->SetState(TRISTATE_INDET);
-        xCheckBox->SetImageAlign(IMAGEALIGN_LEFT); //default to left
+        xCheckBox->SetImageAlign(ImageAlign::Left); //default to left
         xWindow = xCheckBox;
     }
     else if (name == "GtkSpinButton")
commit 9e28cc8ca79b5c42955867a62e89faf8facc5e80
Author: Noel Grandin <noel at peralex.com>
Date:   Thu Jul 23 13:19:40 2015 +0200

    convert WindowAlign to scoped enum
    
    Change-Id: I028d108b3a83bd5541d873c4d03b87339cd3be52

diff --git a/framework/source/layoutmanager/helpers.cxx b/framework/source/layoutmanager/helpers.cxx
index 527eeeb..6ea1c83 100644
--- a/framework/source/layoutmanager/helpers.cxx
+++ b/framework/source/layoutmanager/helpers.cxx
@@ -64,7 +64,7 @@ bool isReverseOrderDockingArea( const sal_Int32 nDockArea )
 bool isToolboxHorizontalAligned( ToolBox* pToolBox )
 {
     if ( pToolBox )
-        return (( pToolBox->GetAlign() == WINDOWALIGN_TOP ) || ( pToolBox->GetAlign() == WINDOWALIGN_BOTTOM ));
+        return (( pToolBox->GetAlign() == WindowAlign::Top ) || ( pToolBox->GetAlign() == WindowAlign::Bottom ));
     return false;
 }
 
@@ -184,13 +184,13 @@ uno::Reference< awt::XWindowPeer > createToolkitWindow( const uno::Reference< un
 WindowAlign ImplConvertAlignment( sal_Int16 aAlignment )
 {
     if ( aAlignment == ui::DockingArea_DOCKINGAREA_LEFT )
-        return WINDOWALIGN_LEFT;
+        return WindowAlign::Left;
     else if ( aAlignment == ui::DockingArea_DOCKINGAREA_RIGHT )
-        return WINDOWALIGN_RIGHT;
+        return WindowAlign::Right;
     else if ( aAlignment == ui::DockingArea_DOCKINGAREA_TOP )
-        return WINDOWALIGN_TOP;
+        return WindowAlign::Top;
     else
-        return WINDOWALIGN_BOTTOM;
+        return WindowAlign::Bottom;
 }
 
 OUString getElementTypeFromResourceURL( const OUString& aResourceURL )
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.cxx b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
index 40a62d9..6eb25c0 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.cxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
@@ -1032,13 +1032,13 @@ void ToolbarLayoutManager::setParentWindow(
     {
         SolarMutexGuard aGuard;
         VclPtr< ::DockingAreaWindow > pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xTopDockWindow ).get() );
-        if( pWindow ) pWindow->SetAlign( WINDOWALIGN_TOP );
+        if( pWindow ) pWindow->SetAlign( WindowAlign::Top );
         pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xBottomDockWindow ).get() );
-        if( pWindow ) pWindow->SetAlign( WINDOWALIGN_BOTTOM );
+        if( pWindow ) pWindow->SetAlign( WindowAlign::Bottom );
         pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xLeftDockWindow ).get() );
-        if( pWindow ) pWindow->SetAlign( WINDOWALIGN_LEFT );
+        if( pWindow ) pWindow->SetAlign( WindowAlign::Left );
         pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xRightDockWindow ).get() );
-        if( pWindow ) pWindow->SetAlign( WINDOWALIGN_RIGHT );
+        if( pWindow ) pWindow->SetAlign( WindowAlign::Right );
         implts_reparentToolbars();
     }
     else
@@ -3540,9 +3540,9 @@ throw (uno::RuntimeException, std::exception)
             if( e.bFloating )
             {
                 if ( aUIDockingElement.m_aFloatingData.m_bIsHorizontal )
-                    pToolBox->SetAlign( WINDOWALIGN_TOP );
+                    pToolBox->SetAlign( WindowAlign::Top );
                 else
-                    pToolBox->SetAlign( WINDOWALIGN_LEFT );
+                    pToolBox->SetAlign( WindowAlign::Left );
             }
             else
             {
@@ -3655,9 +3655,9 @@ throw (uno::RuntimeException, std::exception)
                 {
                     pToolBox->SetLineCount( aUIDockingElement.m_aFloatingData.m_nLines );
                     if ( aUIDockingElement.m_aFloatingData.m_bIsHorizontal )
-                        pToolBox->SetAlign( WINDOWALIGN_TOP );
+                        pToolBox->SetAlign( WindowAlign::Top );
                     else
-                        pToolBox->SetAlign( WINDOWALIGN_LEFT );
+                        pToolBox->SetAlign( WindowAlign::Left );
                 }
 
                 bool bUndefPos = hasDefaultPosValue( aUIDockingElement.m_aFloatingData.m_aPos );
@@ -3734,9 +3734,9 @@ throw (uno::RuntimeException, std::exception)
             if ( aUIDockingElement.m_bFloating )
             {
                 if ( aUIDockingElement.m_aFloatingData.m_bIsHorizontal )
-                    pToolBox->SetAlign( WINDOWALIGN_TOP );
+                    pToolBox->SetAlign( WindowAlign::Top );
                 else
-                    pToolBox->SetAlign( WINDOWALIGN_LEFT );
+                    pToolBox->SetAlign( WindowAlign::Left );
             }
             else
                 pToolBox->SetAlign( ImplConvertAlignment( aUIDockingElement.m_aDockedData.m_nDockedArea) );
diff --git a/framework/source/uielement/popuptoolbarcontroller.cxx b/framework/source/uielement/popuptoolbarcontroller.cxx
index d2e9da8..aa52908 100644
--- a/framework/source/uielement/popuptoolbarcontroller.cxx
+++ b/framework/source/uielement/popuptoolbarcontroller.cxx
@@ -190,7 +190,7 @@ PopupMenuToolbarController::createPopupWindow()
     sal_uInt16 nId = m_xPopupMenu->execute(
         css::uno::Reference< css::awt::XWindowPeer >( getParent(), css::uno::UNO_QUERY ),
         VCLUnoHelper::ConvertToAWTRect( pToolBox->GetItemRect( m_nToolBoxId ) ),
-        ( eAlign == WINDOWALIGN_TOP || eAlign == WINDOWALIGN_BOTTOM ) ?
+        ( eAlign == WindowAlign::Top || eAlign == WindowAlign::Bottom ) ?
             css::awt::PopupMenuDirection::EXECUTE_DOWN :
             css::awt::PopupMenuDirection::EXECUTE_RIGHT );
     pToolBox->SetItemDown( m_nToolBoxId, false );
diff --git a/include/tools/wintypes.hxx b/include/tools/wintypes.hxx
index bfd038e..01a04d9 100644
--- a/include/tools/wintypes.hxx
+++ b/include/tools/wintypes.hxx
@@ -285,11 +285,13 @@ WinBits const WB_EXT_DOCMODIFIED =      0x00000002;
 
 // WindowAlign
 
-enum WindowAlign { WINDOWALIGN_LEFT, WINDOWALIGN_TOP, WINDOWALIGN_RIGHT, WINDOWALIGN_BOTTOM };
+enum class WindowAlign { Left, Top, Right, Bottom };
+
 enum ImageAlign { IMAGEALIGN_LEFT, IMAGEALIGN_TOP, IMAGEALIGN_RIGHT, IMAGEALIGN_BOTTOM,
                   IMAGEALIGN_LEFT_TOP, IMAGEALIGN_LEFT_BOTTOM, IMAGEALIGN_TOP_LEFT,
                   IMAGEALIGN_TOP_RIGHT, IMAGEALIGN_RIGHT_TOP, IMAGEALIGN_RIGHT_BOTTOM,
                   IMAGEALIGN_BOTTOM_LEFT, IMAGEALIGN_BOTTOM_RIGHT, IMAGEALIGN_CENTER };
+
 enum class SymbolAlign { LEFT, RIGHT };
 
 // ButtonDialog-Types
diff --git a/include/vcl/splitwin.hxx b/include/vcl/splitwin.hxx
index 8918d42..5a2711a 100644
--- a/include/vcl/splitwin.hxx
+++ b/include/vcl/splitwin.hxx
@@ -184,7 +184,7 @@ public:
     sal_uInt16          GetItemCount( sal_uInt16 nSetId = 0 ) const;
     bool                IsItemValid( sal_uInt16 nId ) const;
 
-    void                SetAlign( WindowAlign eNewAlign = WINDOWALIGN_TOP );
+    void                SetAlign( WindowAlign eNewAlign = WindowAlign::Top );
     WindowAlign         GetAlign() const { return meAlign; }
     bool                IsHorizontal() const { return mbHorz; }
 
diff --git a/include/vcl/toolbox.hxx b/include/vcl/toolbox.hxx
index f0541cd..bda8d0b 100644
--- a/include/vcl/toolbox.hxx
+++ b/include/vcl/toolbox.hxx
@@ -352,7 +352,7 @@ public:
     void                SetToolboxButtonSize( ToolBoxButtonSize eSize );
     ToolBoxButtonSize   GetToolboxButtonSize() const;
 
-    void                SetAlign( WindowAlign eNewAlign = WINDOWALIGN_TOP );
+    void                SetAlign( WindowAlign eNewAlign = WindowAlign::Top );
     WindowAlign         GetAlign() const { return meAlign; }
     bool                IsHorizontal() const { return mbHorz; }
 
diff --git a/reportdesign/source/ui/report/DesignView.cxx b/reportdesign/source/ui/report/DesignView.cxx
index e438588..a12453e 100644
--- a/reportdesign/source/ui/report/DesignView.cxx
+++ b/reportdesign/source/ui/report/DesignView.cxx
@@ -114,7 +114,7 @@ ODesignView::ODesignView(   vcl::Window* pParent,
     // Splitter einrichten
     m_aSplitWin->SetSplitHdl(LINK(this, ODesignView,SplitHdl));
     m_aSplitWin->ShowAutoHideButton();
-    m_aSplitWin->SetAlign(WINDOWALIGN_LEFT);
+    m_aSplitWin->SetAlign(WindowAlign::Left);
     m_aSplitWin->Show();
 
     m_aMarkIdle.SetPriority( SchedulerPriority::LOW );
diff --git a/rsc/inc/rscdb.hxx b/rsc/inc/rscdb.hxx
index 7428785..bbaa74d 100644
--- a/rsc/inc/rscdb.hxx
+++ b/rsc/inc/rscdb.hxx
@@ -43,6 +43,7 @@ enum class KeyFuncType : sal_Int32;
 enum class MenuItemBits : sal_Int16;
 enum class ToolBoxItemType;
 enum class ButtonType;
+enum class WindowAlign;
 
 struct WriteRcContext
 {
@@ -155,6 +156,7 @@ class RscTypCont
     inline void SETCONST( RscConst *p1, const char * p2, ToolBoxItemType p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
     inline void SETCONST( RscConst *p1, Atom p2, ButtonType p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
     inline void SETCONST( RscConst *p1, const char * p2, ButtonType p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
+    inline void SETCONST( RscConst *p1, const char * p2, WindowAlign p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
     RscEnum *   InitLangType();
     RscEnum *   InitFieldUnitsType();
     RscEnum *   InitColor();
diff --git a/rsc/source/parser/rscicpx.cxx b/rsc/source/parser/rscicpx.cxx
index 0d23d0b..03fe7be 100644
--- a/rsc/source/parser/rscicpx.cxx
+++ b/rsc/source/parser/rscicpx.cxx
@@ -1251,10 +1251,10 @@ RscTop * RscTypCont::InitClassToolBox( RscTop * pSuper,
         RscEnum   * pEnum;
 
         aBaseLst.push_back( pEnum = new RscEnum( pHS->getID( "EnumToolBoxAlign" ), RSC_NOTYPE ) );
-        SETCONST( pEnum, "BOXALIGN_TOP",                WINDOWALIGN_TOP );
-        SETCONST( pEnum, "BOXALIGN_LEFT",               WINDOWALIGN_LEFT );
-        SETCONST( pEnum, "BOXALIGN_RIGHT",              WINDOWALIGN_RIGHT );
-        SETCONST( pEnum, "BOXALIGN_BOTTOM",             WINDOWALIGN_BOTTOM );
+        SETCONST( pEnum, "BOXALIGN_TOP",                WindowAlign::Top );
+        SETCONST( pEnum, "BOXALIGN_LEFT",               WindowAlign::Left );
+        SETCONST( pEnum, "BOXALIGN_RIGHT",              WindowAlign::Right );
+        SETCONST( pEnum, "BOXALIGN_BOTTOM",             WindowAlign::Bottom );
 
         // Variable einfuegen
         nId = aNmTb.Put( "Align", VARNAME );
diff --git a/sfx2/source/dialog/splitwin.cxx b/sfx2/source/dialog/splitwin.cxx
index 077dbe3..3b2ea78 100644
--- a/sfx2/source/dialog/splitwin.cxx
+++ b/sfx2/source/dialog/splitwin.cxx
@@ -135,12 +135,12 @@ void SfxEmptySplitWin_Impl::Actualize()
     Size aSize( pOwner->GetSizePixel() );
     switch ( pOwner->GetAlign() )
     {
-        case WINDOWALIGN_LEFT:
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Left:
+        case WindowAlign::Right:
             aSize.Width() = GetFadeInSize();
             break;
-        case WINDOWALIGN_TOP:
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Top:
+        case WindowAlign::Bottom:
             aSize.Height() = GetFadeInSize();
             break;
     }
@@ -219,20 +219,20 @@ SfxSplitWindow::SfxSplitWindow( vcl::Window* pParent, SfxChildAlignment eAl,
     switch ( eAlign )
     {
         case SfxChildAlignment::LEFT:
-            eTbxAlign = WINDOWALIGN_LEFT;
+            eTbxAlign = WindowAlign::Left;
             break;
         case SfxChildAlignment::RIGHT:
-            eTbxAlign = WINDOWALIGN_RIGHT;
+            eTbxAlign = WindowAlign::Right;
             break;
         case SfxChildAlignment::TOP:
-            eTbxAlign = WINDOWALIGN_TOP;
+            eTbxAlign = WindowAlign::Top;
             break;
         case SfxChildAlignment::BOTTOM:
-            eTbxAlign = WINDOWALIGN_BOTTOM;
+            eTbxAlign = WindowAlign::Bottom;
             bPinned = true;
             break;
         default:
-            eTbxAlign = WINDOWALIGN_TOP;  // some sort of default...
+            eTbxAlign = WindowAlign::Top;  // some sort of default...
             break;  // -Wall lots not handled..
     }
 
@@ -379,12 +379,12 @@ void SfxSplitWindow::StartSplit()
     Rectangle aRect = pWorkWin->GetFreeArea( !bPinned );
     switch ( GetAlign() )
     {
-        case WINDOWALIGN_LEFT:
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Left:
+        case WindowAlign::Right:
             nSize = aSize.Width() + aRect.GetWidth();
             break;
-        case WINDOWALIGN_TOP:
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Top:
+        case WindowAlign::Bottom:
             nSize = aSize.Height() + aRect.GetHeight();
             break;
     }
@@ -714,7 +714,7 @@ void SfxSplitWindow::InsertWindow_Impl( SfxDock_Impl* pDock,
 
         // Create a new nLine:th line
         SplitWindowItemFlags nBits = nItemBits;
-        if ( GetAlign() == WINDOWALIGN_TOP || GetAlign() == WINDOWALIGN_BOTTOM )
+        if ( GetAlign() == WindowAlign::Top || GetAlign() == WindowAlign::Bottom )
             nBits |= SplitWindowItemFlags::ColSet;
         InsertItem( nId, nSetSize, nLine, 0, nBits );
     }
diff --git a/sfx2/source/sidebar/SidebarController.cxx b/sfx2/source/sidebar/SidebarController.cxx
index 2d86f65..9bdd5e0 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -349,9 +349,9 @@ void SidebarController::NotifyResize()
     if (mpCurrentDeck)
     {
         SfxSplitWindow* pSplitWindow = GetSplitWindow();
-        WindowAlign eAlign = pSplitWindow ? pSplitWindow->GetAlign() : WINDOWALIGN_RIGHT;
+        WindowAlign eAlign = pSplitWindow ? pSplitWindow->GetAlign() : WindowAlign::Right;
         long nDeckX, nTabX;
-        if (eAlign == WINDOWALIGN_LEFT)     // attach the Sidebar towards the left-side of screen
+        if (eAlign == WindowAlign::Left)     // attach the Sidebar towards the left-side of screen
         {
             nDeckX = nTabBarDefaultWidth;
             nTabX = 0;
@@ -683,9 +683,9 @@ void SidebarController::SwitchToDeck (
 
     SfxSplitWindow* pSplitWindow = GetSplitWindow();
     sal_Int32 nTabBarDefaultWidth = TabBar::GetDefaultWidth() * mpTabBar->GetDPIScaleFactor();
-    WindowAlign eAlign = pSplitWindow ? pSplitWindow->GetAlign() : WINDOWALIGN_RIGHT;
+    WindowAlign eAlign = pSplitWindow ? pSplitWindow->GetAlign() : WindowAlign::Right;
     long nDeckX;
-    if (eAlign == WINDOWALIGN_LEFT)     // attach the Sidebar towards the left-side of screen
+    if (eAlign == WindowAlign::Left)     // attach the Sidebar towards the left-side of screen
     {
         nDeckX = nTabBarDefaultWidth;
     }
diff --git a/svtools/source/dialogs/roadmapwizard.cxx b/svtools/source/dialogs/roadmapwizard.cxx
index e6399790..1fae0a9 100644
--- a/svtools/source/dialogs/roadmapwizard.cxx
+++ b/svtools/source/dialogs/roadmapwizard.cxx
@@ -140,7 +140,7 @@ namespace svt
         m_pImpl->pRoadmap->SetSizePixel( aRoadmapSize );
 
         SetViewWindow( m_pImpl->pRoadmap );
-        SetViewAlign( WINDOWALIGN_LEFT );
+        SetViewAlign( WindowAlign::Left );
         m_pImpl->pRoadmap->Show();
     }
 
diff --git a/svtools/source/dialogs/wizdlg.cxx b/svtools/source/dialogs/wizdlg.cxx
index 39d6390..b35b901 100644
--- a/svtools/source/dialogs/wizdlg.cxx
+++ b/svtools/source/dialogs/wizdlg.cxx
@@ -57,7 +57,7 @@ void WizardDialog::ImplInitData()
     mpNextBtn       = NULL;
     mpViewWindow    = NULL;
     mnCurLevel      = 0;
-    meViewAlign     = WINDOWALIGN_LEFT;
+    meViewAlign     = WindowAlign::Left;
     mbEmptyViewMargin =  false;
     mnLeftAlignCount = 0;
 
@@ -100,13 +100,13 @@ void WizardDialog::ImplCalcSize( Size& rSize )
     if ( mpViewWindow && mpViewWindow->IsVisible() )
     {
         Size aViewSize = mpViewWindow->GetSizePixel();
-        if ( meViewAlign == WINDOWALIGN_TOP )
+        if ( meViewAlign == WindowAlign::Top )
             rSize.Height() += aViewSize.Height();
-        else if ( meViewAlign == WINDOWALIGN_LEFT )
+        else if ( meViewAlign == WindowAlign::Left )
             rSize.Width() += aViewSize.Width();
-        else if ( meViewAlign == WINDOWALIGN_BOTTOM )
+        else if ( meViewAlign == WindowAlign::Bottom )
             rSize.Height() += aViewSize.Height();
-        else if ( meViewAlign == WINDOWALIGN_RIGHT )
+        else if ( meViewAlign == WindowAlign::Right )
             rSize.Width() += aViewSize.Width();
     }
 }
@@ -196,14 +196,14 @@ void WizardDialog::ImplPosCtrls()
         long    nViewHeight = 0;
         long    nDlgHeight = nOffY;
         PosSizeFlags nViewPosFlags = PosSizeFlags::Pos;
-        if ( meViewAlign == WINDOWALIGN_TOP )
+        if ( meViewAlign == WindowAlign::Top )
         {
             nViewOffX       = WIZARDDIALOG_VIEW_DLGOFFSET_X;
             nViewOffY       = WIZARDDIALOG_VIEW_DLGOFFSET_Y;
             nViewWidth      = aDlgSize.Width()-(WIZARDDIALOG_VIEW_DLGOFFSET_X*2);
             nViewPosFlags  |= PosSizeFlags::Width;
         }
-        else if ( meViewAlign == WINDOWALIGN_LEFT )
+        else if ( meViewAlign == WindowAlign::Left )
         {
             if ( mbEmptyViewMargin )
             {
@@ -219,14 +219,14 @@ void WizardDialog::ImplPosCtrls()
             }
             nViewPosFlags  |= PosSizeFlags::Height;
         }
-        else if ( meViewAlign == WINDOWALIGN_BOTTOM )
+        else if ( meViewAlign == WindowAlign::Bottom )
         {
             nViewOffX       = WIZARDDIALOG_VIEW_DLGOFFSET_X;
             nViewOffY       = nDlgHeight-mpViewWindow->GetSizePixel().Height()-WIZARDDIALOG_VIEW_DLGOFFSET_Y;
             nViewWidth      = aDlgSize.Width()-(WIZARDDIALOG_VIEW_DLGOFFSET_X*2);
             nViewPosFlags  |= PosSizeFlags::Width;
         }
-        else if ( meViewAlign == WINDOWALIGN_RIGHT )
+        else if ( meViewAlign == WindowAlign::Right )
         {
             nViewOffX       = aDlgSize.Width()-mpViewWindow->GetSizePixel().Width()-WIZARDDIALOG_VIEW_DLGOFFSET_X;
             nViewOffY       = WIZARDDIALOG_VIEW_DLGOFFSET_Y;
@@ -283,20 +283,20 @@ void WizardDialog::ImplPosTabPage()
     if ( mpViewWindow && mpViewWindow->IsVisible() )
     {
         Size aViewSize = mpViewWindow->GetSizePixel();
-        if ( meViewAlign == WINDOWALIGN_TOP )
+        if ( meViewAlign == WindowAlign::Top )
         {
             nOffY += aViewSize.Height()+WIZARDDIALOG_VIEW_DLGOFFSET_Y;
             aDlgSize.Height() -= aViewSize.Height()+WIZARDDIALOG_VIEW_DLGOFFSET_Y;
         }
-        else if ( meViewAlign == WINDOWALIGN_LEFT )
+        else if ( meViewAlign == WindowAlign::Left )
         {
             long nViewOffset = mbEmptyViewMargin ? 0 : WIZARDDIALOG_VIEW_DLGOFFSET_X;
             nOffX += aViewSize.Width() + nViewOffset;
             aDlgSize.Width() -= nOffX;
         }
-        else if ( meViewAlign == WINDOWALIGN_BOTTOM )
+        else if ( meViewAlign == WindowAlign::Bottom )
             aDlgSize.Height() -= aViewSize.Height()+WIZARDDIALOG_VIEW_DLGOFFSET_Y;
-        else if ( meViewAlign == WINDOWALIGN_RIGHT )
+        else if ( meViewAlign == WindowAlign::Right )
             aDlgSize.Width() -= aViewSize.Width()+WIZARDDIALOG_VIEW_DLGOFFSET_X;
     }
     Point aPos( nOffX, nOffY );
diff --git a/svx/source/mnuctrls/clipboardctl.cxx b/svx/source/mnuctrls/clipboardctl.cxx
index a76ece6..e085c20 100644
--- a/svx/source/mnuctrls/clipboardctl.cxx
+++ b/svx/source/mnuctrls/clipboardctl.cxx
@@ -86,7 +86,7 @@ VclPtr<SfxPopupWindow> SvxClipBoardControl::CreatePopupWindow()
         rBox.SetItemDown( nId, true );
 
         pPopup->Execute( &rBox, rBox.GetItemRect( nId ),
-            (rBox.GetAlign() == WINDOWALIGN_TOP || rBox.GetAlign() == WINDOWALIGN_BOTTOM) ?
+            (rBox.GetAlign() == WindowAlign::Top || rBox.GetAlign() == WindowAlign::Bottom) ?
                 PopupMenuFlags::ExecuteDown : PopupMenuFlags::ExecuteRight );
 
         rBox.SetItemDown( nId, false );
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index 4faab6b..635127f 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -312,7 +312,7 @@ SwMultiTOXTabDialog::SwMultiTOXTabDialog(vcl::Window* pParent, const SfxItemSet&
     m_pShowExampleCB->Check( SW_MOD()->GetModuleConfig()->IsShowIndexPreview());
 
     m_pExampleContainerWIN->SetAccessibleName(m_pShowExampleCB->GetText());
-    SetViewAlign( WINDOWALIGN_LEFT );
+    SetViewAlign( WindowAlign::Left );
     // SetViewWindow does not work if the dialog is visible!
 
     if(!m_pShowExampleCB->IsChecked())
diff --git a/sw/source/uibase/ribbar/workctrl.cxx b/sw/source/uibase/ribbar/workctrl.cxx
index 8370f4f..81f5462 100644
--- a/sw/source/uibase/ribbar/workctrl.cxx
+++ b/sw/source/uibase/ribbar/workctrl.cxx
@@ -121,7 +121,7 @@ VclPtr<SfxPopupWindow> SwTbxAutoTextCtrl::CreatePopupWindow()
         pToolBox->SetItemDown( nId, true );
 
         pPopup->Execute( pToolBox, pToolBox->GetItemRect( nId ),
-            (pToolBox->GetAlign() == WINDOWALIGN_TOP || pToolBox->GetAlign() == WINDOWALIGN_BOTTOM) ?
+            (pToolBox->GetAlign() == WindowAlign::Top || pToolBox->GetAlign() == WindowAlign::Bottom) ?
                 PopupMenuFlags::ExecuteDown : PopupMenuFlags::ExecuteRight );
 
         pToolBox->SetItemDown( nId, false );
@@ -213,7 +213,7 @@ VclPtr<SfxPopupWindow> SwTbxFieldCtrl::CreatePopupWindow()
         pToolBox->SetItemDown( nId, true );
 
         pPopup->Execute( pToolBox, pToolBox->GetItemRect( nId ),
-                (pToolBox->GetAlign() == WINDOWALIGN_TOP || pToolBox->GetAlign() == WINDOWALIGN_BOTTOM) ?
+                (pToolBox->GetAlign() == WindowAlign::Top || pToolBox->GetAlign() == WindowAlign::Bottom) ?
                  PopupMenuFlags::ExecuteDown : PopupMenuFlags::ExecuteRight );
 
         pToolBox->SetItemDown( nId, false );
diff --git a/vcl/source/window/dockingarea.cxx b/vcl/source/window/dockingarea.cxx
index e847685..4cb8b00 100644
--- a/vcl/source/window/dockingarea.cxx
+++ b/vcl/source/window/dockingarea.cxx
@@ -37,7 +37,7 @@ public:
 
 DockingAreaWindow::ImplData::ImplData()
 {
-    meAlign = WINDOWALIGN_TOP;
+    meAlign = WindowAlign::Top;
 }
 
 DockingAreaWindow::ImplData::~ImplData()
@@ -78,7 +78,7 @@ static void ImplInvalidateMenubar( DockingAreaWindow* pThis )
     // due to a possible common gradient covering menubar and top dockingarea
     // the menubar must be repainted if the top dockingarea changes size or visibility
     if( ImplGetSVData()->maNWFData.mbMenuBarDockingAreaCommonBG &&
-        (pThis->GetAlign() == WINDOWALIGN_TOP)
+        (pThis->GetAlign() == WindowAlign::Top)
         && pThis->IsNativeControlSupported( CTRL_TOOLBAR, PART_ENTIRE_CONTROL )
         && pThis->IsNativeControlSupported( CTRL_MENUBAR, PART_ENTIRE_CONTROL ) )
     {
@@ -102,7 +102,7 @@ void DockingAreaWindow::StateChanged( StateChangedType nType )
 
 bool DockingAreaWindow::IsHorizontal() const
 {
-    return ( mpImplData->meAlign == WINDOWALIGN_TOP || mpImplData->meAlign == WINDOWALIGN_BOTTOM );
+    return ( mpImplData->meAlign == WindowAlign::Top || mpImplData->meAlign == WindowAlign::Bottom );
 }
 
 void DockingAreaWindow::SetAlign( WindowAlign eNewAlign )
@@ -122,12 +122,12 @@ WindowAlign DockingAreaWindow::GetAlign() const
 void DockingAreaWindow::ApplySettings(vcl::RenderContext& rRenderContext)
 {
     const StyleSettings rSetting = rRenderContext.GetSettings().GetStyleSettings();
-    const BitmapEx& rPersonaBitmap = (GetAlign() == WINDOWALIGN_TOP) ? rSetting.GetPersonaHeader() : rSetting.GetPersonaFooter();
+    const BitmapEx& rPersonaBitmap = (GetAlign() == WindowAlign::Top) ? rSetting.GetPersonaHeader() : rSetting.GetPersonaFooter();
 
-    if (!rPersonaBitmap.IsEmpty() && (GetAlign() == WINDOWALIGN_TOP || GetAlign()==WINDOWALIGN_BOTTOM))
+    if (!rPersonaBitmap.IsEmpty() && (GetAlign() == WindowAlign::Top || GetAlign()==WindowAlign::Bottom))
     {
         Wallpaper aWallpaper(rPersonaBitmap);
-        if (GetAlign() == WINDOWALIGN_TOP)
+        if (GetAlign() == WindowAlign::Top)
             aWallpaper.SetStyle(WallpaperStyle::TopRight);
         else
             aWallpaper.SetStyle(WallpaperStyle::BottomRight);
@@ -169,7 +169,7 @@ void DockingAreaWindow::Paint(vcl::RenderContext& rRenderContext, const Rectangl
     {
         ToolbarValue aControlValue;
 
-        if (GetAlign() == WINDOWALIGN_TOP && ImplGetSVData()->maNWFData.mbMenuBarDockingAreaCommonBG)
+        if (GetAlign() == WindowAlign::Top && ImplGetSVData()->maNWFData.mbMenuBarDockingAreaCommonBG)
         {
             // give NWF a hint that this dockingarea is adjacent to the menubar
             // useful for special gradient effects that should cover both windows
@@ -177,9 +177,9 @@ void DockingAreaWindow::Paint(vcl::RenderContext& rRenderContext, const Rectangl
         }
 
         ControlState nState = ControlState::ENABLED;
-        const bool isFooter = GetAlign() == WINDOWALIGN_BOTTOM && !rSetting.GetPersonaFooter().IsEmpty();
+        const bool isFooter = GetAlign() == WindowAlign::Bottom && !rSetting.GetPersonaFooter().IsEmpty();
 
-        if ((GetAlign() == WINDOWALIGN_TOP && !rSetting.GetPersonaHeader().IsEmpty() ) || isFooter)
+        if ((GetAlign() == WindowAlign::Top && !rSetting.GetPersonaHeader().IsEmpty() ) || isFooter)
             Erase(rRenderContext);
         else if (!ImplGetSVData()->maNWFData.mbDockingAreaSeparateTB)
         {
diff --git a/vcl/source/window/menubarwindow.cxx b/vcl/source/window/menubarwindow.cxx
index c6a0783..718ffc0 100644
--- a/vcl/source/window/menubarwindow.cxx
+++ b/vcl/source/window/menubarwindow.cxx
@@ -562,7 +562,7 @@ static int ImplGetTopDockingAreaHeight( vcl::Window *pWindow )
                     if ( pChildWin->GetType() == WINDOW_DOCKINGAREA )
                         pDockingArea = static_cast< DockingAreaWindow* >( pChildWin );
 
-                    if( pDockingArea && pDockingArea->GetAlign() == WINDOWALIGN_TOP &&
+                    if( pDockingArea && pDockingArea->GetAlign() == WindowAlign::Top &&
                         pDockingArea->IsVisible() && pDockingArea->GetOutputSizePixel().Height() != 0 )
                     {
                         return pDockingArea->GetOutputSizePixel().Height();
diff --git a/vcl/source/window/splitwin.cxx b/vcl/source/window/splitwin.cxx
index 69c14f8..fc5cc47 100644
--- a/vcl/source/window/splitwin.cxx
+++ b/vcl/source/window/splitwin.cxx
@@ -204,19 +204,19 @@ static void ImplCalcBorder( WindowAlign eAlign, bool bNoAlign,
     {
         switch ( eAlign )
         {
-        case WINDOWALIGN_TOP:
+        case WindowAlign::Top:
             rLeft   = 2;
             rTop    = 2;
             rRight  = 2;
             rBottom = 0;
             break;
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Left:
             rLeft   = 0;
             rTop    = 2;
             rRight  = 2;
             rBottom = 2;
             break;
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Bottom:
             rLeft   = 2;
             rTop    = 0;
             rRight  = 2;
@@ -249,7 +249,7 @@ void SplitWindow::ImplDrawBorder(vcl::RenderContext& rRenderContext)
     {
         switch (meAlign)
         {
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Bottom:
             rRenderContext.SetLineColor(rStyleSettings.GetShadowColor());
             rRenderContext.DrawLine(Point(0, 0), Point(nDX - 1, 0));
             rRenderContext.DrawLine(Point(0, nDY - 2), Point(nDX - 1, nDY - 2));
@@ -258,7 +258,7 @@ void SplitWindow::ImplDrawBorder(vcl::RenderContext& rRenderContext)
             rRenderContext.DrawLine(Point(0, 1), Point(nDX - 1, 1));
             rRenderContext.DrawLine(Point(0, nDY - 1), Point(nDX - 1, nDY - 1));
             break;
-        case WINDOWALIGN_TOP:
+        case WindowAlign::Top:
             rRenderContext.SetLineColor(rStyleSettings.GetShadowColor());
             rRenderContext.DrawLine(Point(0, nDY - 2), Point(nDX - 1, nDY - 2));
             rRenderContext.DrawLine(Point(0, 0), Point(nDX - 1, 0));
@@ -267,7 +267,7 @@ void SplitWindow::ImplDrawBorder(vcl::RenderContext& rRenderContext)
             rRenderContext.DrawLine(Point(0, nDY - 1), Point(nDX - 1, nDY - 1));
             rRenderContext.DrawLine(Point(0, 1), Point(nDX - 1, 1));
             break;
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Left:
             rRenderContext.SetLineColor(rStyleSettings.GetShadowColor());
             rRenderContext.DrawLine(Point(nDX - 2, 0), Point(nDX - 2, nDY - 2));
             rRenderContext.DrawLine(Point(0, 0), Point(nDX - 1, 0));
@@ -302,28 +302,28 @@ void SplitWindow::ImplDrawBorderLine(vcl::RenderContext& rRenderContext)
 
         switch (meAlign)
         {
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Left:
             rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
             rRenderContext.DrawLine( Point( nDX-SPLITWIN_SPLITSIZEEXLN-1, 1 ), Point( nDX-SPLITWIN_SPLITSIZEEXLN-1, nDY-2 ) );
 
             rRenderContext.SetLineColor( rStyleSettings.GetLightColor() );
             rRenderContext.DrawLine( Point( nDX-SPLITWIN_SPLITSIZEEXLN, 1 ), Point( nDX-SPLITWIN_SPLITSIZEEXLN, nDY-3 ) );
             break;
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Right:
             rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
             rRenderContext.DrawLine( Point( SPLITWIN_SPLITSIZEEXLN-1, 0 ), Point( SPLITWIN_SPLITSIZEEXLN-1, nDY-2 ) );
 
             rRenderContext.SetLineColor( rStyleSettings.GetLightColor() );
             rRenderContext.DrawLine( Point( SPLITWIN_SPLITSIZEEXLN, 1 ), Point( SPLITWIN_SPLITSIZEEXLN, nDY-3 ) );
             break;
-        case WINDOWALIGN_TOP:
+        case WindowAlign::Top:
             rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
             rRenderContext.DrawLine( Point( 0, nDY-SPLITWIN_SPLITSIZEEXLN-1 ), Point( nDX-1, nDY-SPLITWIN_SPLITSIZEEXLN-1 ) );
 
             rRenderContext.SetLineColor( rStyleSettings.GetLightColor() );
             rRenderContext.DrawLine( Point( 0, nDY-SPLITWIN_SPLITSIZEEXLN ), Point( nDX-1, nDY-SPLITWIN_SPLITSIZEEXLN ) );
             break;
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Bottom:
             rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
             rRenderContext.DrawLine( Point( 0, 5 ), Point( nDX-1, 5 ) );
 
@@ -1321,7 +1321,7 @@ void SplitWindow::ImplInit( vcl::Window* pParent, WinBits nStyle )
     mnBottomBorder          = 0;
     mnMaxSize               = 0;
     mnMouseOff              = 0;
-    meAlign                 = WINDOWALIGN_TOP;
+    meAlign                 = WindowAlign::Top;
     mnWinStyle              = nStyle;
     mnSplitTest             = 0;
     mnSplitPos              = 0;
@@ -1424,11 +1424,11 @@ void SplitWindow::ImplSetWindowSize( long nDelta )
     Size aSize = GetSizePixel();
     switch ( meAlign )
     {
-    case WINDOWALIGN_TOP:
+    case WindowAlign::Top:
         aSize.Height() += nDelta;
         SetSizePixel( aSize );
         break;
-    case WINDOWALIGN_BOTTOM:
+    case WindowAlign::Bottom:
     {
         maDragRect.Top() += nDelta;
         Point aPos = GetPosPixel();
@@ -1437,11 +1437,11 @@ void SplitWindow::ImplSetWindowSize( long nDelta )
         SetPosSizePixel( aPos, aSize );
         break;
     }
-    case WINDOWALIGN_LEFT:
+    case WindowAlign::Left:
         aSize.Width() += nDelta;
         SetSizePixel( aSize );
         break;
-    case WINDOWALIGN_RIGHT:
+    case WindowAlign::Right:
     default:
     {
         maDragRect.Left() += nDelta;
@@ -1498,17 +1498,17 @@ Size SplitWindow::CalcLayoutSizePixel( const Size& aNewSize )
 
             switch ( meAlign )
             {
-            case WINDOWALIGN_TOP:
+            case WindowAlign::Top:
                 aSize.Height() += nDelta;
                 break;
-            case WINDOWALIGN_BOTTOM:
+            case WindowAlign::Bottom:
                 aPos.Y() -= nDelta;
                 aSize.Height() += nDelta;
                 break;
-            case WINDOWALIGN_LEFT:
+            case WindowAlign::Left:
                 aSize.Width() += nDelta;
                 break;
-            case WINDOWALIGN_RIGHT:
+            case WindowAlign::Right:
             default:
                 aPos.X() -= nDelta;
                 aSize.Width() += nDelta;
@@ -1660,7 +1660,7 @@ void SplitWindow::ImplGetButtonRect( Rectangle& rRect, long nEx, bool bTest ) co
 
     switch ( meAlign )
     {
-    case WINDOWALIGN_TOP:
+    case WindowAlign::Top:
         rRect.Left()    = mnLeftBorder+nEx;
         rRect.Top()     = mnDY-mnBottomBorder-nSplitSize;
         rRect.Right()   = rRect.Left()+SPLITWIN_SPLITSIZEAUTOHIDE;
@@ -1671,7 +1671,7 @@ void SplitWindow::ImplGetButtonRect( Rectangle& rRect, long nEx, bool bTest ) co
             rRect.Bottom()  += mnBottomBorder;
         }
         break;
-    case WINDOWALIGN_BOTTOM:
+    case WindowAlign::Bottom:
         rRect.Left()    = mnLeftBorder+nEx;
         rRect.Top()     = mnTopBorder;
         rRect.Right()   = rRect.Left()+SPLITWIN_SPLITSIZEAUTOHIDE;
@@ -1682,7 +1682,7 @@ void SplitWindow::ImplGetButtonRect( Rectangle& rRect, long nEx, bool bTest ) co
             rRect.Bottom()  += mnBottomBorder;
         }
         break;
-    case WINDOWALIGN_LEFT:
+    case WindowAlign::Left:
         rRect.Left()    = mnDX-mnRightBorder-nSplitSize;
         rRect.Top()     = mnTopBorder+nEx;
         rRect.Right()   = mnDX-mnRightBorder-1;
@@ -1693,7 +1693,7 @@ void SplitWindow::ImplGetButtonRect( Rectangle& rRect, long nEx, bool bTest ) co
             rRect.Right()   += mnRightBorder;
         }
         break;
-    case WINDOWALIGN_RIGHT:
+    case WindowAlign::Right:
         rRect.Left()    = mnLeftBorder;
         rRect.Top()     = mnTopBorder+nEx;
         rRect.Right()   = mnLeftBorder+nSplitSize-1;
@@ -1977,12 +1977,12 @@ void SplitWindow::ImplDrawFadeIn(vcl::RenderContext& rRenderContext, bool bInPai
         bool bLeft = true;
         switch (meAlign)
         {
-        case WINDOWALIGN_TOP:
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Top:
+        case WindowAlign::Left:
             bLeft = false;
             break;
-        case WINDOWALIGN_BOTTOM:
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Bottom:
+        case WindowAlign::Right:
         default:
             bLeft = true;
             break;
@@ -1991,7 +1991,7 @@ void SplitWindow::ImplDrawFadeIn(vcl::RenderContext& rRenderContext, bool bInPai
         if (!bInPaint)
             rRenderContext.Erase(aTempRect);
 
-        ImplDrawGrip(rRenderContext, aTempRect, (meAlign == WINDOWALIGN_TOP) || (meAlign == WINDOWALIGN_BOTTOM), bLeft);
+        ImplDrawGrip(rRenderContext, aTempRect, (meAlign == WindowAlign::Top) || (meAlign == WindowAlign::Bottom), bLeft);
     }
 }
 
@@ -2005,12 +2005,12 @@ void SplitWindow::ImplDrawFadeOut(vcl::RenderContext& rRenderContext, bool bInPa
         bool bLeft = true;
         switch (meAlign)
         {
-        case WINDOWALIGN_BOTTOM:
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Bottom:
+        case WindowAlign::Right:
             bLeft = false;
             break;
-        case WINDOWALIGN_TOP:
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Top:
+        case WindowAlign::Left:
         default:
             bLeft = true;
             break;
@@ -2019,7 +2019,7 @@ void SplitWindow::ImplDrawFadeOut(vcl::RenderContext& rRenderContext, bool bInPa
         if (!bInPaint)
             rRenderContext.Erase(aTempRect);
 
-        ImplDrawGrip(rRenderContext, aTempRect, (meAlign == WINDOWALIGN_TOP) || (meAlign == WINDOWALIGN_BOTTOM), bLeft);
+        ImplDrawGrip(rRenderContext, aTempRect, (meAlign == WindowAlign::Top) || (meAlign == WindowAlign::Bottom), bLeft);
     }
 }
 
@@ -3200,19 +3200,19 @@ void SplitWindow::ImplNewAlign()
     {
         switch ( meAlign )
         {
-        case WINDOWALIGN_TOP:
+        case WindowAlign::Top:
             mbHorz        = true;
             mbBottomRight = false;
             break;
-        case WINDOWALIGN_BOTTOM:
+        case WindowAlign::Bottom:
             mbHorz        = true;
             mbBottomRight = true;
             break;
-        case WINDOWALIGN_LEFT:
+        case WindowAlign::Left:
             mbHorz        = false;
             mbBottomRight = false;
             break;
-        case WINDOWALIGN_RIGHT:
+        case WindowAlign::Right:
             mbHorz        = false;
             mbBottomRight = true;
             break;
diff --git a/vcl/source/window/tabdlg.cxx b/vcl/source/window/tabdlg.cxx
index 1080cb8..c5bea40 100644
--- a/vcl/source/window/tabdlg.cxx
+++ b/vcl/source/window/tabdlg.cxx
@@ -27,7 +27,7 @@ void TabDialog::ImplInitTabDialogData()
 {
     mpFixedLine     = NULL;
     mpViewWindow    = NULL;
-    meViewAlign     = WINDOWALIGN_LEFT;
+    meViewAlign     = WindowAlign::Left;
     mbPosControls   = true;
 }
 
@@ -97,7 +97,7 @@ void TabDialog::ImplPosControls()
             long    nViewHeight = 0;
             PosSizeFlags nViewPosFlags = PosSizeFlags::Pos;
             Size    aViewSize = mpViewWindow->GetSizePixel();
-            if (  meViewAlign == WINDOWALIGN_TOP )
+            if (  meViewAlign == WindowAlign::Top )
             {
                 nViewOffX       = aTabOffset.X();
                 nViewOffY       = nOffY+IMPL_DIALOG_OFFSET;
@@ -106,7 +106,7 @@ void TabDialog::ImplPosControls()
                 aTabOffset.Y() += aViewSize.Height()+IMPL_DIALOG_OFFSET;
                 aDlgSize.Height() += aViewSize.Height()+IMPL_DIALOG_OFFSET;
             }
-            else if (  meViewAlign == WINDOWALIGN_BOTTOM )
+            else if (  meViewAlign == WindowAlign::Bottom )
             {
                 nViewOffX       = aTabOffset.X();
                 nViewOffY       = aTabOffset.Y()+aTabSize.Height()+IMPL_DIALOG_OFFSET;
@@ -114,7 +114,7 @@ void TabDialog::ImplPosControls()
                 nViewPosFlags  |= PosSizeFlags::Width;
                 aDlgSize.Height() += aViewSize.Height()+IMPL_DIALOG_OFFSET;
             }
-            else if (  meViewAlign == WINDOWALIGN_RIGHT )
+            else if (  meViewAlign == WindowAlign::Right )
             {
                 nViewOffX       = aTabOffset.X()+aTabSize.Width()+IMPL_DIALOG_OFFSET;
                 nViewOffY       = aTabOffset.Y();
@@ -123,7 +123,7 @@ void TabDialog::ImplPosControls()
                 aDlgSize.Width() += aViewSize.Width()+IMPL_DIALOG_OFFSET;
                 nBtnEx          = aViewSize.Width()+IMPL_DIALOG_OFFSET;
             }
-            else // meViewAlign == WINDOWALIGN_LEFT
+            else // meViewAlign == WindowAlign::Left
             {
                 nViewOffX       = IMPL_DIALOG_OFFSET;
                 nViewOffY       = aTabOffset.Y();
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index 0100068..09847f8 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -189,7 +189,7 @@ void ToolBox::ImplUpdateDragArea( ToolBox *pThis )
             pWrapper->SetDragArea( Rectangle() );
         else
         {
-            if( pThis->meAlign == WINDOWALIGN_TOP || pThis->meAlign == WINDOWALIGN_BOTTOM )
+            if( pThis->meAlign == WindowAlign::Top || pThis->meAlign == WindowAlign::Bottom )
                 pWrapper->SetDragArea( Rectangle( 0, 0, ImplGetDragWidth( pThis ), pThis->GetOutputSizePixel().Height() ) );
             else
                 pWrapper->SetDragArea( Rectangle( 0, 0, pThis->GetOutputSizePixel().Width(), ImplGetDragWidth( pThis ) ) );
@@ -215,21 +215,21 @@ void ToolBox::ImplCalcBorder( WindowAlign eAlign, long& rLeft, long& rTop,
     // no shadow border for dockable toolbars
     int    borderwidth = pWrapper ? 0: 2;
 
-    if ( eAlign == WINDOWALIGN_TOP )
+    if ( eAlign == WindowAlign::Top )
     {
         rLeft   = borderwidth+dragwidth;
         rTop    = borderwidth;
         rRight  = borderwidth;
         rBottom = 0;
     }
-    else if ( eAlign == WINDOWALIGN_LEFT )
+    else if ( eAlign == WindowAlign::Left )
     {
         rLeft   = borderwidth;
         rTop    = borderwidth+dragwidth;
         rRight  = 0;
         rBottom = borderwidth;
     }
-    else if ( eAlign == WINDOWALIGN_BOTTOM )
+    else if ( eAlign == WindowAlign::Bottom )
     {
         rLeft   = borderwidth+dragwidth;
         rTop    = 0;
@@ -287,7 +287,7 @@ void ToolBox::ImplDrawGrip(vcl::RenderContext& rRenderContext)
 
         Size aSz(GetOutputSizePixel());
 
-        if (meAlign == WINDOWALIGN_TOP || meAlign == WINDOWALIGN_BOTTOM)
+        if (meAlign == WindowAlign::Top || meAlign == WindowAlign::Bottom)
         {
             int height = (int) (0.6 * aSz.Height() + 0.5);
             int i = (aSz.Height() - height) / 2;
@@ -533,9 +533,9 @@ void ToolBox::ImplDrawBackground(vcl::RenderContext& rRenderContext, const Recta
         const StyleSettings rSetting = Application::GetSettings().GetStyleSettings();
         if (!bNativeOk)
         {
-            const bool isFooter = GetAlign() == WINDOWALIGN_BOTTOM && !rSetting.GetPersonaFooter().IsEmpty();
+            const bool isFooter = GetAlign() == WindowAlign::Bottom && !rSetting.GetPersonaFooter().IsEmpty();
             if (!IsBackground() ||
-                ((GetAlign() == WINDOWALIGN_TOP && !rSetting.GetPersonaHeader().IsEmpty() ) || isFooter))
+                ((GetAlign() == WindowAlign::Top && !rSetting.GetPersonaHeader().IsEmpty() ) || isFooter))
             {
                 if (!IsInPaint())
                     ImplDrawTransparentBackground(rRenderContext, aPaintRegion);
@@ -589,7 +589,7 @@ void ToolBox::ImplDrawBorder(vcl::RenderContext& rRenderContext)
     if( pWrapper )
         return;
 
-    if (meAlign == WINDOWALIGN_BOTTOM)
+    if (meAlign == WindowAlign::Bottom)
     {
         // draw bottom border
         rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
@@ -605,9 +605,9 @@ void ToolBox::ImplDrawBorder(vcl::RenderContext& rRenderContext)
         rRenderContext.SetLineColor( rStyleSettings.GetLightColor() );
         rRenderContext.DrawLine( Point( 0, 1 ), Point( nDX-1, 1 ) );
 
-        if (meAlign == WINDOWALIGN_LEFT || meAlign == WINDOWALIGN_RIGHT)
+        if (meAlign == WindowAlign::Left || meAlign == WindowAlign::Right)
         {
-            if (meAlign == WINDOWALIGN_LEFT)
+            if (meAlign == WindowAlign::Left)
             {
                 // draw left-bottom border
                 rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
@@ -630,7 +630,7 @@ void ToolBox::ImplDrawBorder(vcl::RenderContext& rRenderContext)
         }
     }
 
-    if ( meAlign == WINDOWALIGN_BOTTOM || meAlign == WINDOWALIGN_TOP )
+    if ( meAlign == WindowAlign::Bottom || meAlign == WindowAlign::Top )
     {
         // draw right border
         rRenderContext.SetLineColor( rStyleSettings.GetShadowColor() );
@@ -684,18 +684,18 @@ Size ToolBox::ImplCalcSize( const ToolBox* pThis, sal_uInt16 nCalcLines, sal_uIn
         if ( nCalcMode == TB_CALCMODE_HORZ )
         {
             pThis->mpData->mbAssumeDocked = true;   // force non-floating mode during calculation
-            ImplCalcBorder( WINDOWALIGN_TOP, nLeft, nTop, nRight, nBottom, pThis );
+            ImplCalcBorder( WindowAlign::Top, nLeft, nTop, nRight, nBottom, pThis );
             const_cast<ToolBox*>(pThis)->mbHorz = true;
             if ( pThis->mbHorz != bOldHorz )
-                const_cast<ToolBox*>(pThis)->meAlign = WINDOWALIGN_TOP;
+                const_cast<ToolBox*>(pThis)->meAlign = WindowAlign::Top;
         }
         else if ( nCalcMode == TB_CALCMODE_VERT )
         {
             pThis->mpData->mbAssumeDocked = true;   // force non-floating mode during calculation
-            ImplCalcBorder( WINDOWALIGN_LEFT, nLeft, nTop, nRight, nBottom, pThis );
+            ImplCalcBorder( WindowAlign::Left, nLeft, nTop, nRight, nBottom, pThis );
             const_cast<ToolBox*>(pThis)->mbHorz = false;
             if ( pThis->mbHorz != bOldHorz )
-                const_cast<ToolBox*>(pThis)->meAlign = WINDOWALIGN_LEFT;
+                const_cast<ToolBox*>(pThis)->meAlign = WindowAlign::Left;
         }
         else if ( nCalcMode == TB_CALCMODE_FLOAT )
         {
@@ -703,7 +703,7 @@ Size ToolBox::ImplCalcSize( const ToolBox* pThis, sal_uInt16 nCalcLines, sal_uIn
             nLeft = nTop = nRight = nBottom = 0;
             const_cast<ToolBox*>(pThis)->mbHorz = true;
             if ( pThis->mbHorz != bOldHorz )
-                const_cast<ToolBox*>(pThis)->meAlign = WINDOWALIGN_TOP;
+                const_cast<ToolBox*>(pThis)->meAlign = WindowAlign::Top;
         }
 
         if ( (pThis->meAlign != eOldAlign) || (pThis->mbHorz != bOldHorz) ||
@@ -945,22 +945,22 @@ sal_uInt16 ToolBox::ImplTestLineSize( ToolBox* pThis, const Point& rPos )
     {
         WindowAlign eAlign = pThis->GetAlign();
 
-        if ( eAlign == WINDOWALIGN_LEFT )
+        if ( eAlign == WindowAlign::Left )
         {
             if ( rPos.X() > pThis->mnDX-DOCK_LINEOFFSET )
                 return DOCK_LINEHSIZE | DOCK_LINERIGHT;
         }
-        else if ( eAlign == WINDOWALIGN_TOP )
+        else if ( eAlign == WindowAlign::Top )
         {
             if ( rPos.Y() > pThis->mnDY-DOCK_LINEOFFSET )
                 return DOCK_LINEVSIZE | DOCK_LINEBOTTOM;
         }
-        else if ( eAlign == WINDOWALIGN_RIGHT )
+        else if ( eAlign == WindowAlign::Right )
         {
             if ( rPos.X() < DOCK_LINEOFFSET )
                 return DOCK_LINEHSIZE | DOCK_LINELEFT;
         }
-        else if ( eAlign == WINDOWALIGN_BOTTOM )
+        else if ( eAlign == WindowAlign::Bottom )
         {
             if ( rPos.Y() < DOCK_LINEOFFSET )
                 return DOCK_LINEVSIZE | DOCK_LINETOP;
@@ -1395,7 +1395,7 @@ void ToolBox::ImplInit( vcl::Window* pParent, WinBits nStyle )
     mbIsKeyEvent = false;
     mbChangingHighlight = false;
     meButtonType      = ButtonType::SYMBOLONLY;
-    meAlign           = WINDOWALIGN_TOP;
+    meAlign           = WindowAlign::Top;
     meLastStyle       = PointerStyle::Arrow;
     mnWinStyle        = nStyle;
     meLayoutMode      = TBX_LAYOUT_NORMAL;
@@ -1456,8 +1456,8 @@ void ToolBox::ApplySettings(vcl::RenderContext& rRenderContext)
     else
     {
         if (rRenderContext.IsNativeControlSupported(CTRL_TOOLBAR, PART_ENTIRE_CONTROL)
-            || (GetAlign() == WINDOWALIGN_TOP && !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty())
-            || (GetAlign() == WINDOWALIGN_BOTTOM && !Application::GetSettings().GetStyleSettings().GetPersonaFooter().IsEmpty()))
+            || (GetAlign() == WindowAlign::Top && !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty())
+            || (GetAlign() == WindowAlign::Bottom && !Application::GetSettings().GetStyleSettings().GetPersonaFooter().IsEmpty()))
         {
             rRenderContext.SetBackground();
             rRenderContext.SetTextColor(rStyleSettings.GetMenuBarTextColor());
@@ -1519,8 +1519,8 @@ void ToolBox::ImplInitSettings(bool bFont, bool bForeground, bool bBackground)
         else
         {
             if (IsNativeControlSupported(CTRL_TOOLBAR, PART_ENTIRE_CONTROL)
-                || (GetAlign() == WINDOWALIGN_TOP && !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty())
-                || (GetAlign() == WINDOWALIGN_BOTTOM && !Application::GetSettings().GetStyleSettings().GetPersonaFooter().IsEmpty()))
+                || (GetAlign() == WindowAlign::Top && !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty())
+                || (GetAlign() == WindowAlign::Bottom && !Application::GetSettings().GetStyleSettings().GetPersonaFooter().IsEmpty()))
             {
                 SetBackground();
                 SetTextColor(rStyleSettings.GetMenuBarTextColor());
@@ -3213,7 +3213,7 @@ void ToolBox::ImplDrawItem(vcl::RenderContext& rRenderContext, sal_uInt16 nPos,
         // rotate text when vertically docked
         vcl::Font aOldFont = rRenderContext.GetFont();
         if( pItem->mbVisibleText && !ImplIsFloatingMode() &&
-            ((meAlign == WINDOWALIGN_LEFT) || (meAlign == WINDOWALIGN_RIGHT)) )
+            ((meAlign == WindowAlign::Left) || (meAlign == WindowAlign::Right)) )
         {
             bRotate = true;
 
@@ -3679,14 +3679,14 @@ void ToolBox::MouseMove( const MouseEvent& rMEvt )
             sal_uInt16 nLinePtr = ImplTestLineSize( this, rMEvt.GetPosPixel() );
             if ( nLinePtr & DOCK_LINEHSIZE )
             {
-                if ( meAlign == WINDOWALIGN_LEFT )
+                if ( meAlign == WindowAlign::Left )
                     eStyle = PointerStyle::WindowESize;
                 else
                     eStyle = PointerStyle::WindowWSize;
             }
             else if ( nLinePtr & DOCK_LINEVSIZE )
             {
-                if ( meAlign == WINDOWALIGN_TOP )
+                if ( meAlign == WindowAlign::Top )
                     eStyle = PointerStyle::WindowSSize;
                 else
                     eStyle = PointerStyle::WindowNSize;
@@ -4573,7 +4573,7 @@ void ToolBox::ToggleFloatingMode()
     if ( ImplIsFloatingMode() )
     {
         mbHorz   = true;
-        meAlign  = WINDOWALIGN_TOP;
+        meAlign  = WindowAlign::Top;
         mbScroll = true;
 
         if( mbOldHorz != mbHorz )
@@ -4585,7 +4585,7 @@ void ToolBox::ToggleFloatingMode()
     else
     {
         mbScroll = (mnWinStyle & WB_SCROLL) != 0;
-        if ( (meAlign == WINDOWALIGN_TOP) || (meAlign == WINDOWALIGN_BOTTOM) )
+        if ( (meAlign == WindowAlign::Top) || (meAlign == WindowAlign::Bottom) )
             mbHorz = true;
         else
             mbHorz = false;
@@ -4677,16 +4677,16 @@ bool ToolBox::Docking( const Point& rPos, Rectangle& rRect )
             Size  aInSize = aInRect.GetSize();
 
             if ( aInPosTL.X() <= 0 )
-                meDockAlign = WINDOWALIGN_LEFT;
+                meDockAlign = WindowAlign::Left;
             else if ( aInPosTL.Y() <= 0)
-                meDockAlign = WINDOWALIGN_TOP;
+                meDockAlign = WindowAlign::Top;
             else if ( aInPosBR.X() >= aInSize.Width() )
-                meDockAlign = WINDOWALIGN_RIGHT;
+                meDockAlign = WindowAlign::Right;
             else if ( aInPosBR.Y() >= aInSize.Height() )
-                meDockAlign = WINDOWALIGN_BOTTOM;
+                meDockAlign = WindowAlign::Bottom;
 
             // update the Dock size if Dock-Align was changed
-            if ( (meDockAlign == WINDOWALIGN_TOP) || (meDockAlign == WINDOWALIGN_BOTTOM) )
+            if ( (meDockAlign == WindowAlign::Top) || (meDockAlign == WindowAlign::Bottom) )
                 aDockSize.Width() = maInDockRect.GetWidth();
             else
                 aDockSize.Height() = maInDockRect.GetHeight();
@@ -4696,20 +4696,20 @@ bool ToolBox::Docking( const Point& rPos, Rectangle& rRect )
             Point aPosTL( maInDockRect.TopLeft() );
             switch ( meDockAlign )
             {
-                case WINDOWALIGN_TOP :
+                case WindowAlign::Top :
                     aDockingRect.SetPos( aPosTL );
                     break;
-                case WINDOWALIGN_LEFT :
+                case WindowAlign::Left :
                     aDockingRect.SetPos( aPosTL );
                     break;
-                case WINDOWALIGN_BOTTOM :
+                case WindowAlign::Bottom :
                 {
                     Point aPosBL( maInDockRect.BottomLeft() );
                     aPosBL.Y() -= aDockingRect.GetHeight();
                     aDockingRect.SetPos( aPosBL );
                     break;
                 }
-                case WINDOWALIGN_RIGHT :
+                case WindowAlign::Right :
                 {
                     Point aPosTR( maInDockRect.TopRight() );
                     aPosTR.X() -= aDockingRect.GetWidth();
@@ -4829,7 +4829,7 @@ Size ToolBox::CalcWindowSizePixel( sal_uInt16 nCalcLines ) const
 Size ToolBox::CalcWindowSizePixel( sal_uInt16 nCalcLines, WindowAlign eAlign ) const
 {
     return ImplCalcSize( this, nCalcLines,
-        (eAlign == WINDOWALIGN_TOP || eAlign == WINDOWALIGN_BOTTOM) ? TB_CALCMODE_HORZ : TB_CALCMODE_VERT );
+        (eAlign == WindowAlign::Top || eAlign == WindowAlign::Bottom) ? TB_CALCMODE_HORZ : TB_CALCMODE_VERT );
 }
 
 sal_uInt16 ToolBox::ImplCountLineBreaks( const ToolBox *pThis )
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx
index 856b807..7bd7610 100644
--- a/vcl/source/window/toolbox2.cxx
+++ b/vcl/source/window/toolbox2.cxx
@@ -826,7 +826,7 @@ void ToolBox::SetAlign( WindowAlign eNewAlign )
         if ( !ImplIsFloatingMode() )
         {
             // set horizontal/vertical alignment
-            if ( (eNewAlign == WINDOWALIGN_LEFT) || (eNewAlign == WINDOWALIGN_RIGHT) )
+            if ( (eNewAlign == WindowAlign::Left) || (eNewAlign == WindowAlign::Right) )
                 mbHorz = false;
             else
                 mbHorz = true;
@@ -974,14 +974,14 @@ Point ToolBox::ImplGetPopupPosition( const Rectangle& rRect, const Size& rSize )
         Point devPos;           // the position in device coordinates for screen comparison
         switch( meAlign )
         {
-            case WINDOWALIGN_TOP:
+            case WindowAlign::Top:
                 aPos = rRect.BottomLeft();
                 aPos.Y()++;
                 devPos = OutputToAbsoluteScreenPixel( aPos );
                 if( devPos.Y() + rSize.Height() >= aScreen.Bottom() )
                     aPos.Y() = rRect.Top() - rSize.Height();
                 break;
-            case WINDOWALIGN_BOTTOM:
+            case WindowAlign::Bottom:
                 aPos = rRect.TopLeft();
                 aPos.Y()--;
                 devPos = OutputToAbsoluteScreenPixel( aPos );
@@ -990,14 +990,14 @@ Point ToolBox::ImplGetPopupPosition( const Rectangle& rRect, const Size& rSize )
                 else
                     aPos.Y() = rRect.Bottom();
                 break;
-            case WINDOWALIGN_LEFT:
+            case WindowAlign::Left:
                 aPos = rRect.TopRight();
                 aPos.X()++;
                 devPos = OutputToAbsoluteScreenPixel( aPos );
                 if( devPos.X() + rSize.Width() >= aScreen.Right() )
                     aPos.X() = rRect.Left() - rSize.Width();
                 break;
-            case WINDOWALIGN_RIGHT:
+            case WindowAlign::Right:
                 aPos = rRect.TopLeft();
                 aPos.X()--;
                 devPos = OutputToAbsoluteScreenPixel( aPos );
commit dc7fc2074dd81f0960e6c112ead1cfe5bfd1bf4c
Author: Noel Grandin <noel at peralex.com>
Date:   Thu Jul 23 12:43:02 2015 +0200

    convert WALLPAPER constants to scoped enum
    
    Change-Id: I3b4b4e8a94904e22823a263bd5446a2e1aa47661

diff --git a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
index 25854db..09bc2cc 100644
--- a/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/metafileprimitive2d.cxx
@@ -1149,7 +1149,7 @@ namespace
         // if bitmap visualisation is transparent, maybe background
         // needs to be filled. Create background
         if(aBitmapEx.IsTransparent()
-            || (WALLPAPER_TILE != eWallpaperStyle && WALLPAPER_SCALE != eWallpaperStyle))
+            || (WallpaperStyle::Tile != eWallpaperStyle && WallpaperStyle::Scale != eWallpaperStyle))
         {
             if(rWallpaper.IsGradient())
             {
@@ -2375,7 +2375,7 @@ namespace
                             aWallpaperRectangle.Left(), aWallpaperRectangle.Top(),
                             aWallpaperRectangle.Right(), aWallpaperRectangle.Bottom());
 
-                        if(WALLPAPER_NULL != eWallpaperStyle)
+                        if(WallpaperStyle::NONE != eWallpaperStyle)
                         {
                             if(rWallpaper.IsBitmap())
                             {
diff --git a/drawinglayer/source/primitive2d/wallpaperprimitive2d.cxx b/drawinglayer/source/primitive2d/wallpaperprimitive2d.cxx
index 63d8f7e..4f631c9 100644
--- a/drawinglayer/source/primitive2d/wallpaperprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/wallpaperprimitive2d.cxx
@@ -44,7 +44,7 @@ namespace drawinglayer
 
                 if(rPixelSize.Width() > 0 && rPixelSize.Height() > 0)
                 {
-                    if(WALLPAPER_SCALE == getWallpaperStyle())
+                    if(WallpaperStyle::Scale == getWallpaperStyle())
                     {
                         // shortcut for scale; use simple BitmapPrimitive2D
                         basegfx::B2DHomMatrix aObjectTransform;
@@ -76,64 +76,64 @@ namespace drawinglayer
 
                         switch(getWallpaperStyle())
                         {
-                            default: //case WALLPAPER_TILE :, also WALLPAPER_NULL and WALLPAPER_APPLICATIONGRADIENT
+                            default: //case WallpaperStyle::Tile :, also WallpaperStyle::NONE and WallpaperStyle::ApplicationGradient
                             {
                                 bUseTargetTopLeft = false;
                                 break;
                             }
-                            case WALLPAPER_SCALE :
+                            case WallpaperStyle::Scale :
                             {
                                 // handled by shortcut above
                                 break;
                             }
-                            case WALLPAPER_TOPLEFT :
+                            case WallpaperStyle::TopLeft :
                             {
                                 // nothing to do
                                 break;
                             }
-                            case WALLPAPER_TOP :
+                            case WallpaperStyle::Top :
                             {
                                 const basegfx::B2DPoint aCenter(getLocalObjectRange().getCenter());
                                 aTargetTopLeft.setX(aCenter.getX() - (aLogicSize.getX() * 0.5));
                                 break;
                             }
-                            case WALLPAPER_TOPRIGHT :
+                            case WallpaperStyle::TopRight :
                             {
                                 aTargetTopLeft.setX(getLocalObjectRange().getMaxX() - aLogicSize.getX());
                                 break;
                             }
-                            case WALLPAPER_LEFT :
+                            case WallpaperStyle::Left :
                             {
                                 const basegfx::B2DPoint aCenter(getLocalObjectRange().getCenter());
                                 aTargetTopLeft.setY(aCenter.getY() - (aLogicSize.getY() * 0.5));
                                 break;
                             }
-                            case WALLPAPER_CENTER :
+                            case WallpaperStyle::Center :
                             {
                                 const basegfx::B2DPoint aCenter(getLocalObjectRange().getCenter());
                                 aTargetTopLeft = aCenter - (aLogicSize * 0.5);
                                 break;
                             }
-                            case WALLPAPER_RIGHT :
+                            case WallpaperStyle::Right :
                             {
                                 const basegfx::B2DPoint aCenter(getLocalObjectRange().getCenter());
                                 aTargetTopLeft.setX(getLocalObjectRange().getMaxX() - aLogicSize.getX());
                                 aTargetTopLeft.setY(aCenter.getY() - (aLogicSize.getY() * 0.5));
                                 break;
                             }
-                            case WALLPAPER_BOTTOMLEFT :
+                            case WallpaperStyle::BottomLeft :
                             {
                                 aTargetTopLeft.setY(getLocalObjectRange().getMaxY() - aLogicSize.getY());
                                 break;
                             }
-                            case WALLPAPER_BOTTOM :
+                            case WallpaperStyle::Bottom :
                             {
                                 const basegfx::B2DPoint aCenter(getLocalObjectRange().getCenter());
                                 aTargetTopLeft.setX(aCenter.getX() - (aLogicSize.getX() * 0.5));
                                 aTargetTopLeft.setY(getLocalObjectRange().getMaxY() - aLogicSize.getY());
                                 break;
                             }
-                            case WALLPAPER_BOTTOMRIGHT :
+                            case WallpaperStyle::BottomRight :
                             {
                                 aTargetTopLeft = getLocalObjectRange().getMaximum() - aLogicSize;
                                 break;
@@ -164,14 +164,14 @@ namespace drawinglayer
                         }
                         else
                         {
-                            // WALLPAPER_TILE, WALLPAPER_NULL, WALLPAPER_APPLICATIONGRADIENT
+                            // WallpaperStyle::Tile, WallpaperStyle::NONE, WallpaperStyle::ApplicationGradient
                             // convert to relative positions
                             const basegfx::B2DVector aRelativeSize(
                                 aLogicSize.getX() / (getLocalObjectRange().getWidth() ? getLocalObjectRange().getWidth() : 1.0),
                                 aLogicSize.getY() / (getLocalObjectRange().getHeight() ? getLocalObjectRange().getHeight() : 1.0));
                             basegfx::B2DPoint aRelativeTopLeft(0.0, 0.0);
 
-                            if(WALLPAPER_TILE != getWallpaperStyle())
+                            if(WallpaperStyle::Tile != getWallpaperStyle())
                             {
                                 aRelativeTopLeft.setX(0.5 - aRelativeSize.getX());
                                 aRelativeTopLeft.setY(0.5 - aRelativeSize.getY());
diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx
index b0b61af..ba042d9 100644
--- a/editeng/source/items/frmitems.cxx
+++ b/editeng/source/items/frmitems.cxx
@@ -4069,18 +4069,18 @@ SvxGraphicPosition SvxBrushItem::WallpaperStyle2GraphicPos( WallpaperStyle eStyl
     // The switch is not the fastest, but the safest
     switch( eStyle )
     {
-        case WALLPAPER_NULL: eResult = GPOS_NONE; break;
-        case WALLPAPER_TILE: eResult = GPOS_TILED; break;
-        case WALLPAPER_CENTER: eResult = GPOS_MM; break;
-        case WALLPAPER_SCALE: eResult = GPOS_AREA; break;
-        case WALLPAPER_TOPLEFT: eResult = GPOS_LT; break;
-        case WALLPAPER_TOP: eResult = GPOS_MT; break;
-        case WALLPAPER_TOPRIGHT: eResult = GPOS_RT; break;
-        case WALLPAPER_LEFT: eResult = GPOS_LM; break;
-        case WALLPAPER_RIGHT: eResult = GPOS_RM; break;
-        case WALLPAPER_BOTTOMLEFT: eResult = GPOS_LB; break;
-        case WALLPAPER_BOTTOM: eResult = GPOS_MB; break;
-        case WALLPAPER_BOTTOMRIGHT: eResult = GPOS_RB; break;
+        case WallpaperStyle::NONE: eResult = GPOS_NONE; break;
+        case WallpaperStyle::Tile: eResult = GPOS_TILED; break;
+        case WallpaperStyle::Center: eResult = GPOS_MM; break;
+        case WallpaperStyle::Scale: eResult = GPOS_AREA; break;
+        case WallpaperStyle::TopLeft: eResult = GPOS_LT; break;
+        case WallpaperStyle::Top: eResult = GPOS_MT; break;
+        case WallpaperStyle::TopRight: eResult = GPOS_RT; break;
+        case WallpaperStyle::Left: eResult = GPOS_LM; break;
+        case WallpaperStyle::Right: eResult = GPOS_RM; break;
+        case WallpaperStyle::BottomLeft: eResult = GPOS_LB; break;
+        case WallpaperStyle::Bottom: eResult = GPOS_MB; break;
+        case WallpaperStyle::BottomRight: eResult = GPOS_RB; break;
         default: eResult = GPOS_NONE;
     }
     return eResult;
@@ -4092,19 +4092,19 @@ WallpaperStyle SvxBrushItem::GraphicPos2WallpaperStyle( SvxGraphicPosition ePos
     WallpaperStyle eResult;
     switch( ePos )
     {
-        case GPOS_NONE: eResult = WALLPAPER_NULL; break;
-        case GPOS_TILED: eResult = WALLPAPER_TILE; break;
-        case GPOS_MM: eResult = WALLPAPER_CENTER; break;
-        case GPOS_AREA: eResult = WALLPAPER_SCALE; break;
-        case GPOS_LT: eResult = WALLPAPER_TOPLEFT; break;
-        case GPOS_MT: eResult = WALLPAPER_TOP; break;
-        case GPOS_RT: eResult = WALLPAPER_TOPRIGHT; break;
-        case GPOS_LM: eResult = WALLPAPER_LEFT; break;
-        case GPOS_RM: eResult = WALLPAPER_RIGHT; break;
-        case GPOS_LB: eResult = WALLPAPER_BOTTOMLEFT; break;
-        case GPOS_MB: eResult = WALLPAPER_BOTTOM; break;
-        case GPOS_RB: eResult = WALLPAPER_BOTTOMRIGHT; break;
-        default: eResult = WALLPAPER_NULL;
+        case GPOS_NONE: eResult = WallpaperStyle::NONE; break;
+        case GPOS_TILED: eResult = WallpaperStyle::Tile; break;
+        case GPOS_MM: eResult = WallpaperStyle::Center; break;
+        case GPOS_AREA: eResult = WallpaperStyle::Scale; break;
+        case GPOS_LT: eResult = WallpaperStyle::TopLeft; break;
+        case GPOS_MT: eResult = WallpaperStyle::Top; break;
+        case GPOS_RT: eResult = WallpaperStyle::TopRight; break;
+        case GPOS_LM: eResult = WallpaperStyle::Left; break;
+        case GPOS_RM: eResult = WallpaperStyle::Right; break;
+        case GPOS_LB: eResult = WallpaperStyle::BottomLeft; break;
+        case GPOS_MB: eResult = WallpaperStyle::Bottom; break;
+        case GPOS_RB: eResult = WallpaperStyle::BottomRight; break;
+        default: eResult = WallpaperStyle::NONE;
     }
     return eResult;
 }
diff --git a/include/vcl/wall.hxx b/include/vcl/wall.hxx
index 206e5fb..f727dc7 100644
--- a/include/vcl/wall.hxx
+++ b/include/vcl/wall.hxx
@@ -28,45 +28,24 @@ class Gradient;
 class BitmapEx;
 class ImplWallpaper;
 
-#define WALLPAPER_NULL                  WallpaperStyle_NULL
-#define WALLPAPER_TILE                  WallpaperStyle_TILE
-#define WALLPAPER_CENTER                WallpaperStyle_CENTER
-#define WALLPAPER_SCALE                 WallpaperStyle_SCALE
-#define WALLPAPER_TOPLEFT               WallpaperStyle_TOPLEFT
-#define WALLPAPER_TOP                   WallpaperStyle_TOP
-#define WALLPAPER_TOPRIGHT              WallpaperStyle_TOPRIGHT
-#define WALLPAPER_LEFT                  WallpaperStyle_LEFT
-#define WALLPAPER_RIGHT                 WallpaperStyle_RIGHT
-#define WALLPAPER_BOTTOMLEFT            WallpaperStyle_BOTTOMLEFT
-#define WALLPAPER_BOTTOM                WallpaperStyle_BOTTOM
-#define WALLPAPER_BOTTOMRIGHT           WallpaperStyle_BOTTOMRIGHT
-#define WALLPAPER_APPLICATIONGRADIENT   WallpaperStyle_APPLICATIONGRADIENT
-#define WALLPAPER_FORCE_EQUAL_SIZE      WallpaperStyle_FORCE_EQUAL_SIZE
-
-#ifndef ENUM_WALLPAPERSTYLE_DECLARED
-#define ENUM_WALLPAPERSTYLE_DECLARED
-
-enum WallpaperStyle
+enum class WallpaperStyle
 {
-    WALLPAPER_NULL,
-    WALLPAPER_TILE,
-    WALLPAPER_CENTER,
-    WALLPAPER_SCALE,
-    WALLPAPER_TOPLEFT,
-    WALLPAPER_TOP,
-    WALLPAPER_TOPRIGHT,
-    WALLPAPER_LEFT,
-    WALLPAPER_RIGHT,
-    WALLPAPER_BOTTOMLEFT,
-    WALLPAPER_BOTTOM,
-    WALLPAPER_BOTTOMRIGHT,
-    WALLPAPER_APPLICATIONGRADIENT,          // defines a gradient that internally covers the whole application
-                                            // and uses a color derived from the face color
-    WALLPAPER_FORCE_EQUAL_SIZE = 0x7fffffff
+    NONE,
+    Tile,
+    Center,
+    Scale,
+    TopLeft,
+    Top,
+    TopRight,
+    Left,
+    Right,
+    BottomLeft,
+    Bottom,
+    BottomRight,
+    ApplicationGradient          // defines a gradient that internally covers the whole application
+                                 // and uses a color derived from the face color
 };
 
-#endif
-
 class VCL_DLLPUBLIC Wallpaper
 {
 private:
diff --git a/sfx2/source/dialog/backingwindow.cxx b/sfx2/source/dialog/backingwindow.cxx
index e268790..d267e3b9 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -322,7 +322,7 @@ void BackingWindow::initControls()
 
     // motif image under the buttons
     Wallpaper aWallpaper(get<FixedImage>("motif")->GetImage().GetBitmapEx());
-    aWallpaper.SetStyle(WALLPAPER_BOTTOMRIGHT);
+    aWallpaper.SetStyle(WallpaperStyle::BottomRight);
     aWallpaper.SetColor(aButtonsBackground);
 
     mpButtonsBox->SetBackground(aWallpaper);
diff --git a/sfx2/source/doc/frmdescr.cxx b/sfx2/source/doc/frmdescr.cxx
index 3a257c6..d3a2ba0 100644
--- a/sfx2/source/doc/frmdescr.cxx
+++ b/sfx2/source/doc/frmdescr.cxx
@@ -139,7 +139,7 @@ void SfxFrameDescriptor::SetWallpaper( const Wallpaper& rWallpaper )
 {
     DELETEZ( pImp->pWallpaper );
 
-    if ( rWallpaper.GetStyle() != WALLPAPER_NULL )
+    if ( rWallpaper.GetStyle() != WallpaperStyle::NONE )
         pImp->pWallpaper = new Wallpaper( rWallpaper );
 }
 
diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx
index 73e5c5e..01b76a4 100644
--- a/svtools/source/contnr/ivctrl.cxx
+++ b/svtools/source/contnr/ivctrl.cxx
@@ -371,7 +371,7 @@ void SvtIconChoiceCtrl::SetBackground( const Wallpaper& rPaper )
             Wallpaper aBackground( rPaper );
             // HACK, as background might be transparent!
             if( !aBackground.IsBitmap() )
-                aBackground.SetStyle( WALLPAPER_TILE );
+                aBackground.SetStyle( WallpaperStyle::Tile );
 
             WallpaperStyle eStyle = aBackground.GetStyle();
             Color aBack( aBackground.GetColor());
@@ -379,7 +379,7 @@ void SvtIconChoiceCtrl::SetBackground( const Wallpaper& rPaper )
             if( aBack == aTrans  && (
                 (!aBackground.IsBitmap() ||
                     aBackground.GetBitmap().IsTransparent() ||
-                    (eStyle != WALLPAPER_TILE && eStyle != WALLPAPER_SCALE))))
+                    (eStyle != WallpaperStyle::Tile && eStyle != WallpaperStyle::Scale))))
             {
                 aBackground.SetColor( rStyleSettings.GetFieldColor() );
             }
diff --git a/toolkit/source/awt/vclxwindows.cxx b/toolkit/source/awt/vclxwindows.cxx
index c24324f..ad9f9d2 100644
--- a/toolkit/source/awt/vclxwindows.cxx
+++ b/toolkit/source/awt/vclxwindows.cxx
@@ -2397,7 +2397,7 @@ throw(::com::sun::star::uno::RuntimeException, std::exception)
                     Image aImage( xGraphic );
 
                     Wallpaper aWallpaper( aImage.GetBitmapEx());
-                    aWallpaper.SetStyle( WALLPAPER_SCALE );
+                    aWallpaper.SetStyle( WallpaperStyle::Scale );
                     pDialog->SetBackground( aWallpaper );
                 }
                 else if ( bVoid || !xGraphic.is() )
@@ -2561,7 +2561,7 @@ throw(::com::sun::star::uno::RuntimeException, std::exception)
                     Image aImage( xGraphic );
 
                     Wallpaper aWallpaper( aImage.GetBitmapEx());
-                    aWallpaper.SetStyle( WALLPAPER_SCALE );
+                    aWallpaper.SetStyle( WallpaperStyle::Scale );
                     pTabControl->SetBackground( aWallpaper );
                 }
                 else if ( bVoid || !xGraphic.is() )
@@ -2803,7 +2803,7 @@ throw(::com::sun::star::uno::RuntimeException, std::exception)
                     Image aImage( xGraphic );
 
                     Wallpaper aWallpaper( aImage.GetBitmapEx());
-                    aWallpaper.SetStyle( WALLPAPER_SCALE );
+                    aWallpaper.SetStyle( WallpaperStyle::Scale );
                     pTabPage->SetBackground( aWallpaper );
                 }
                 else if ( bVoid || !xGraphic.is() )
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index 70a1502..cd11091 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -348,7 +348,7 @@ void doTestCode()
     aWriter.NewPage( 595, 842 );
     aWriter.SetMapMode( MapMode( MAP_100TH_MM ) );
     Wallpaper aWall( aTransMask );
-    aWall.SetStyle( WALLPAPER_TILE );
+    aWall.SetStyle( WallpaperStyle::Tile );
     aWriter.DrawWallpaper( Rectangle( Point( 4400, 4200 ), Size( 10200, 6300 ) ), aWall );
 
     aWriter.NewPage( 595, 842 );
@@ -11823,9 +11823,9 @@ void PDFWriterImpl::drawWallpaper( const Rectangle& rRect, const Wallpaper& rWal
             aBmpPos = aRect.TopLeft();
             aBmpSize = aRect.GetSize();
         }
-        if( rWall.GetStyle() != WALLPAPER_SCALE )
+        if( rWall.GetStyle() != WallpaperStyle::Scale )
         {
-            if( rWall.GetStyle() != WALLPAPER_TILE )
+            if( rWall.GetStyle() != WallpaperStyle::Tile )
             {
                 bDrawBitmap     = true;
                 if( rWall.IsGradient() )
@@ -11834,33 +11834,33 @@ void PDFWriterImpl::drawWallpaper( const Rectangle& rRect, const Wallpaper& rWal
                     bDrawColor = true;
                 switch( rWall.GetStyle() )
                 {
-                    case WALLPAPER_TOPLEFT:
+                    case WallpaperStyle::TopLeft:
                         break;
-                    case WALLPAPER_TOP:
+                    case WallpaperStyle::Top:
                         aBmpPos.X() += (aRect.GetWidth()-aBmpSize.Width())/2;
                         break;
-                    case WALLPAPER_LEFT:
+                    case WallpaperStyle::Left:
                         aBmpPos.Y() += (aRect.GetHeight()-aBmpSize.Height())/2;
                         break;
-                    case WALLPAPER_TOPRIGHT:
+                    case WallpaperStyle::TopRight:
                         aBmpPos.X() += aRect.GetWidth()-aBmpSize.Width();
                         break;
-                    case WALLPAPER_CENTER:
+                    case WallpaperStyle::Center:
                         aBmpPos.X() += (aRect.GetWidth()-aBmpSize.Width())/2;
                         aBmpPos.Y() += (aRect.GetHeight()-aBmpSize.Height())/2;
                         break;
-                    case WALLPAPER_RIGHT:
+                    case WallpaperStyle::Right:
                         aBmpPos.X() += aRect.GetWidth()-aBmpSize.Width();
                         aBmpPos.Y() += (aRect.GetHeight()-aBmpSize.Height())/2;
                         break;
-                    case WALLPAPER_BOTTOMLEFT:
+                    case WallpaperStyle::BottomLeft:
                         aBmpPos.Y() += aRect.GetHeight()-aBmpSize.Height();
                         break;
-                    case WALLPAPER_BOTTOM:
+                    case WallpaperStyle::Bottom:
                         aBmpPos.X() += (aRect.GetWidth()-aBmpSize.Width())/2;
                         aBmpPos.Y() += aRect.GetHeight()-aBmpSize.Height();
                         break;
-                    case WALLPAPER_BOTTOMRIGHT:
+                    case WallpaperStyle::BottomRight:
                         aBmpPos.X() += aRect.GetWidth()-aBmpSize.Width();
                         aBmpPos.Y() += aRect.GetHeight()-aBmpSize.Height();
                         break;
diff --git a/vcl/source/gdi/wall.cxx b/vcl/source/gdi/wall.cxx
index 847a5a1..e462f2d 100644
--- a/vcl/source/gdi/wall.cxx
+++ b/vcl/source/gdi/wall.cxx
@@ -36,7 +36,7 @@ ImplWallpaper::ImplWallpaper() :
     mpCache         = NULL;
     mpGradient      = NULL;
     mpRect          = NULL;
-    meStyle         = WALLPAPER_NULL;
+    meStyle         = WallpaperStyle::NONE;
 }
 
 ImplWallpaper::ImplWallpaper( const ImplWallpaper& rImplWallpaper ) :
@@ -148,7 +148,7 @@ SvStream& WriteImplWallpaper( SvStream& rOStm, const ImplWallpaper& rImplWallpap
 
     // version 1
     WriteColor( rOStm, rImplWallpaper.maColor );
-    rOStm.WriteUInt16( rImplWallpaper.meStyle );
+    rOStm.WriteUInt16( static_cast<sal_uInt16>(rImplWallpaper.meStyle) );
 
     // version 2
     rOStm.WriteBool( bRect ).WriteBool( bGrad ).WriteBool( bBmp ).WriteBool( bDummy ).WriteBool( bDummy ).WriteBool( bDummy );
@@ -207,7 +207,7 @@ Wallpaper::Wallpaper( const Color& rColor )
 
     mpImplWallpaper             = new ImplWallpaper;
     mpImplWallpaper->maColor    = rColor;
-    mpImplWallpaper->meStyle    = WALLPAPER_TILE;
+    mpImplWallpaper->meStyle    = WallpaperStyle::Tile;
 }
 
 Wallpaper::Wallpaper( const BitmapEx& rBmpEx )
@@ -215,7 +215,7 @@ Wallpaper::Wallpaper( const BitmapEx& rBmpEx )
 
     mpImplWallpaper             = new ImplWallpaper;
     mpImplWallpaper->mpBitmap   = new BitmapEx( rBmpEx );
-    mpImplWallpaper->meStyle    = WALLPAPER_TILE;
+    mpImplWallpaper->meStyle    = WallpaperStyle::Tile;
 }
 
 Wallpaper::Wallpaper( const Gradient& rGradient )
@@ -223,7 +223,7 @@ Wallpaper::Wallpaper( const Gradient& rGradient )
 
     mpImplWallpaper             = new ImplWallpaper;
     mpImplWallpaper->mpGradient = new Gradient( rGradient );
-    mpImplWallpaper->meStyle    = WALLPAPER_TILE;
+    mpImplWallpaper->meStyle    = WallpaperStyle::Tile;
 }
 
 Wallpaper::~Wallpaper()
@@ -245,8 +245,8 @@ void Wallpaper::SetColor( const Color& rColor )
     ImplMakeUnique();
     mpImplWallpaper->maColor = rColor;
 
-    if( WALLPAPER_NULL == mpImplWallpaper->meStyle || WALLPAPER_APPLICATIONGRADIENT == mpImplWallpaper->meStyle )
-        mpImplWallpaper->meStyle = WALLPAPER_TILE;
+    if( WallpaperStyle::NONE == mpImplWallpaper->meStyle || WallpaperStyle::ApplicationGradient == mpImplWallpaper->meStyle )
+        mpImplWallpaper->meStyle = WallpaperStyle::Tile;
 }
 
 const Color& Wallpaper::GetColor() const
@@ -260,7 +260,7 @@ void Wallpaper::SetStyle( WallpaperStyle eStyle )
 
     ImplMakeUnique( false );
 
-    if( eStyle == WALLPAPER_APPLICATIONGRADIENT )
+    if( eStyle == WallpaperStyle::ApplicationGradient )
         // set a dummy gradient, the correct gradient
         // will be created dynamically in GetGradient()
         SetGradient( ImplGetApplicationGradient() );
@@ -295,8 +295,8 @@ void Wallpaper::SetBitmap( const BitmapEx& rBitmap )
             mpImplWallpaper->mpBitmap = new BitmapEx( rBitmap );
     }
 
-    if( WALLPAPER_NULL == mpImplWallpaper->meStyle || WALLPAPER_APPLICATIONGRADIENT == mpImplWallpaper->meStyle)
-        mpImplWallpaper->meStyle = WALLPAPER_TILE;
+    if( WallpaperStyle::NONE == mpImplWallpaper->meStyle || WallpaperStyle::ApplicationGradient == mpImplWallpaper->meStyle)
+        mpImplWallpaper->meStyle = WallpaperStyle::Tile;
 }
 
 BitmapEx Wallpaper::GetBitmap() const
@@ -327,14 +327,14 @@ void Wallpaper::SetGradient( const Gradient& rGradient )
     else
         mpImplWallpaper->mpGradient = new Gradient( rGradient );
 
-    if( WALLPAPER_NULL == mpImplWallpaper->meStyle || WALLPAPER_APPLICATIONGRADIENT == mpImplWallpaper->meStyle )
-        mpImplWallpaper->meStyle = WALLPAPER_TILE;
+    if( WallpaperStyle::NONE == mpImplWallpaper->meStyle || WallpaperStyle::ApplicationGradient == mpImplWallpaper->meStyle )
+        mpImplWallpaper->meStyle = WallpaperStyle::Tile;
 }
 
 Gradient Wallpaper::GetGradient() const
 {
 
-    if( WALLPAPER_APPLICATIONGRADIENT == mpImplWallpaper->meStyle )
+    if( WallpaperStyle::ApplicationGradient == mpImplWallpaper->meStyle )
         return ImplGetApplicationGradient();
     else if ( mpImplWallpaper->mpGradient )
         return *(mpImplWallpaper->mpGradient);
@@ -407,7 +407,7 @@ bool Wallpaper::IsRect() const
 
 bool Wallpaper::IsFixed() const
 {
-    if ( mpImplWallpaper->meStyle == WALLPAPER_NULL )
+    if ( mpImplWallpaper->meStyle == WallpaperStyle::NONE )
         return false;
     else
         return (!mpImplWallpaper->mpBitmap && !mpImplWallpaper->mpGradient);
@@ -415,12 +415,12 @@ bool Wallpaper::IsFixed() const
 
 bool Wallpaper::IsScrollable() const
 {
-    if ( mpImplWallpaper->meStyle == WALLPAPER_NULL )
+    if ( mpImplWallpaper->meStyle == WallpaperStyle::NONE )
         return false;
     else if ( !mpImplWallpaper->mpBitmap && !mpImplWallpaper->mpGradient )
         return true;
     else if ( mpImplWallpaper->mpBitmap )
-        return (mpImplWallpaper->meStyle == WALLPAPER_TILE);
+        return (mpImplWallpaper->meStyle == WallpaperStyle::Tile);
     else
         return false;
 }
diff --git a/vcl/source/outdev/outdevstate.cxx b/vcl/source/outdev/outdevstate.cxx
index e1c6498..ad8e8ae 100644
--- a/vcl/source/outdev/outdevstate.cxx
+++ b/vcl/source/outdev/outdevstate.cxx
@@ -466,7 +466,7 @@ void OutputDevice::SetBackground( const Wallpaper& rBackground )
 
     maBackground = rBackground;
 
-    if( rBackground.GetStyle() == WALLPAPER_NULL )
+    if( rBackground.GetStyle() == WallpaperStyle::NONE )
         mbBackground = false;
     else
         mbBackground = true;
diff --git a/vcl/source/outdev/wallpaper.cxx b/vcl/source/outdev/wallpaper.cxx
index adf935a..175f0d1 100644
--- a/vcl/source/outdev/wallpaper.cxx
+++ b/vcl/source/outdev/wallpaper.cxx
@@ -36,7 +36,7 @@ void OutputDevice::DrawWallpaper( const Rectangle& rRect,
     if ( !IsDeviceOutputNecessary() || ImplIsRecordLayout() )
         return;
 
-    if ( rWallpaper.GetStyle() != WALLPAPER_NULL )
+    if ( rWallpaper.GetStyle() != WallpaperStyle::NONE )
     {
         Rectangle aRect = LogicToPixel( rRect );
         aRect.Justify();
@@ -150,7 +150,7 @@ void OutputDevice::DrawBitmapWallpaper( long nX, long nY,
             bDrawColorBackground = true;
         }
     }
-    else if( eStyle != WALLPAPER_TILE && eStyle != WALLPAPER_SCALE )
+    else if( eStyle != WallpaperStyle::Tile && eStyle != WallpaperStyle::Scale )
     {

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list