[Libreoffice-commits] core.git: officecfg/registry sw/Library_sw.mk sw/source sw/uiconfig sw/UIConfig_swriter.mk

Rishabh Kumar kris.kr296 at gmail.com
Thu May 26 09:01:31 UTC 2016


 officecfg/registry/data/org/openoffice/Office/UI/Sidebar.xcu |  162 ++++++++
 sw/Library_sw.mk                                             |    5 
 sw/UIConfig_swriter.mk                                       |    5 
 sw/source/uibase/sidebar/PageFooterPanel.cxx                 |   92 ++++
 sw/source/uibase/sidebar/PageFooterPanel.hxx                 |   92 ++++
 sw/source/uibase/sidebar/PageFormatPanel.cxx                 |  102 +++++
 sw/source/uibase/sidebar/PageFormatPanel.hxx                 |   91 ++++
 sw/source/uibase/sidebar/PageHeaderPanel.cxx                 |  137 +++++++
 sw/source/uibase/sidebar/PageHeaderPanel.hxx                 |   95 +++++
 sw/source/uibase/sidebar/PageMarginPanel.cxx                 |  207 +++++++++++
 sw/source/uibase/sidebar/PageMarginPanel.hxx                 |  113 ++++++
 sw/source/uibase/sidebar/PageStylesPanel.cxx                 |   92 ++++
 sw/source/uibase/sidebar/PageStylesPanel.hxx                 |   92 ++++
 sw/source/uibase/sidebar/SwPanelFactory.cxx                  |   50 ++
 sw/uiconfig/swriter/ui/pagefooterpanel.ui                    |  164 ++++++++
 sw/uiconfig/swriter/ui/pageformatpanel.ui                    |  115 ++++++
 sw/uiconfig/swriter/ui/pageheaderpanel.ui                    |  164 ++++++++
 sw/uiconfig/swriter/ui/pagemarginpanel.ui                    |  114 ++++++
 sw/uiconfig/swriter/ui/pagestylespanel.ui                    |  127 ++++++
 19 files changed, 2019 insertions(+)

New commits:
commit 2060543586fa01d77ed17fd7904a903313b2251e
Author: Rishabh Kumar <kris.kr296 at gmail.com>
Date:   Fri Aug 21 18:24:28 2015 +0530

    tdf#83830: Writer page sidebar deck
    
    Change-Id: I6eb16a5a721fad28aa7822b0ca8d7c06a0c08541
    Reviewed-on: https://gerrit.libreoffice.org/17904
    Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
    Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>

diff --git a/officecfg/registry/data/org/openoffice/Office/UI/Sidebar.xcu b/officecfg/registry/data/org/openoffice/Office/UI/Sidebar.xcu
index 80bfad7..776782e 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/Sidebar.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/Sidebar.xcu
@@ -41,6 +41,28 @@
         </prop>
       </node>
 
+      <node oor:name="WriterPageDeck" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Properties</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="IconURL" oor:type="xs:string">
+          <value>private:graphicrepository/sfx2/res/symphony/sidebar-template-large.png</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            any, any, visible ;
+          </value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>100</value>
+        </prop>
+        <prop oor:name="IsExperimental" oor:type="xs:boolean">
+          <value>true</value>
+        </prop>
+      </node>
       <node oor:name="GalleryDeck" oor:op="replace">
         <prop oor:name="Title" oor:type="xs:string">
           <value xml:lang="en-US">Gallery</value>
@@ -357,6 +379,146 @@
         </prop>
       </node>
 
+      <node oor:name="PageStylesPanel" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Styles</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>PageStylesPanel</value>
+        </prop>
+        <prop oor:name="DeckId" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="DefaultMenuCommand">
+          <value>.uno:PageDialog</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            Writer, Table,    visible ;
+            Writer, Text,     visible ;
+            Writer, default,  visible ;
+          </value>
+        </prop>
+        <prop oor:name="ImplementationURL" oor:type="xs:string">
+          <value>private:resource/toolpanel/SwPanelFactory/PageStylesPanel</value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>200</value>
+        </prop>
+      </node>
+
+      <node oor:name="PageMarginPanel" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Margin</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>PageMarginPanel</value>
+        </prop>
+        <prop oor:name="DeckId" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="DefaultMenuCommand">
+          <value>.uno:PageDialog</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            Writer, Table,    visible ;
+            Writer, Text,     visible ;
+            Writer, default,  visible ;
+          </value>
+        </prop>
+        <prop oor:name="ImplementationURL" oor:type="xs:string">
+          <value>private:resource/toolpanel/SwPanelFactory/PageMarginPanel</value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>300</value>
+        </prop>
+      </node>
+
+      <node oor:name="PageFormatPanel" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Format</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>PageFormatPanel</value>
+        </prop>
+        <prop oor:name="DeckId" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="DefaultMenuCommand">
+          <value>.uno:PageDialog</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            Writer, Table,    visible ;
+            Writer, Text,     visible ;
+            Writer, default,  visible ;
+          </value>
+        </prop>
+        <prop oor:name="ImplementationURL" oor:type="xs:string">
+          <value>private:resource/toolpanel/SwPanelFactory/PageFormatPanel</value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>100</value>
+        </prop>
+      </node>
+
+      <node oor:name="PageHeaderPanel" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Header</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>PageHeaderPanel</value>
+        </prop>
+        <prop oor:name="DeckId" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="DefaultMenuCommand">
+          <value>.uno:PageDialog</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            Writer, Table,    hidden ;
+            Writer, Text,     hidden ;
+            Writer, default,  hidden ;
+          </value>
+        </prop>
+        <prop oor:name="ImplementationURL" oor:type="xs:string">
+          <value>private:resource/toolpanel/SwPanelFactory/PageHeaderPanel</value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>400</value>
+        </prop>
+      </node>
+
+      <node oor:name="PageFooterPanel" oor:op="replace">
+        <prop oor:name="Title" oor:type="xs:string">
+          <value xml:lang="en-US">Footer</value>
+        </prop>
+        <prop oor:name="Id" oor:type="xs:string">
+          <value>PageFooterPanel</value>
+        </prop>
+        <prop oor:name="DeckId" oor:type="xs:string">
+          <value>WriterPageDeck</value>
+        </prop>
+        <prop oor:name="DefaultMenuCommand">
+          <value>.uno:PageDialog</value>
+        </prop>
+        <prop oor:name="ContextList">
+          <value oor:separator=";">
+            Writer, Table,    hidden ;
+            Writer, Text,     hidden ;
+            Writer, default,  hidden ;
+          </value>
+        </prop>
+        <prop oor:name="ImplementationURL" oor:type="xs:string">
+          <value>private:resource/toolpanel/SwPanelFactory/PageFooterPanel</value>
+        </prop>
+        <prop oor:name="OrderIndex" oor:type="xs:int">
+          <value>500</value>
+        </prop>
+      </node>
+
       <node oor:name="AreaPropertyPanel" oor:op="replace">
         <prop oor:name="Title" oor:type="xs:string">
           <value xml:lang="en-US">Area</value>
diff --git a/sw/Library_sw.mk b/sw/Library_sw.mk
index 3d130cd..bb2d680 100644
--- a/sw/Library_sw.mk
+++ b/sw/Library_sw.mk
@@ -681,6 +681,11 @@ $(eval $(call gb_Library_add_exception_objects,sw,\
     sw/source/uibase/sidebar/PageSizeControl \
     sw/source/uibase/sidebar/PageColumnControl \
     sw/source/uibase/sidebar/PagePropertyPanel \
+    sw/source/uibase/sidebar/PageMarginPanel \
+    sw/source/uibase/sidebar/PageFormatPanel \
+    sw/source/uibase/sidebar/PageHeaderPanel \
+    sw/source/uibase/sidebar/PageFooterPanel \
+    sw/source/uibase/sidebar/PageStylesPanel \
     sw/source/uibase/sidebar/WrapPropertyPanel \
     sw/source/uibase/sidebar/ThemePanel \
     sw/source/uibase/sidebar/SwPanelFactory \
diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index f1e5dc8..43e66ae 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -225,6 +225,11 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
 	sw/uiconfig/swriter/ui/selectindexdialog \
 	sw/uiconfig/swriter/ui/selecttabledialog \
 	sw/uiconfig/swriter/ui/sidebarpage \
+	sw/uiconfig/swriter/ui/pagemarginpanel \
+	sw/uiconfig/swriter/ui/pageformatpanel \
+	sw/uiconfig/swriter/ui/pagestylespanel \
+	sw/uiconfig/swriter/ui/pageheaderpanel \
+	sw/uiconfig/swriter/ui/pagefooterpanel \
 	sw/uiconfig/swriter/ui/sidebarwrap \
 	sw/uiconfig/swriter/ui/sidebarstylepresets \
     sw/uiconfig/swriter/ui/sidebartheme \
diff --git a/sw/source/uibase/sidebar/PageFooterPanel.cxx b/sw/source/uibase/sidebar/PageFooterPanel.cxx
new file mode 100644
index 0000000..b492230
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageFooterPanel.cxx
@@ -0,0 +1,92 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#include <sal/config.h>
+#include <swtypes.hxx>
+#include <svl/intitem.hxx>
+#include <editeng/sizeitem.hxx>
+#include <editeng/paperinf.hxx>
+#include <svx/svxids.hrc>
+#include <svx/dlgutil.hxx>
+#include <svx/rulritem.hxx>
+#include "PageFooterPanel.hxx"
+#include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/objsh.hxx>
+#include "cmdid.h"
+#include <com/sun/star/frame/XController.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/document/XUndoManagerSupplier.hpp>
+
+namespace sw { namespace sidebar{
+
+VclPtr<vcl::Window> PageFooterPanel::Create(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings)
+{
+    if( pParent == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageFooterPanel::Create", NULL, 0);
+    if( !rxFrame.is() )
+        throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PageFooterPanel::Create", NULL, 0);
+    if( pBindings == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageFooterPanel::Create", NULL, 0);
+
+    return VclPtr<PageFooterPanel>::Create(pParent, rxFrame, pBindings);
+}
+
+PageFooterPanel::PageFooterPanel(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings
+    ) :
+    PanelLayout(pParent, "PageFooterPanel", "modules/swriter/ui/pagefooterpanel.ui", rxFrame),
+    mpBindings( pBindings )
+{
+    Initialize();
+}
+
+PageFooterPanel::~PageFooterPanel()
+{
+    disposeOnce();
+}
+
+void PageFooterPanel::dispose()
+{
+    PanelLayout::dispose();
+}
+
+void PageFooterPanel::Initialize()
+{
+
+}
+
+void PageFooterPanel::NotifyItemUpdate(
+    const sal_uInt16 /*nSid*/,
+    const SfxItemState /*eState*/,
+    const SfxPoolItem* /*pState*/,
+    const bool /*bIsEnabled*/)
+{
+
+}
+
+} }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageFooterPanel.hxx b/sw/source/uibase/sidebar/PageFooterPanel.hxx
new file mode 100644
index 0000000..f02a7d8
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageFooterPanel.hxx
@@ -0,0 +1,92 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEFOOTERPANEL_HXX
+#define INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEFOOTERPANEL_HXX
+
+#include <com/sun/star/frame/XFrame.hpp>
+#include <com/sun/star/document/XUndoManager.hpp>
+
+#include <svx/sidebar/Popup.hxx>
+#include <svx/sidebar/PanelLayout.hxx>
+
+#include <sfx2/sidebar/ControllerItem.hxx>
+
+#include <i18nutil/paper.hxx>
+
+#include <svx/pageitem.hxx>
+#include <svx/rulritem.hxx>
+#include <editeng/sizeitem.hxx>
+
+#include <vcl/ctrl.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/button.hxx>
+#include <vcl/toolbox.hxx>
+#include <vcl/lstbox.hxx>
+#include <vcl/field.hxx>
+#include <svl/intitem.hxx>
+#include <tools/fldunit.hxx>
+#include <svl/poolitem.hxx>
+#include <svx/rulritem.hxx>
+
+namespace sw { namespace sidebar {
+
+class PageFooterPanel:
+    public PanelLayout,
+    public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
+{
+public:
+    static VclPtr<vcl::Window> Create(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+
+    virtual void NotifyItemUpdate(
+        const sal_uInt16 nSId,
+        const SfxItemState eState,
+        const SfxPoolItem* pState,
+        const bool bIsEnabled);
+
+    SfxBindings* GetBindings() const { return mpBindings; }
+    PageFooterPanel(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+    virtual ~PageFooterPanel();
+    virtual void dispose();
+
+private:
+
+    SfxBindings* mpBindings;
+
+    VclPtr<CheckBox> mpFooterToggle;
+    VclPtr<MetricField> mpFooterHeightField;
+    VclPtr<MetricField> mpFooterLMargin;
+    VclPtr<MetricField> mpFooterRMargin;
+    VclPtr<MetricField> mpFooterSpacing;
+    VclPtr<ListBox> mpSameContentLB;
+
+    void Initialize();
+
+};
+
+} } //end of namespace sw::sidebar
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageFormatPanel.cxx b/sw/source/uibase/sidebar/PageFormatPanel.cxx
new file mode 100644
index 0000000..165d5d3
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageFormatPanel.cxx
@@ -0,0 +1,102 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#include <sal/config.h>
+#include <swtypes.hxx>
+#include <svl/intitem.hxx>
+#include <editeng/sizeitem.hxx>
+#include <editeng/paperinf.hxx>
+#include <svx/svxids.hrc>
+#include <svx/dlgutil.hxx>
+#include <svx/rulritem.hxx>
+#include "PageFormatPanel.hxx"
+#include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/objsh.hxx>
+#include "cmdid.h"
+#include <com/sun/star/frame/XController.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/document/XUndoManagerSupplier.hpp>
+
+namespace sw { namespace sidebar{
+
+VclPtr<vcl::Window> PageFormatPanel::Create(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings)
+{
+    if( pParent == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageFormatPanel::Create", NULL, 0);
+    if( !rxFrame.is() )
+        throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PageFormatPanel::Create", NULL, 0);
+    if( pBindings == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageFormatPanel::Create", NULL, 0);
+
+    return VclPtr<PageFormatPanel>::Create(pParent, rxFrame, pBindings);
+}
+
+PageFormatPanel::PageFormatPanel(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings
+    ) :
+    PanelLayout(pParent, "PageFormatPanel", "modules/swriter/ui/pageformatpanel.ui", rxFrame),
+    mpBindings( pBindings )
+{
+    get(mpPaperSizeLB, "papersize");
+    get(mpPaperWidth, "paperwidth");
+    get(mpPaperHeight, "paperheight");
+    get(mpPaperOrientation, "paperorientation");
+
+    Initialize();
+}
+
+PageFormatPanel::~PageFormatPanel()
+{
+    disposeOnce();
+}
+
+void PageFormatPanel::dispose()
+{
+    mpPaperSizeLB.disposeAndClear();
+    mpPaperWidth.disposeAndClear();
+    mpPaperHeight.disposeAndClear();
+    mpPaperOrientation.disposeAndClear();
+
+    PanelLayout::dispose();
+}
+
+void PageFormatPanel::Initialize()
+{
+
+}
+
+void PageFormatPanel::NotifyItemUpdate(
+    const sal_uInt16 /*nSid*/,
+    const SfxItemState /*eState*/,
+    const SfxPoolItem* /*pState*/,
+    const bool /*bIsEnabled*/)
+{
+
+}
+
+} }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageFormatPanel.hxx b/sw/source/uibase/sidebar/PageFormatPanel.hxx
new file mode 100644
index 0000000..c6797e4
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageFormatPanel.hxx
@@ -0,0 +1,91 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEFORMATPANEL_HXX
+#define INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEFORMATPANEL_HXX
+
+#include <com/sun/star/frame/XFrame.hpp>
+#include <com/sun/star/document/XUndoManager.hpp>
+
+#include <svx/sidebar/Popup.hxx>
+#include <svx/sidebar/PanelLayout.hxx>
+
+#include <sfx2/sidebar/ControllerItem.hxx>
+
+#include <i18nutil/paper.hxx>
+
+#include <svx/pageitem.hxx>
+#include <svx/rulritem.hxx>
+#include <editeng/sizeitem.hxx>
+
+#include <vcl/ctrl.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/button.hxx>
+#include <vcl/toolbox.hxx>
+#include <vcl/lstbox.hxx>
+#include <vcl/field.hxx>
+#include <svl/intitem.hxx>
+#include <tools/fldunit.hxx>
+#include <svl/poolitem.hxx>
+#include <svx/rulritem.hxx>
+
+namespace sw { namespace sidebar {
+
+class PageFormatPanel:
+    public PanelLayout,
+    public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
+{
+public:
+    static VclPtr<vcl::Window> Create(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+
+    virtual void NotifyItemUpdate(
+        const sal_uInt16 nSId,
+        const SfxItemState eState,
+        const SfxPoolItem* pState,
+        const bool bIsEnabled);
+
+    SfxBindings* GetBindings() const { return mpBindings; }
+
+    PageFormatPanel(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+    virtual ~PageFormatPanel();
+    virtual void dispose();
+
+private:
+
+    SfxBindings* mpBindings;
+
+    VclPtr<ListBox> mpPaperSizeLB;
+    VclPtr<MetricField> mpPaperWidth;
+    VclPtr<MetricField> mpPaperHeight;
+    VclPtr<ListBox> mpPaperOrientation;
+
+    void Initialize();
+
+};
+
+} } //end of namespace sw::sidebar
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageHeaderPanel.cxx b/sw/source/uibase/sidebar/PageHeaderPanel.cxx
new file mode 100644
index 0000000..907961b
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageHeaderPanel.cxx
@@ -0,0 +1,137 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#include <sal/config.h>
+#include <swtypes.hxx>
+#include <svl/intitem.hxx>
+#include <svl/eitem.hxx>
+#include <editeng/sizeitem.hxx>
+#include <editeng/paperinf.hxx>
+#include <svx/svxids.hrc>
+#include <svx/dlgutil.hxx>
+#include <svx/rulritem.hxx>
+#include "PageHeaderPanel.hxx"
+#include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/objsh.hxx>
+#include "cmdid.h"
+#include <com/sun/star/frame/XController.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/document/XUndoManagerSupplier.hpp>
+
+namespace sw { namespace sidebar{
+
+VclPtr<vcl::Window> PageHeaderPanel::Create(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings)
+{
+    if( pParent == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageHeaderPanel::Create", NULL, 0);
+    if( !rxFrame.is() )
+        throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PageHeaderPanel::Create", NULL, 0);
+    if( pBindings == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageHeaderPanel::Create", NULL, 0);
+
+    return VclPtr<PageHeaderPanel>::Create(pParent, rxFrame, pBindings);
+}
+
+PageHeaderPanel::PageHeaderPanel(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings
+    ) :
+    PanelLayout(pParent, "PageHeaderPanel", "modules/swriter/ui/pageheaderpanel.ui", rxFrame),
+    mpBindings( pBindings )
+{
+    get(mpHeaderToggle, "headertoggle");
+    get(mpHeaderHeightField, "heightspinfield");
+    get(mpHeaderLMargin, "leftmargin");
+    get(mpHeaderRMargin, "rightmargin");
+    get(mpHeaderSpacing, "spacingspinfield");
+    get(mpSameContentLB, "samecontentLB");
+
+    Initialize();
+}
+
+PageHeaderPanel::~PageHeaderPanel()
+{
+    disposeOnce();
+}
+
+void PageHeaderPanel::dispose()
+{
+    mpHeaderToggle.disposeAndClear();
+    mpHeaderHeightField.disposeAndClear();
+    mpHeaderLMargin.disposeAndClear();
+    mpHeaderRMargin.disposeAndClear();
+    mpHeaderSpacing.disposeAndClear();
+    mpSameContentLB.disposeAndClear();
+
+    PanelLayout::dispose();
+}
+
+void PageHeaderPanel::Initialize()
+{
+    mpHeaderToggle->SetClickHdl( LINK(this, PageHeaderPanel, HeaderToggleHdl) );
+}
+
+void PageHeaderPanel::UpdateControls()
+{
+    bool bIsEnabled = (bool)mpHeaderToggle->IsChecked();
+    if(bIsEnabled)
+    {
+        mpHeaderHeightField->Enable();
+        mpHeaderLMargin->Enable();
+        mpHeaderRMargin->Enable();
+        mpHeaderSpacing->Enable();
+        mpSameContentLB->Enable();
+    }
+    else
+    {
+        mpHeaderHeightField->Disable();
+        mpHeaderLMargin->Disable();
+        mpHeaderRMargin->Disable();
+        mpHeaderSpacing->Disable();
+        mpSameContentLB->Disable();
+    }
+}
+
+void PageHeaderPanel::NotifyItemUpdate(
+    const sal_uInt16 /*nSid*/,
+    const SfxItemState /*eState*/,
+    const SfxPoolItem* /*pState*/,
+    const bool /*bIsEnabled*/)
+{
+}
+
+IMPL_LINK_NOARG_TYPED( PageHeaderPanel, HeaderToggleHdl, Button*, void )
+{
+    bool IsChecked = mpHeaderToggle->IsChecked();
+    SfxBoolItem aItem(SID_ATTR_PAGE_ON, IsChecked);
+    GetBindings()->GetDispatcher()->ExecuteList( SID_ATTR_PAGE_HEADERSET, SfxCallMode::RECORD, { &aItem } );
+    UpdateControls();
+}
+
+
+
+} }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageHeaderPanel.hxx b/sw/source/uibase/sidebar/PageHeaderPanel.hxx
new file mode 100644
index 0000000..46222ae
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageHeaderPanel.hxx
@@ -0,0 +1,95 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEHEADERPANEL_HXX
+#define INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEHEADERPANEL_HXX
+
+#include <com/sun/star/frame/XFrame.hpp>
+#include <com/sun/star/document/XUndoManager.hpp>
+
+#include <svx/sidebar/Popup.hxx>
+#include <svx/sidebar/PanelLayout.hxx>
+
+#include <sfx2/sidebar/ControllerItem.hxx>
+
+#include <i18nutil/paper.hxx>
+
+#include <svx/pageitem.hxx>
+#include <svx/rulritem.hxx>
+#include <editeng/sizeitem.hxx>
+
+#include <vcl/ctrl.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/button.hxx>
+#include <vcl/toolbox.hxx>
+#include <vcl/lstbox.hxx>
+#include <vcl/field.hxx>
+#include <svl/intitem.hxx>
+#include <tools/fldunit.hxx>
+#include <svl/poolitem.hxx>
+#include <svx/rulritem.hxx>
+
+namespace sw { namespace sidebar {
+
+class PageHeaderPanel:
+    public PanelLayout,
+    public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
+{
+public:
+    static VclPtr<vcl::Window> Create(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+
+    virtual void NotifyItemUpdate(
+        const sal_uInt16 nSId,
+        const SfxItemState eState,
+        const SfxPoolItem* pState,
+        const bool bIsEnabled);
+
+    SfxBindings* GetBindings() const { return mpBindings; }
+    PageHeaderPanel(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+    virtual ~PageHeaderPanel();
+    virtual void dispose();
+
+private:
+
+    SfxBindings* mpBindings;
+
+    VclPtr<CheckBox> mpHeaderToggle;
+    VclPtr<MetricField> mpHeaderHeightField;
+    VclPtr<MetricField> mpHeaderLMargin;
+    VclPtr<MetricField> mpHeaderRMargin;
+    VclPtr<MetricField> mpHeaderSpacing;
+    VclPtr<ListBox> mpSameContentLB;
+
+    void Initialize();
+    void UpdateControls();
+
+    DECL_LINK_TYPED( HeaderToggleHdl, Button*, void );
+
+};
+
+} } //end of namespace sw::sidebar
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageMarginPanel.cxx b/sw/source/uibase/sidebar/PageMarginPanel.cxx
new file mode 100644
index 0000000..2bb5127
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageMarginPanel.cxx
@@ -0,0 +1,207 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#include <sal/config.h>
+#include <swtypes.hxx>
+#include <svl/intitem.hxx>
+#include <editeng/sizeitem.hxx>
+#include <editeng/paperinf.hxx>
+#include <svx/svxids.hrc>
+#include <svx/dlgutil.hxx>
+#include <svx/rulritem.hxx>
+#include "PageMarginPanel.hxx"
+#include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/objsh.hxx>
+#include "cmdid.h"
+#include <com/sun/star/frame/XController.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/document/XUndoManagerSupplier.hpp>
+
+namespace sw { namespace sidebar{
+
+VclPtr<vcl::Window> PageMarginPanel::Create(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings)
+{
+    if( pParent == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageMarginPanel::Create", NULL, 0);
+    if( !rxFrame.is() )
+        throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PageMarginPanel::Create", NULL, 0);
+    if( pBindings == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageMarginPanel::Create", NULL, 0);
+
+    return VclPtr<PageMarginPanel>::Create(pParent, rxFrame, pBindings);
+}
+
+PageMarginPanel::PageMarginPanel(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings
+    ) :
+    PanelLayout(pParent, "PageMarginPanel" , "modules/swriter/ui/pagemarginpanel.ui", rxFrame),
+    mpBindings(pBindings),
+    meFUnit(),
+    meUnit(),
+    mpPageLRMarginItem( new SvxLongLRSpaceItem( 0, 0, SID_ATTR_PAGE_LRSPACE ) ),
+    mpPageULMarginItem( new SvxLongULSpaceItem( 0, 0, SID_ATTR_PAGE_ULSPACE ) ),
+    maSwPageLRControl(SID_ATTR_PAGE_LRSPACE, *pBindings, *this),
+    maSwPageULControl(SID_ATTR_PAGE_ULSPACE, *pBindings, *this),
+    maSwPageSizeControl(SID_ATTR_PAGE_SIZE, *pBindings, *this),
+    maSwPageMetricControl(SID_ATTR_METRIC, *pBindings, *this)
+{
+    get(mpLeftMarginEdit, "leftmargin");
+    get(mpRightMarginEdit, "rightmargin");
+    get(mpTopMarginEdit, "topmargin");
+    get(mpBottomMarginEdit, "bottommargin");
+
+    Initialize();
+}
+
+PageMarginPanel::~PageMarginPanel()
+{
+    disposeOnce();
+}
+
+void PageMarginPanel::dispose()
+{
+
+    mpLeftMarginEdit.disposeAndClear();
+    mpRightMarginEdit.disposeAndClear();
+    mpTopMarginEdit.disposeAndClear();
+    mpBottomMarginEdit.disposeAndClear();
+
+    mpPageLRMarginItem.reset();
+    mpPageULMarginItem.reset();
+
+    maSwPageULControl.dispose();
+    maSwPageLRControl.dispose();
+    maSwPageSizeControl.dispose();
+    maSwPageMetricControl.dispose();
+
+    PanelLayout::dispose();
+}
+
+void PageMarginPanel::Initialize()
+{
+    meUnit = maSwPageSizeControl.GetCoreMetric();
+    mpLeftMarginEdit->SetModifyHdl( LINK(this, PageMarginPanel, ModifyLRMarginHdl) );
+    mpRightMarginEdit->SetModifyHdl( LINK(this, PageMarginPanel, ModifyLRMarginHdl) );
+    mpTopMarginEdit->SetModifyHdl( LINK(this, PageMarginPanel, ModifyULMarginHdl) );
+    mpBottomMarginEdit->SetModifyHdl( LINK(this, PageMarginPanel, ModifyULMarginHdl) );
+}
+
+void PageMarginPanel::MetricState( SfxItemState eState, const SfxPoolItem* pState )
+{
+    meFUnit = FUNIT_NONE;
+    if ( pState && eState >= SfxItemState::DEFAULT )
+    {
+        meFUnit = (FieldUnit)static_cast<const SfxUInt16Item*>(pState )->GetValue();
+    }
+    else
+    {
+        SfxViewFrame* pFrame = SfxViewFrame::Current();
+        SfxObjectShell* pSh = NULL;
+        if ( pFrame )
+            pSh = pFrame->GetObjectShell();
+        if ( pSh )
+        {
+            SfxModule* pModule = pSh->GetModule();
+            if ( pModule )
+            {
+                const SfxPoolItem* pItem = pModule->GetItem( SID_ATTR_METRIC );
+                if ( pItem )
+                    meFUnit = (FieldUnit)static_cast<const SfxUInt16Item*>(pItem )->GetValue();
+            }
+            else
+            {
+                SAL_WARN("sw.ui", "<PageMarginPanel::MetricState(..)>: no module found");
+            }
+        }
+    }
+/*
+    SetFieldUnit( *mpLeftMarginEdit.get(), meFUnit );
+    SetFieldUnit( *mpRightMarginEdit.get(), meFUnit );
+    SetFieldUnit( *mpTopMarginEdit.get(), meFUnit );
+    SetFieldUnit( *mpBottomMarginEdit.get(), meFUnit );
+*/
+}
+
+void PageMarginPanel::ExecuteMarginLRChange(
+    const long nPageLeftMargin,
+    const long nPageRightMargin )
+{
+    mpPageLRMarginItem->SetLeft( nPageLeftMargin );
+    mpPageLRMarginItem->SetRight( nPageRightMargin );
+    GetBindings()->GetDispatcher()->ExecuteList( SID_ATTR_PAGE_LRSPACE, SfxCallMode::RECORD, { mpPageLRMarginItem.get() });
+}
+
+void PageMarginPanel::ExecuteMarginULChange(
+    const long nPageTopMargin,
+    const long nPageBottomMargin )
+{
+    mpPageULMarginItem->SetUpper( nPageTopMargin );
+    mpPageULMarginItem->SetLower( nPageBottomMargin );
+    GetBindings()->GetDispatcher()->ExecuteList( SID_ATTR_PAGE_ULSPACE, SfxCallMode::RECORD, { mpPageULMarginItem.get() });
+}
+
+void PageMarginPanel::NotifyItemUpdate(
+    const sal_uInt16 nSId,
+    const SfxItemState eState,
+    const SfxPoolItem* pState,
+    const bool bIsEnabled)
+{
+    (void)bIsEnabled;
+    switch( nSId )
+    {
+        case SID_ATTR_PAGE_LRSPACE:
+        {
+        }
+        break;
+        case SID_ATTR_PAGE_ULSPACE:
+        {
+        }
+        break;
+        case SID_ATTR_METRIC:
+            MetricState(eState, pState);
+        break;
+    }
+}
+
+
+
+IMPL_LINK_NOARG_TYPED( PageMarginPanel, ModifyLRMarginHdl, Edit&, void )
+{
+    mnPageLeftMargin = GetCoreValue( *mpLeftMarginEdit.get(), meUnit );
+    mnPageRightMargin = GetCoreValue( *mpRightMarginEdit.get(), meUnit );
+    ExecuteMarginLRChange( mnPageLeftMargin, mnPageRightMargin );
+}
+
+IMPL_LINK_NOARG_TYPED( PageMarginPanel, ModifyULMarginHdl, Edit&, void )
+{
+    mnPageTopMargin = GetCoreValue( *mpTopMarginEdit.get(), meUnit );
+    mnPageBottomMargin = GetCoreValue( *mpBottomMarginEdit.get(), meUnit );
+    ExecuteMarginULChange( mnPageTopMargin, mnPageBottomMargin );
+}
+
+} }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageMarginPanel.hxx b/sw/source/uibase/sidebar/PageMarginPanel.hxx
new file mode 100644
index 0000000..3ad17c4
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageMarginPanel.hxx
@@ -0,0 +1,113 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEMARGINPANEL_HXX
+#define INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGEMARGINPANEL_HXX
+
+#include <com/sun/star/frame/XFrame.hpp>
+#include <com/sun/star/document/XUndoManager.hpp>
+
+#include <svx/sidebar/Popup.hxx>
+#include <svx/sidebar/PanelLayout.hxx>
+
+#include <sfx2/sidebar/ControllerItem.hxx>
+
+#include <i18nutil/paper.hxx>
+
+#include <svx/pageitem.hxx>
+#include <svx/rulritem.hxx>
+#include <editeng/sizeitem.hxx>
+
+#include <vcl/ctrl.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/button.hxx>
+#include <vcl/toolbox.hxx>
+#include <vcl/lstbox.hxx>
+#include <vcl/field.hxx>
+#include <svl/intitem.hxx>
+#include <tools/fldunit.hxx>
+#include <svl/poolitem.hxx>
+#include <svx/rulritem.hxx>
+
+namespace sw { namespace sidebar {
+
+class PageMarginPanel:
+    public PanelLayout,
+    public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
+{
+public:
+    static VclPtr<vcl::Window> Create(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+
+    virtual void NotifyItemUpdate(
+        const sal_uInt16 nSID,
+        const SfxItemState eState,
+        const SfxPoolItem* pState,
+        const bool bIsEnabled);
+
+    SfxBindings* GetBindings() const { return mpBindings; }
+
+    PageMarginPanel(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+    virtual ~PageMarginPanel();
+    virtual void dispose();
+
+private:
+
+    SfxBindings* mpBindings;
+
+    VclPtr<MetricField> mpLeftMarginEdit;
+    VclPtr<MetricField> mpRightMarginEdit;
+    VclPtr<MetricField> mpTopMarginEdit;
+    VclPtr<MetricField> mpBottomMarginEdit;
+
+    FieldUnit meFUnit;
+    SfxMapUnit meUnit;
+
+    long mnPageLeftMargin;
+    long mnPageRightMargin;
+    long mnPageTopMargin;
+    long mnPageBottomMargin;
+
+    void Initialize();
+    void ExecuteMarginLRChange( const long nPageLeftMargin, const long nPageRightMargin );
+    void ExecuteMarginULChange( const long nPageTopMargin, const long  nPageBottomMargin);
+    void MetricState( SfxItemState eState, const SfxPoolItem* pState );
+
+    std::unique_ptr<SvxLongLRSpaceItem> mpPageLRMarginItem;
+    std::unique_ptr<SvxLongULSpaceItem> mpPageULMarginItem;
+
+    ::sfx2::sidebar::ControllerItem maSwPageLRControl;
+    ::sfx2::sidebar::ControllerItem maSwPageULControl;
+    ::sfx2::sidebar::ControllerItem maSwPageSizeControl;
+    ::sfx2::sidebar::ControllerItem maSwPageMetricControl;
+
+    DECL_LINK_TYPED( ModifyLRMarginHdl, Edit&, void );
+    DECL_LINK_TYPED( ModifyULMarginHdl, Edit&, void );
+
+};
+
+} } // end of namespace sw::sidebar
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageStylesPanel.cxx b/sw/source/uibase/sidebar/PageStylesPanel.cxx
new file mode 100644
index 0000000..0e10e917
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageStylesPanel.cxx
@@ -0,0 +1,92 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#include <sal/config.h>
+#include <swtypes.hxx>
+#include <svl/intitem.hxx>
+#include <editeng/sizeitem.hxx>
+#include <editeng/paperinf.hxx>
+#include <svx/svxids.hrc>
+#include <svx/dlgutil.hxx>
+#include <svx/rulritem.hxx>
+#include "PageStylesPanel.hxx"
+#include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/objsh.hxx>
+#include "cmdid.h"
+#include <com/sun/star/frame/XController.hpp>
+#include <com/sun/star/frame/XModel.hpp>
+#include <com/sun/star/document/XUndoManagerSupplier.hpp>
+
+namespace sw { namespace sidebar{
+
+VclPtr<vcl::Window> PageStylesPanel::Create(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings)
+{
+    if( pParent == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageStylesPanel::Create", NULL, 0);
+    if( !rxFrame.is() )
+        throw ::com::sun::star::lang::IllegalArgumentException("no XFrame given to PageStylesPanel::Create", NULL, 0);
+    if( pBindings == NULL )
+        throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageStylesPanel::Create", NULL, 0);
+
+    return VclPtr<PageStylesPanel>::Create(pParent, rxFrame, pBindings);
+}
+
+PageStylesPanel::PageStylesPanel(
+    vcl::Window* pParent,
+    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+    SfxBindings* pBindings
+    ) :
+    PanelLayout(pParent, "PageStylesPanel", "modules/swriter/ui/pagestylespanel.ui", rxFrame),
+    mpBindings( pBindings )
+{
+    Initialize();
+}
+
+PageStylesPanel::~PageStylesPanel()
+{
+    disposeOnce();
+}
+
+void PageStylesPanel::dispose()
+{
+    PanelLayout::dispose();
+}
+
+void PageStylesPanel::Initialize()
+{
+
+}
+
+void PageStylesPanel::NotifyItemUpdate(
+    const sal_uInt16 /*nSid*/,
+    const SfxItemState /*eState*/,
+    const SfxPoolItem* /*pState*/,
+    const bool /*bIsEnabled*/)
+{
+
+}
+
+} }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/PageStylesPanel.hxx b/sw/source/uibase/sidebar/PageStylesPanel.hxx
new file mode 100644
index 0000000..8216937
--- /dev/null
+++ b/sw/source/uibase/sidebar/PageStylesPanel.hxx
@@ -0,0 +1,92 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGESTYLESPANEL_HXX
+#define INCLUDED_SW_SOURCE_UIBASE_SIDEBAR_PAGESTYLESPANEL_HXX
+
+#include <com/sun/star/frame/XFrame.hpp>
+#include <com/sun/star/document/XUndoManager.hpp>
+
+#include <svx/sidebar/Popup.hxx>
+#include <svx/sidebar/PanelLayout.hxx>
+
+#include <sfx2/sidebar/ControllerItem.hxx>
+
+#include <i18nutil/paper.hxx>
+
+#include <svx/pageitem.hxx>
+#include <svx/rulritem.hxx>
+#include <editeng/sizeitem.hxx>
+
+#include <vcl/ctrl.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/button.hxx>
+#include <vcl/toolbox.hxx>
+#include <vcl/lstbox.hxx>
+#include <vcl/field.hxx>
+#include <svl/intitem.hxx>
+#include <tools/fldunit.hxx>
+#include <svl/poolitem.hxx>
+#include <svx/rulritem.hxx>
+
+namespace sw { namespace sidebar {
+
+class PageStylesPanel:
+    public PanelLayout,
+    public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
+{
+public:
+    static VclPtr<vcl::Window> Create(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+
+    virtual void NotifyItemUpdate(
+        const sal_uInt16 nSId,
+        const SfxItemState eState,
+        const SfxPoolItem* pState,
+        const bool bIsEnabled);
+
+    SfxBindings* GetBindings() const { return mpBindings; }
+    PageStylesPanel(
+        vcl::Window* pParent,
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxFrame,
+        SfxBindings* pBindings);
+    virtual ~PageStylesPanel();
+    virtual void dispose();
+
+private:
+
+    SfxBindings* mpBindings;
+
+    VclPtr<CheckBox> mpFooterToggle;
+    VclPtr<MetricField> mpFooterHeightField;
+    VclPtr<MetricField> mpFooterLMargin;
+    VclPtr<MetricField> mpFooterRMargin;
+    VclPtr<MetricField> mpFooterSpacing;
+    VclPtr<ListBox> mpSameContentLB;
+
+    void Initialize();
+
+};
+
+} } //end of namespace sw::sidebar
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/sidebar/SwPanelFactory.cxx b/sw/source/uibase/sidebar/SwPanelFactory.cxx
index ed9263b..e7f1151 100644
--- a/sw/source/uibase/sidebar/SwPanelFactory.cxx
+++ b/sw/source/uibase/sidebar/SwPanelFactory.cxx
@@ -22,6 +22,11 @@
 #include <ThemePanel.hxx>
 #include <StylePresetsPanel.hxx>
 #include <PagePropertyPanel.hxx>
+#include <PageMarginPanel.hxx>
+#include <PageStylesPanel.hxx>
+#include <PageFormatPanel.hxx>
+#include <PageHeaderPanel.hxx>
+#include <PageFooterPanel.hxx>
 #include <WrapPropertyPanel.hxx>
 #include <navipi.hxx>
 #include <redlndlg.hxx>
@@ -129,6 +134,51 @@ Reference<ui::XUIElement> SAL_CALL SwPanelFactory::createUIElement (
             pPanel,
             ui::LayoutSize(-1,-1,-1));
     }
+    else if(rsResourceURL.endsWith("/PageMarginPanel"))
+    {
+        VclPtr<vcl::Window> pPanel = sw::sidebar::PageMarginPanel::Create( pParentWindow, xFrame, pBindings );
+        xElement = sfx2::sidebar::SidebarPanelBase::Create(
+            rsResourceURL,
+            xFrame,
+            pPanel,
+            ui::LayoutSize(-1,-1,-1));
+    }
+    else if(rsResourceURL.endsWith("/PageStylesPanel"))
+    {
+        VclPtr<vcl::Window> pPanel = sw::sidebar::PageStylesPanel::Create( pParentWindow, xFrame, pBindings );
+        xElement = sfx2::sidebar::SidebarPanelBase::Create(
+            rsResourceURL,
+            xFrame,
+            pPanel,
+            ui::LayoutSize(-1,-1,-1));
+    }
+    else if(rsResourceURL.endsWith("/PageFormatPanel"))
+    {
+        VclPtr<vcl::Window> pPanel = sw::sidebar::PageFormatPanel::Create( pParentWindow, xFrame, pBindings );
+        xElement = sfx2::sidebar::SidebarPanelBase::Create(
+            rsResourceURL,
+            xFrame,
+            pPanel,
+            ui::LayoutSize(-1,-1,-1));
+    }
+    else if(rsResourceURL.endsWith("/PageHeaderPanel"))
+    {
+        VclPtr<vcl::Window> pPanel = sw::sidebar::PageHeaderPanel::Create( pParentWindow, xFrame, pBindings );
+        xElement = sfx2::sidebar::SidebarPanelBase::Create(
+            rsResourceURL,
+            xFrame,
+            pPanel,
+            ui::LayoutSize(-1,-1,-1));
+    }
+    else if(rsResourceURL.endsWith("/PageFooterPanel"))
+    {
+        VclPtr<vcl::Window> pPanel = sw::sidebar::PageFooterPanel::Create( pParentWindow, xFrame, pBindings );
+        xElement = sfx2::sidebar::SidebarPanelBase::Create(
+            rsResourceURL,
+            xFrame,
+            pPanel,
+            ui::LayoutSize(-1,-1,-1));
+    }
     else if (rsResourceURL.endsWith("/WrapPropertyPanel"))
     {
         VclPtr<vcl::Window> pPanel = sw::sidebar::WrapPropertyPanel::Create( pParentWindow, xFrame, pBindings );
diff --git a/sw/uiconfig/swriter/ui/pagefooterpanel.ui b/sw/uiconfig/swriter/ui/pagefooterpanel.ui
new file mode 100644
index 0000000..401b2cd
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/pagefooterpanel.ui
@@ -0,0 +1,164 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.18.3 -->
+<interface>
+  <requires lib="gtk+" version="3.12"/>
+  <object class="GtkGrid" id="PageFooterPanel">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="row_spacing">6</property>
+        <property name="column_spacing">6</property>
+        <child>
+          <object class="GtkBox" id="box1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="spacing">6</property>
+            <child>
+              <object class="GtkCheckButton" id="headertoggle">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">False</property>
+                <property name="xalign">0</property>
+                <property name="draw_indicator">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkLabel" id="height">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Height:</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="heightspinfield">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="margins">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Margins:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkBox" id="box2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="spacing">6</property>
+            <child>
+              <object class="GtkSpinButton" id="leftmargin">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkSpinButton" id="rightmargin">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="spacing">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Spacing:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="samecontent">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Same Content:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="spacingspinfield">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBoxText" id="samecontentLB">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <items>
+              <item translatable="yes">Left/Right</item>
+              <item translatable="yes">First Page</item>
+              <item translatable="yes">All Pages</item>
+            </items>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+      </packing>
+    </child>
+  </object>
+</interface>
diff --git a/sw/uiconfig/swriter/ui/pageformatpanel.ui b/sw/uiconfig/swriter/ui/pageformatpanel.ui
new file mode 100644
index 0000000..148030b
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/pageformatpanel.ui
@@ -0,0 +1,115 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.18.3 -->
+<interface>
+  <requires lib="gtk+" version="3.12"/>
+  <object class="GtkGrid" id="PageFormatPanel">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="row_spacing">6</property>
+        <property name="column_spacing">6</property>
+        <child>
+          <object class="GtkLabel" id="size">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Size:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="width">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Width:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="height">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Height:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="orientation">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Orientation:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="paperwidth">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="paperheight">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBoxText" id="paperorientation">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <items>
+              <item translatable="yes">Portrait</item>
+              <item translatable="yes">Landscape</item>
+            </items>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBoxText" id="papersize">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+      </packing>
+    </child>
+  </object>
+</interface>
diff --git a/sw/uiconfig/swriter/ui/pageheaderpanel.ui b/sw/uiconfig/swriter/ui/pageheaderpanel.ui
new file mode 100644
index 0000000..546f2f6
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/pageheaderpanel.ui
@@ -0,0 +1,164 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.18.3 -->
+<interface>
+  <requires lib="gtk+" version="3.12"/>
+  <object class="GtkGrid" id="PageHeaderPanel">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="row_spacing">6</property>
+        <property name="column_spacing">6</property>
+        <child>
+          <object class="GtkBox" id="box1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="spacing">6</property>
+            <child>
+              <object class="GtkCheckButton" id="headertoggle">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">False</property>
+                <property name="xalign">0</property>
+                <property name="draw_indicator">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkLabel" id="height">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Height:</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="heightspinfield">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="margins">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Margins:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkBox" id="box2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="spacing">6</property>
+            <child>
+              <object class="GtkSpinButton" id="leftmargin">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkSpinButton" id="rightmargin">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="spacing">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Spacing:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="samecontent">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Same Content:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="spacingspinfield">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="hexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBoxText" id="samecontentLB">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <items>
+              <item translatable="yes">Left/Right</item>
+              <item translatable="yes">First Page</item>
+              <item translatable="yes">All Pages</item>
+            </items>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+      </packing>
+    </child>
+  </object>
+</interface>
diff --git a/sw/uiconfig/swriter/ui/pagemarginpanel.ui b/sw/uiconfig/swriter/ui/pagemarginpanel.ui
new file mode 100644
index 0000000..7127800
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/pagemarginpanel.ui
@@ -0,0 +1,114 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.18.3 -->
+<interface>
+  <requires lib="gtk+" version="3.12"/>
+  <object class="GtkGrid" id="PageMarginPanel">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <child>
+      <object class="GtkBox" id="box1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="orientation">vertical</property>
+        <child>
+          <object class="GtkComboBoxText" id="marginLB">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <items>
+              <item translatable="yes">Narrow</item>
+              <item translatable="yes">Normal</item>
+              <item translatable="yes">Wide</item>
+              <item translatable="yes">Mirrored</item>
+            </items>
+          </object>
+          <packing>
+            <property name="expand">True</property>
+            <property name="fill">True</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkGrid" id="grid2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <child>
+              <object class="GtkSpinButton" id="topmargin:0cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="climb_rate">1</property>
+              </object>
+              <packing>
+                <property name="left_attach">1</property>
+                <property name="top_attach">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkSpinButton" id="leftmargin:0cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="climb_rate">1</property>
+              </object>
+              <packing>
+                <property name="left_attach">0</property>
+                <property name="top_attach">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkSpinButton" id="bottommargin:0cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="climb_rate">1</property>
+              </object>
+              <packing>
+                <property name="left_attach">1</property>
+                <property name="top_attach">2</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkSpinButton" id="rightmargin:0cm">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="hexpand">True</property>
+                <property name="climb_rate">1</property>
+              </object>
+              <packing>
+                <property name="left_attach">2</property>
+                <property name="top_attach">1</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+            <child>
+              <placeholder/>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">True</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+      </packing>
+    </child>
+  </object>
+</interface>
diff --git a/sw/uiconfig/swriter/ui/pagestylespanel.ui b/sw/uiconfig/swriter/ui/pagestylespanel.ui
new file mode 100644
index 0000000..f0fe76a
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/pagestylespanel.ui
@@ -0,0 +1,127 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.18.3 -->
+<interface>
+  <requires lib="gtk+" version="3.12"/>
+  <object class="GtkGrid" id="PageStylesPanel">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="hexpand">True</property>
+    <property name="vexpand">True</property>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="row_spacing">6</property>
+        <property name="column_spacing">6</property>
+        <child>
+          <object class="GtkLabel" id="numberslabel">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Number:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="backgroundlabel">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Background:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="layoutlabel">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Layout:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="columnlabel">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Column:</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">4</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBox" id="layoutCombobox">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <property name="popup_fixed_width">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBox" id="l">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBox" id="combobox1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">2</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkComboBox" id="combobox2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkSpinButton" id="spinbutton1">
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">4</property>
+          </packing>
+        </child>
+        <child>
+          <placeholder/>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+      </packing>
+    </child>
+  </object>
+</interface>


More information about the Libreoffice-commits mailing list