Date: prev next · Thread: first prev next last
2013 Archives by date, by thread · List index


Hi,

I have submitted a patch for review:

    https://gerrit.libreoffice.org/2478

To pull it, you can do:

    git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/78/2478/1

Convert page header/footer to new widget UI

* The widget UI needs further work for better display, but all elements are there
* Fix First page toggle with header/footer on/off
* Calculations for Edit button position in Calc discarded.
* Some comments in German translated
* Need to address helpID's

Change-Id: Iab4eec4fb2497d17c8eb1ab2bab7c31b028af7b0
---
M sc/AllLangResTarget_sc.mk
M sc/inc/sc.hrc
M sc/source/ui/inc/tphf.hxx
M sc/source/ui/pagedlg/tphf.cxx
D sc/source/ui/pagedlg/tphf.src
M svx/AllLangResTarget_svx.mk
M svx/UI_svx.mk
M svx/inc/svx/hdft.hxx
M svx/source/dialog/hdft.cxx
D svx/source/dialog/hdft.hrc
D svx/source/dialog/hdft.src
A svx/uiconfig/ui/headfootformatpage.ui
12 files changed, 760 insertions(+), 693 deletions(-)



diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk
index e92e18c..59191dc 100644
--- a/sc/AllLangResTarget_sc.mk
+++ b/sc/AllLangResTarget_sc.mk
@@ -89,7 +89,6 @@
     sc/source/ui/docshell/tpstat.src \
     sc/source/ui/optdlg/calcoptionsdlg.src \
     sc/source/ui/pagedlg/pagedlg.src \
-    sc/source/ui/pagedlg/tphf.src \
     sc/source/ui/pagedlg/hfedtdlg.src \
     sc/source/ui/styleui/scstyles.src \
     sc/source/ui/styleui/styledlg.src \
diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc
index 9c17b88..0b19621 100644
--- a/sc/inc/sc.hrc
+++ b/sc/inc/sc.hrc
@@ -981,7 +981,7 @@
 #define RID_SCDLG_HFEDIT_ALL    (SC_DIALOGS_START + 51)
 #define RID_SCDLG_HFED_HEADER   (SC_DIALOGS_START + 52)
 #define RID_SCDLG_HFED_FOOTER   (SC_DIALOGS_START + 53)
-#define RID_SCBTN_HFEDIT        (SC_DIALOGS_START + 54)
+
 #define RID_SCPAGE_CALC         (SC_DIALOGS_START + 56)
 #define RID_SCDLG_NAVIGATOR     (SC_DIALOGS_START + 57)
 #define RID_SCDLG_TABOP         (SC_DIALOGS_START + 58)
diff --git a/sc/source/ui/inc/tphf.hxx b/sc/source/ui/inc/tphf.hxx
index 40b822f..e952a41 100644
--- a/sc/source/ui/inc/tphf.hxx
+++ b/sc/source/ui/inc/tphf.hxx
@@ -20,7 +20,6 @@
 #ifndef SC_TPHF_HXX
 #define SC_TPHF_HXX
 
-
 #include <svx/hdft.hxx>
 
 class ScStyleDlg;
@@ -40,7 +39,6 @@
 
 protected:
                     ScHFPage( Window* pParent,
-                              sal_uInt16 nResId,
                               const SfxItemSet& rSet,
                               sal_uInt16 nSetId );
 
@@ -50,10 +48,10 @@
     virtual int     DeactivatePage( SfxItemSet* pSet = 0 );
 
 private:
-    PushButton          aBtnEdit;
+    PushButton*         m_pBtnEdit;
     SfxItemSet          aDataSet;
-    String              aStrPageStyle;
-    sal_uInt16              nPageUsage;
+    OUString            aStrPageStyle;
+    sal_uInt16          nPageUsage;
     const ScStyleDlg*   pStyleDlg;
 
 #ifdef _TPHF_CXX
diff --git a/sc/source/ui/pagedlg/tphf.cxx b/sc/source/ui/pagedlg/tphf.cxx
index e0cc297..18e23b8 100644
--- a/sc/source/ui/pagedlg/tphf.cxx
+++ b/sc/source/ui/pagedlg/tphf.cxx
@@ -49,29 +49,22 @@
 // class ScHFPage
 //==================================================================
 
-ScHFPage::ScHFPage( Window* pParent, sal_uInt16 nResId,
-                    const SfxItemSet& rSet, sal_uInt16 nSetId )
+ScHFPage::ScHFPage( Window* pParent, const SfxItemSet& rSet, sal_uInt16 nSetId )
 
-    :   SvxHFPage   ( pParent, nResId, rSet, nSetId ),
-        aBtnEdit    ( this, ScResId( RID_SCBTN_HFEDIT ) ),
+    :   SvxHFPage   ( pParent, rSet, nSetId ),
         aDataSet    ( *rSet.GetPool(),
                        ATTR_PAGE_HEADERLEFT, ATTR_PAGE_FOOTERRIGHT,
                        ATTR_PAGE, ATTR_PAGE, 0 ),
         nPageUsage  ( (sal_uInt16)SVX_PAGE_ALL ),
         pStyleDlg   ( NULL )
 {
+    get(m_pBtnEdit,"buttonEdit");
+
     SetExchangeSupport();
 
     SfxViewShell*   pSh = SfxViewShell::Current();
     ScTabViewShell* pViewSh = PTR_CAST(ScTabViewShell,pSh);
-    Point           aPos( aBackgroundBtn.GetPosPixel() );
-
-    // aBackgroundBtn position not changed anymore
-
-    aPos.X() += aBackgroundBtn.GetSizePixel().Width();
-    aPos.X() += LogicToPixel( Size(3,0), MAP_APPFONT ).Width();
-    aBtnEdit.SetPosPixel( aPos );
-    aBtnEdit.Show();
+    m_pBtnEdit->Show();
 
     aDataSet.Put( rSet );
 
@@ -83,15 +76,15 @@
         aStrPageStyle = pDoc->GetPageStyle( pViewData->GetTabNo() );
     }
 
-    aBtnEdit.SetClickHdl    ( LINK( this, ScHFPage, BtnHdl ) );
-    aTurnOnBox.SetClickHdl  ( LINK( this, ScHFPage, TurnOnHdl ) );
+    m_pBtnEdit->SetClickHdl    ( LINK( this, ScHFPage, BtnHdl ) );
+    m_pTurnOnBox->SetClickHdl  ( LINK( this, ScHFPage, TurnOnHdl ) );
 
     if ( nId == SID_ATTR_PAGE_HEADERSET )
-        aBtnEdit.SetHelpId( HID_SC_HEADER_EDIT );
+        m_pBtnEdit->SetHelpId( HID_SC_HEADER_EDIT );
     else
-        aBtnEdit.SetHelpId( HID_SC_FOOTER_EDIT );
+        m_pBtnEdit->SetHelpId( HID_SC_FOOTER_EDIT );
 
-    aBtnEdit.SetAccessibleRelationMemberOf(&aFrm);
+    m_pBtnEdit->SetAccessibleRelationMemberOf(m_pFrm);
 }
 
 //------------------------------------------------------------------
@@ -132,7 +125,7 @@
 
 void ScHFPage::ActivatePage( const SfxItemSet& rSet )
 {
-    sal_uInt16              nPageWhich = GetWhich( SID_ATTR_PAGE );
+    sal_uInt16          nPageWhich = GetWhich( SID_ATTR_PAGE );
     const SvxPageItem&  rPageItem  = (const SvxPageItem&)
                                      rSet.Get(nPageWhich);
 
@@ -173,12 +166,12 @@
 
 IMPL_LINK_NOARG(ScHFPage, TurnOnHdl)
 {
-    SvxHFPage::TurnOnHdl( &aTurnOnBox );
+    SvxHFPage::TurnOnHdl( m_pTurnOnBox );
 
-    if ( aTurnOnBox.IsChecked() )
-        aBtnEdit.Enable();
+    if ( m_pTurnOnBox->IsChecked() )
+        m_pBtnEdit->Enable();
     else
-        aBtnEdit.Disable();
+        m_pBtnEdit->Disable();
 
     return 0;
 }
@@ -188,10 +181,9 @@
 
 IMPL_LINK_NOARG(ScHFPage, BtnHdl)
 {
-    //  Wenn der Bearbeiten-Dialog direkt aus dem Click-Handler des Buttons
-    //  aufgerufen wird, funktioniert im Bearbeiten-Dialog unter OS/2 das
-    //  GrabFocus nicht (Bug #41805#).
-    //  Mit dem neuen StarView sollte dieser Workaround wieder raus koennen!
+    // When the Edit-Dialog is directly called up from the Button's Click-Handler,
+    // the GraveFocus from the Edit-Dialog under OS/2 doesn't work.(Bug #41805#).
+    // With the new StarView, this workaround should be again considered!
 
     Application::PostUserEvent( LINK( this, ScHFPage, HFEditHdl ) );
     return 0;
@@ -207,8 +199,8 @@
         return 0;
     }
 
-    if (   aCntSharedBox.IsEnabled()
-        && !aCntSharedBox.IsChecked() )
+    if (   m_pCntSharedBox->IsEnabled()
+        && !m_pCntSharedBox->IsChecked() )
     {
         sal_uInt16 nResId = ( nId == SID_ATTR_PAGE_HEADERSET )
                             ? RID_SCDLG_HFED_HEADER
@@ -227,9 +219,9 @@
     }
     else
     {
-        String              aText;
+        OUString  aText;
         SfxNoLayoutSingleTabDialog* pDlg = new SfxNoLayoutSingleTabDialog( this, aDataSet, 42 );
-        sal_Bool bRightPage =   aCntSharedBox.IsChecked()
+        sal_Bool bRightPage =   m_pCntSharedBox->IsChecked()
                          || ( SVX_PAGE_LEFT != SvxPageUsage(nPageUsage) );
 
         if ( nId == SID_ATTR_PAGE_HEADERSET )
@@ -252,11 +244,8 @@
         SvxNumType eNumType = ((const SvxPageItem&)aDataSet.Get(ATTR_PAGE)).GetNumType();
         ((ScHFEditPage*)pDlg->GetTabPage())->SetNumType(eNumType);
 
-        aText.AppendAscii(RTL_CONSTASCII_STRINGPARAM( " (" ));
-        aText += ScGlobal::GetRscString( STR_PAGESTYLE );
-        aText.AppendAscii(RTL_CONSTASCII_STRINGPARAM( ": " ));
-        aText += aStrPageStyle;
-        aText += ')';
+        aText += " (" + ScGlobal::GetRscString( STR_PAGESTYLE );
+        aText += ": " + aStrPageStyle + ")";
 
         pDlg->SetText( aText );
 
@@ -276,7 +265,7 @@
 //==================================================================
 
 ScHeaderPage::ScHeaderPage( Window* pParent, const SfxItemSet& rSet )
-    : ScHFPage( pParent, RID_SVXPAGE_HEADER, rSet, SID_ATTR_PAGE_HEADERSET )
+    : ScHFPage( pParent, rSet, SID_ATTR_PAGE_HEADERSET )
 {
 }
 
@@ -299,7 +288,7 @@
 //==================================================================
 
 ScFooterPage::ScFooterPage( Window* pParent, const SfxItemSet& rSet )
-    : ScHFPage( pParent, RID_SVXPAGE_FOOTER, rSet, SID_ATTR_PAGE_FOOTERSET )
+    : ScHFPage( pParent, rSet, SID_ATTR_PAGE_FOOTERSET )
 {
 }
 
diff --git a/sc/source/ui/pagedlg/tphf.src b/sc/source/ui/pagedlg/tphf.src
deleted file mode 100644
index 206a697..0000000
--- a/sc/source/ui/pagedlg/tphf.src
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * 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 "sc.hrc"
-
-PushButton RID_SCBTN_HFEDIT
-{
-    TabStop = TRUE ;
-    Hide = TRUE ;
-    Pos = MAP_APPFONT ( 0 , 0 ) ;
-    Size = MAP_APPFONT ( 50 , 14 ) ;
-    Text [ en-US ] = "~Edit..." ;
-};
diff --git a/svx/AllLangResTarget_svx.mk b/svx/AllLangResTarget_svx.mk
index ca50785..6591df1 100644
--- a/svx/AllLangResTarget_svx.mk
+++ b/svx/AllLangResTarget_svx.mk
@@ -55,7 +55,6 @@
     svx/source/dialog/docrecovery.src \
     svx/source/dialog/fontwork.src \
     svx/source/dialog/frmsel.src \
-    svx/source/dialog/hdft.src \
     svx/source/dialog/imapdlg.src \
     svx/source/dialog/langbox.src \
     svx/source/dialog/language.src \
diff --git a/svx/UI_svx.mk b/svx/UI_svx.mk
index aee883f..f7e28ae 100644
--- a/svx/UI_svx.mk
+++ b/svx/UI_svx.mk
@@ -14,6 +14,7 @@
        svx/uiconfig/ui/asianphoneticguidedialog \
        svx/uiconfig/ui/chineseconversiondialog \
        svx/uiconfig/ui/compressgraphicdialog \
+       svx/uiconfig/ui/headfootformatpage \
        svx/uiconfig/ui/redlinecontrol \
        svx/uiconfig/ui/redlinefilterpage \
        svx/uiconfig/ui/redlineviewpage \
diff --git a/svx/inc/svx/hdft.hxx b/svx/inc/svx/hdft.hxx
index 14bd6ae..57924c1 100644
--- a/svx/inc/svx/hdft.hxx
+++ b/svx/inc/svx/hdft.hxx
@@ -57,31 +57,37 @@
     virtual void    ActivatePage( const SfxItemSet& rSet );
     virtual int     DeactivatePage( SfxItemSet* pSet = 0 );
 
-    SvxHFPage( Window* pParent, sal_uInt16 nResId, const SfxItemSet& rSet,
-               sal_uInt16 nSetId );
+    SvxHFPage( Window* pParent, const SfxItemSet& rSet, sal_uInt16 nSetId );
 
-    FixedLine       aFrm;
-    CheckBox        aTurnOnBox;
-    CheckBox        aCntSharedBox;
-    CheckBox        aCntSharedFirstBox;
-    FixedText       aLMLbl;
-    MetricField     aLMEdit;
-    FixedText       aRMLbl;
-    MetricField     aRMEdit;
-    FixedText       aDistFT;
-    MetricField     aDistEdit;
-    CheckBox        aDynSpacingCB;
-    FixedText       aHeightFT;
-    MetricField     aHeightEdit;
-    CheckBox        aHeightDynBtn;
-    SvxPageWindow   aBspWin;
-    PushButton      aBackgroundBtn;
+    VclFrame*        m_pFrm;
+    FixedText*       m_pPageLbl;
+    CheckBox*        m_pTurnOnBox;
+    CheckBox*        m_pCntSharedBox;
+    CheckBox*        m_pCntSharedFirstBox;
+    FixedText*       m_pLMLbl;
+    MetricField*     m_pLMEdit;
+    FixedText*       m_pRMLbl;
+    MetricField*     m_pRMEdit;
+    FixedText*       m_pDistFT;
+    MetricField*     m_pDistEdit;
+    CheckBox*        m_pDynSpacingCB;
+    FixedText*       m_pHeightFT;
+    MetricField*     m_pHeightEdit;
+    CheckBox*        m_pHeightDynBtn;
+    SvxPageWindow*   m_pBspWin;
+    PushButton*      m_pBackgroundBtn;
 
-    sal_uInt16          nId;
-    SfxItemSet*     pBBSet;
-    sal_Bool            bDisableQueryBox;
-    sal_Bool            bEnableBackgroundSelector;
-    bool            bInReset;
+    FixedText*       m_pFooterOn;
+    FixedText*       m_pFooterLbl;
+    FixedText*       m_pHeaderOn;
+    FixedText*       m_pHeaderLbl;
+    FixedText*       m_pMsg;
+
+    sal_uInt16       nId;
+    SfxItemSet*      pBBSet;
+    sal_Bool         bDisableQueryBox;
+    sal_Bool         bEnableBackgroundSelector;
+    bool             bInReset;
 
     void            InitHandler();
     DECL_LINK( TurnOnHdl, CheckBox*);
diff --git a/svx/source/dialog/hdft.cxx b/svx/source/dialog/hdft.cxx
index 55a2151..3a08520 100644
--- a/svx/source/dialog/hdft.cxx
+++ b/svx/source/dialog/hdft.cxx
@@ -28,7 +28,7 @@
 #include <sfx2/sfxsids.hrc>
 #include <svx/svxids.hrc>
 #include <svx/dialogs.hrc>
-#include "hdft.hrc"
+
 #include <svl/intitem.hxx>
 
 #define _SVX_HDFT_CXX
@@ -139,7 +139,7 @@
 
 SvxHeaderPage::SvxHeaderPage( Window* pParent, const SfxItemSet& rAttr ) :
 
-    SvxHFPage( pParent, RID_SVXPAGE_HEADER, rAttr, SID_ATTR_PAGE_HEADERSET )
+    SvxHFPage( pParent, rAttr, SID_ATTR_PAGE_HEADERSET )
 
 {
 }
@@ -148,69 +148,86 @@
 
 SvxFooterPage::SvxFooterPage( Window* pParent, const SfxItemSet& rAttr ) :
 
-    SvxHFPage( pParent, RID_SVXPAGE_FOOTER, rAttr, SID_ATTR_PAGE_FOOTERSET )
+    SvxHFPage( pParent, rAttr, SID_ATTR_PAGE_FOOTERSET )
 
 {
 }
 
 // -----------------------------------------------------------------------
 
-SvxHFPage::SvxHFPage( Window* pParent, sal_uInt16 nResId, const SfxItemSet& rAttr, sal_uInt16 
nSetId ) :
+SvxHFPage::SvxHFPage( Window* pParent, const SfxItemSet& rSet, sal_uInt16 nSetId ) :
 
-    SfxTabPage( pParent, SVX_RES( nResId ), rAttr ),
-
-    aFrm            ( this, SVX_RES( FL_FRAME ) ),
-    aTurnOnBox      ( this, SVX_RES( CB_TURNON ) ),
-    aCntSharedBox   ( this, SVX_RES( CB_SHARED ) ),
-    aCntSharedFirstBox   ( this, SVX_RES( CB_SHARED_FIRST ) ),
-    aLMLbl          ( this, SVX_RES( FT_LMARGIN ) ),
-    aLMEdit         ( this, SVX_RES( ED_LMARGIN ) ),
-    aRMLbl          ( this, SVX_RES( FT_RMARGIN ) ),
-    aRMEdit         ( this, SVX_RES( ED_RMARGIN ) ),
-    aDistFT         ( this, SVX_RES( FT_DIST ) ),
-    aDistEdit       ( this, SVX_RES( ED_DIST ) ),
-    aDynSpacingCB   ( this, SVX_RES( CB_DYNSPACING ) ),
-    aHeightFT       ( this, SVX_RES( FT_HEIGHT ) ),
-    aHeightEdit     ( this, SVX_RES( ED_HEIGHT ) ),
-    aHeightDynBtn   ( this, SVX_RES( CB_HEIGHT_DYN ) ),
-    aBspWin         ( this, SVX_RES( WN_BSP ) ),
-    aBackgroundBtn  ( this, SVX_RES( BTN_EXTRAS ) ),
-
+    SfxTabPage( pParent, "HFFormatPage", "svx/ui/headfootformatpage.ui", rSet ),
     nId                         ( nSetId ),
     pBBSet                      ( NULL ),
     bDisableQueryBox            ( sal_False ),
     bEnableBackgroundSelector   ( sal_True )
 
 {
+    get(m_pFrm,"frameHdrOn");
+    get(m_pPageLbl,"labelHeaderFooterFormat");
+    get(m_pTurnOnBox,"checkHeaderOn");
+    get(m_pCntSharedBox,"checkSameLR");
+    get(m_pCntSharedFirstBox,"checkSameFP");
+    get(m_pLMEdit,"spinMargLeft");
+    get(m_pLMLbl,"labelLeftMarg");
+    get(m_pRMEdit,"spinMargRight");
+    get(m_pRMLbl,"labelRightMarg");
+    get(m_pDistEdit,"spinSpacing");
+    get(m_pDistFT,"labelSpacing");
+    get(m_pDynSpacingCB,"checkDynSpacing");
+    get(m_pHeightFT,"labelHeight");
+    get(m_pHeightEdit,"spinHeight");
+    get(m_pHeightDynBtn,"checkAutofit");
+    get(m_pBspWin,"drawingareaPageHF");
+    get(m_pBackgroundBtn,"buttonMore");
+
+    get(m_pFooterOn,"labelFooterOn");
+    get(m_pFooterLbl,"labelFooter");
+    get(m_pHeaderOn,"labelHeaderOn");
+    get(m_pHeaderLbl,"labelHeader");
+    get(m_pMsg,"labelMsg");
+
+    //swap header <-> footer in UI
+    if(nId == SID_ATTR_PAGE_FOOTERSET)
+    {
+        m_pPageLbl->SetText(m_pFooterLbl->GetText());
+        m_pTurnOnBox->SetText(m_pFooterOn->GetText());
+    }
+    else //Header
+    {
+        m_pPageLbl->SetText(m_pHeaderLbl->GetText());
+        m_pTurnOnBox->SetText(m_pHeaderOn->GetText());
+    }
+
     InitHandler();
-    aBspWin.EnableRTL( sal_False );
+    m_pBspWin->EnableRTL( sal_False );
 
     // This Page needs ExchangeSupport
     SetExchangeSupport();
 
-    FreeResource();
 
     // Set metrics
-    FieldUnit eFUnit = GetModuleFieldUnit( rAttr );
-    SetFieldUnit( aDistEdit, eFUnit );
-    SetFieldUnit( aHeightEdit, eFUnit );
-    SetFieldUnit( aLMEdit, eFUnit );
-    SetFieldUnit( aRMEdit, eFUnit );
+    FieldUnit eFUnit = GetModuleFieldUnit( rSet );
+    SetFieldUnit( *m_pDistEdit, eFUnit );
+    SetFieldUnit( *m_pHeightEdit, eFUnit );
+    SetFieldUnit( *m_pLMEdit, eFUnit );
+    SetFieldUnit( *m_pRMEdit, eFUnit );
 
-    aTurnOnBox.SetAccessibleRelationMemberOf( &aFrm );
-    aCntSharedBox.SetAccessibleRelationMemberOf( &aFrm );
-    aCntSharedFirstBox.SetAccessibleRelationMemberOf( &aFrm );
-    aLMLbl.SetAccessibleRelationMemberOf( &aFrm );
-    aLMEdit.SetAccessibleRelationMemberOf( &aFrm );
-    aRMLbl.SetAccessibleRelationMemberOf( &aFrm );
-    aRMEdit.SetAccessibleRelationMemberOf( &aFrm );
-    aDistFT.SetAccessibleRelationMemberOf( &aFrm );
-    aDistEdit.SetAccessibleRelationMemberOf( &aFrm );
-    aDynSpacingCB.SetAccessibleRelationMemberOf( &aFrm );
-    aHeightFT.SetAccessibleRelationMemberOf( &aFrm );
-    aHeightEdit.SetAccessibleRelationMemberOf( &aFrm );
-    aHeightDynBtn.SetAccessibleRelationMemberOf( &aFrm );
-    aBackgroundBtn.SetAccessibleRelationMemberOf(&aFrm);
+    m_pTurnOnBox->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pCntSharedBox->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pCntSharedFirstBox->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pLMLbl->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pLMEdit->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pRMLbl->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pRMEdit->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pDistFT->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pDistEdit->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pDynSpacingCB->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pHeightFT->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pHeightEdit->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pHeightDynBtn->SetAccessibleRelationMemberOf( m_pFrm );
+    m_pBackgroundBtn->SetAccessibleRelationMemberOf(m_pFrm);
 }
 
 // -----------------------------------------------------------------------
@@ -257,14 +274,14 @@
 
     //--------------------------------------------------------------------
 
-    aSet.Put( SfxBoolItem( nWOn,      aTurnOnBox.IsChecked() ) );
-    aSet.Put( SfxBoolItem( nWDynamic, aHeightDynBtn.IsChecked() ) );
-    aSet.Put( SfxBoolItem( nWShared,  aCntSharedBox.IsChecked() ) );
-    aSet.Put( SfxBoolItem( nWSharedFirst,  aCntSharedFirstBox.IsChecked() ) );
-    if(aDynSpacingCB.IsVisible() && SFX_WHICH_MAX > nWDynSpacing)
+    aSet.Put( SfxBoolItem( nWOn,      m_pTurnOnBox->IsChecked() ) );
+    aSet.Put( SfxBoolItem( nWDynamic, m_pHeightDynBtn->IsChecked() ) );
+    aSet.Put( SfxBoolItem( nWShared,  m_pCntSharedBox->IsChecked() ) );
+    aSet.Put( SfxBoolItem( nWSharedFirst,  m_pCntSharedFirstBox->IsChecked() ) );
+    if(m_pDynSpacingCB->IsVisible() && SFX_WHICH_MAX > nWDynSpacing)
     {
         SfxBoolItem* pBoolItem = (SfxBoolItem*)pPool->GetDefaultItem(nWDynSpacing).Clone();
-        pBoolItem->SetValue(aDynSpacingCB.IsChecked());
+        pBoolItem->SetValue(m_pDynSpacingCB->IsChecked());
         aSet.Put(*pBoolItem);
         delete pBoolItem;
     }
@@ -272,8 +289,8 @@
     // Size
     SvxSizeItem aSizeItem( (const SvxSizeItem&)rOldSet.Get( nWSize ) );
     Size        aSize( aSizeItem.GetSize() );
-    long        nDist = GetCoreValue( aDistEdit, eUnit );
-    long        nH    = GetCoreValue( aHeightEdit, eUnit );
+    long        nDist = GetCoreValue( *m_pDistEdit, eUnit );
+    long        nH    = GetCoreValue( *m_pHeightEdit, eUnit );
 
     nH += nDist; // add distance
     aSize.Height() = nH;
@@ -282,8 +299,8 @@
 
     // Margins
     SvxLRSpaceItem aLR( nWLRSpace );
-    aLR.SetLeft( (sal_uInt16)GetCoreValue( aLMEdit, eUnit ) );
-    aLR.SetRight( (sal_uInt16)GetCoreValue( aRMEdit, eUnit ) );
+    aLR.SetLeft( (sal_uInt16)GetCoreValue( *m_pLMEdit, eUnit ) );
+    aLR.SetRight( (sal_uInt16)GetCoreValue( *m_pRMEdit, eUnit ) );
     aSet.Put( aLR );
 
     SvxULSpaceItem aUL( nWULSpace );
@@ -344,7 +361,7 @@
         const SfxBoolItem& rHeaderOn =
             (const SfxBoolItem&)rHeaderSet.Get(GetWhich(SID_ATTR_PAGE_ON));
 
-        aTurnOnBox.Check(rHeaderOn.GetValue());
+        m_pTurnOnBox->Check(rHeaderOn.GetValue());
 
         if ( rHeaderOn.GetValue() )
         {
@@ -361,33 +378,33 @@
                 (const SvxULSpaceItem&)rHeaderSet.Get( GetWhich( SID_ATTR_ULSPACE ) );
             const SvxLRSpaceItem& rLR =
                 (const SvxLRSpaceItem&)rHeaderSet.Get( GetWhich( SID_ATTR_LRSPACE ) );
-            if(aDynSpacingCB.IsVisible())
+            if(m_pDynSpacingCB->IsVisible())
             {
                 const SfxBoolItem& rDynSpacing =
                     (const SfxBoolItem&)rHeaderSet.Get(GetWhich(SID_ATTR_HDFT_DYNAMIC_SPACING));
-                aDynSpacingCB.Check(rDynSpacing.GetValue());
+                m_pDynSpacingCB->Check(rDynSpacing.GetValue());
             }
 
 
             if ( nId == SID_ATTR_PAGE_HEADERSET )
             {   // Header
-                SetMetricValue( aDistEdit, rUL.GetLower(), eUnit );
-                SetMetricValue( aHeightEdit, rSize.GetSize().Height() - rUL.GetLower(), eUnit );
+                SetMetricValue( *m_pDistEdit, rUL.GetLower(), eUnit );
+                SetMetricValue( *m_pHeightEdit, rSize.GetSize().Height() - rUL.GetLower(), eUnit );
             }
             else
             {   // Footer
-                SetMetricValue( aDistEdit, rUL.GetUpper(), eUnit );
-                SetMetricValue( aHeightEdit, rSize.GetSize().Height() - rUL.GetUpper(), eUnit );
+                SetMetricValue( *m_pDistEdit, rUL.GetUpper(), eUnit );
+                SetMetricValue( *m_pHeightEdit, rSize.GetSize().Height() - rUL.GetUpper(), eUnit );
             }
 
-            aHeightDynBtn.Check(rDynamic.GetValue());
-            SetMetricValue( aLMEdit, rLR.GetLeft(), eUnit );
-            SetMetricValue( aRMEdit, rLR.GetRight(), eUnit );
-            aCntSharedBox.Check(rShared.GetValue());
+            m_pHeightDynBtn->Check(rDynamic.GetValue());
+            SetMetricValue( *m_pLMEdit, rLR.GetLeft(), eUnit );
+            SetMetricValue( *m_pRMEdit, rLR.GetRight(), eUnit );
+            m_pCntSharedBox->Check(rShared.GetValue());
             if (pSharedFirst)
-                aCntSharedFirstBox.Check(pSharedFirst->GetValue());
+                m_pCntSharedFirstBox->Check(pSharedFirst->GetValue());
             else
-                aCntSharedFirstBox.Hide();
+                m_pCntSharedFirstBox->Hide();
         }
         else
             pSetItem = 0;
@@ -402,27 +419,27 @@
         if ( pExt1 && pExt1->ISA(SfxBoolItem) && pExt2 && pExt2->ISA(SfxBoolItem) )
             nDefaultDist = DEF_DIST_CALC;
 
-        SetMetricValue( aDistEdit, nDefaultDist, SFX_MAPUNIT_100TH_MM );
-        SetMetricValue( aHeightEdit, 500, SFX_MAPUNIT_100TH_MM );
+        SetMetricValue( *m_pDistEdit, nDefaultDist, SFX_MAPUNIT_100TH_MM );
+        SetMetricValue( *m_pHeightEdit, 500, SFX_MAPUNIT_100TH_MM );
     }
 
     if ( !pSetItem )
     {
-        aTurnOnBox.Check( sal_False );
-        aHeightDynBtn.Check( sal_True );
-        aCntSharedBox.Check( sal_True );
-        aCntSharedFirstBox.Check( sal_True );
+        m_pTurnOnBox->Check( sal_False );
+        m_pHeightDynBtn->Check( sal_True );
+        m_pCntSharedBox->Check( sal_True );
+        m_pCntSharedFirstBox->Check( sal_True );
     }
 
     TurnOnHdl(0);
 
-    aTurnOnBox.SaveValue();
-    aDistEdit.SaveValue();
-    aHeightEdit.SaveValue();
-    aHeightDynBtn.SaveValue();
-    aLMEdit.SaveValue();
-    aRMEdit.SaveValue();
-    aCntSharedBox.SaveValue();
+    m_pTurnOnBox->SaveValue();
+    m_pDistEdit->SaveValue();
+    m_pHeightEdit->SaveValue();
+    m_pHeightDynBtn->SaveValue();
+    m_pLMEdit->SaveValue();
+    m_pRMEdit->SaveValue();
+    m_pCntSharedBox->SaveValue();
     RangeHdl( 0 );
 
     const SfxPoolItem* pItem = 0;
@@ -435,8 +452,8 @@
         nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue();
         if(nHtmlMode & HTMLMODE_ON)
         {
-            aCntSharedBox.Hide();
-            aBackgroundBtn.Hide();
+            m_pCntSharedBox->Hide();
+            m_pBackgroundBtn->Hide();
         }
     }
 
@@ -444,72 +461,73 @@
 
 void SvxHFPage::InitHandler()
 {
-    aTurnOnBox.SetClickHdl(LINK(this,   SvxHFPage, TurnOnHdl));
-    aDistEdit.SetModifyHdl(LINK(this,   SvxHFPage, DistModify));
-    aDistEdit.SetLoseFocusHdl(LINK(this, SvxHFPage, RangeHdl));
+    m_pTurnOnBox->SetClickHdl(LINK(this,   SvxHFPage, TurnOnHdl));
+    m_pDistEdit->SetModifyHdl(LINK(this,   SvxHFPage, DistModify));
+    m_pDistEdit->SetLoseFocusHdl(LINK(this, SvxHFPage, RangeHdl));
 
-    aHeightEdit.SetModifyHdl(LINK(this,     SvxHFPage, HeightModify));
-    aHeightEdit.SetLoseFocusHdl(LINK(this,SvxHFPage,RangeHdl));
+    m_pHeightEdit->SetModifyHdl(LINK(this,     SvxHFPage, HeightModify));
+    m_pHeightEdit->SetLoseFocusHdl(LINK(this,SvxHFPage,RangeHdl));
 
-    aLMEdit.SetModifyHdl(LINK(this,         SvxHFPage, BorderModify));
-    aLMEdit.SetLoseFocusHdl(LINK(this,  SvxHFPage, RangeHdl));
-    aRMEdit.SetModifyHdl(LINK(this,         SvxHFPage, BorderModify));
-    aRMEdit.SetLoseFocusHdl(LINK(this,  SvxHFPage, RangeHdl));
-    aBackgroundBtn.SetClickHdl(LINK(this,SvxHFPage, BackgroundHdl));
+    m_pLMEdit->SetModifyHdl(LINK(this,         SvxHFPage, BorderModify));
+    m_pLMEdit->SetLoseFocusHdl(LINK(this,  SvxHFPage, RangeHdl));
+    m_pRMEdit->SetModifyHdl(LINK(this,         SvxHFPage, BorderModify));
+    m_pRMEdit->SetLoseFocusHdl(LINK(this,  SvxHFPage, RangeHdl));
+    m_pBackgroundBtn->SetClickHdl(LINK(this,SvxHFPage, BackgroundHdl));
 }
 
 IMPL_LINK( SvxHFPage, TurnOnHdl, CheckBox *, pBox )
 {
-    if ( aTurnOnBox.IsChecked() )
+    if ( m_pTurnOnBox->IsChecked() )
     {
-        aDistFT.Enable();
-        aDistEdit.Enable();
-        aDynSpacingCB.Enable();
-        aHeightFT.Enable();
-        aHeightEdit.Enable();
-        aHeightDynBtn.Enable();
-        aLMLbl.Enable();
-        aLMEdit.Enable();
-        aRMLbl.Enable();
-        aRMEdit.Enable();
+        m_pDistFT->Enable();
+        m_pDistEdit->Enable();
+        m_pDynSpacingCB->Enable();
+        m_pHeightFT->Enable();
+        m_pHeightEdit->Enable();
+        m_pHeightDynBtn->Enable();
+        m_pLMLbl->Enable();
+        m_pLMEdit->Enable();
+        m_pRMLbl->Enable();
+        m_pRMEdit->Enable();
 
-        sal_uInt16 nUsage = aBspWin.GetUsage();
+        sal_uInt16 nUsage = m_pBspWin->GetUsage();
 
         if( nUsage == SVX_PAGE_RIGHT || nUsage == SVX_PAGE_LEFT )
-            aCntSharedBox.Disable();
+            m_pCntSharedBox->Disable();
         else
         {
-            aCntSharedBox.Enable();
-            aCntSharedFirstBox.Enable();
+            m_pCntSharedBox->Enable();
+            m_pCntSharedFirstBox->Enable();
         }
-        aBackgroundBtn.Enable();
+        m_pBackgroundBtn->Enable();
     }
     else
     {
         sal_Bool bDelete = sal_True;
 
-        if ( !bDisableQueryBox && pBox && aTurnOnBox.GetSavedValue() == sal_True )
+        if ( !bDisableQueryBox && pBox && m_pTurnOnBox->GetSavedValue() == sal_True )
             bDelete = ( QueryBox( this, SVX_RES( RID_SVXQBX_DELETE_HEADFOOT ) ).Execute() == 
RET_YES );
 
         if ( bDelete )
         {
-            aDistFT.Disable();
-            aDistEdit.Disable();
-            aDynSpacingCB.Enable(sal_False);
-            aHeightFT.Disable();
-            aHeightEdit.Disable();
-            aHeightDynBtn.Disable();
+            m_pDistFT->Disable();
+            m_pDistEdit->Disable();
+            m_pDynSpacingCB->Enable(sal_False);
+            m_pHeightFT->Disable();
+            m_pHeightEdit->Disable();
+            m_pHeightDynBtn->Disable();
 
-            aLMLbl.Disable();
-            aLMEdit.Disable();
-            aRMLbl.Disable();
-            aRMEdit.Disable();
+            m_pLMLbl->Disable();
+            m_pLMEdit->Disable();
+            m_pRMLbl->Disable();
+            m_pRMEdit->Disable();
 
-            aCntSharedBox.Disable();
-            aBackgroundBtn.Disable();
+            m_pCntSharedBox->Disable();
+            m_pBackgroundBtn->Disable();
+            m_pCntSharedFirstBox->Disable();
         }
         else
-            aTurnOnBox.Check();
+            m_pTurnOnBox->Check();
     }
     UpdateExample();
     return 0;
@@ -574,9 +592,9 @@
         {
             const SvxBrushItem& rItem = (const SvxBrushItem&)pBBSet->Get( nWhich );
             if ( nId == SID_ATTR_PAGE_HEADERSET )
-                aBspWin.SetHdColor( rItem.GetColor() );
+                m_pBspWin->SetHdColor( rItem.GetColor() );
             else
-                aBspWin.SetFtColor( rItem.GetColor() );
+                m_pBspWin->SetFtColor( rItem.GetColor() );
         }
 
         //----------------------------------------------------------------
@@ -588,9 +606,9 @@
             const SvxBoxItem& rItem = (const SvxBoxItem&)pBBSet->Get( nWhich );
 
             if ( nId == SID_ATTR_PAGE_HEADERSET )
-                aBspWin.SetHdBorder( rItem );
+                m_pBspWin->SetHdBorder( rItem );
             else
-                aBspWin.SetFtBorder( rItem );
+                m_pBspWin->SetFtBorder( rItem );
         }
 
         UpdateExample();
@@ -603,21 +621,21 @@
 {
     if ( nId == SID_ATTR_PAGE_HEADERSET )
     {
-        aBspWin.SetHeader( aTurnOnBox.IsChecked() );
-        aBspWin.SetHdHeight( GetCoreValue( aHeightEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetHdDist( GetCoreValue( aDistEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetHdLeft( GetCoreValue( aLMEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetHdRight( GetCoreValue( aRMEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetHeader( m_pTurnOnBox->IsChecked() );
+        m_pBspWin->SetHdHeight( GetCoreValue( *m_pHeightEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetHdDist( GetCoreValue( *m_pDistEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetHdLeft( GetCoreValue( *m_pLMEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetHdRight( GetCoreValue( *m_pRMEdit, SFX_MAPUNIT_TWIP ) );
     }
     else
     {
-        aBspWin.SetFooter( aTurnOnBox.IsChecked() );
-        aBspWin.SetFtHeight( GetCoreValue( aHeightEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetFtDist( GetCoreValue( aDistEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetFtLeft( GetCoreValue( aLMEdit, SFX_MAPUNIT_TWIP ) );
-        aBspWin.SetFtRight( GetCoreValue( aRMEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetFooter( m_pTurnOnBox->IsChecked() );
+        m_pBspWin->SetFtHeight( GetCoreValue( *m_pHeightEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetFtDist( GetCoreValue( *m_pDistEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetFtLeft( GetCoreValue( *m_pLMEdit, SFX_MAPUNIT_TWIP ) );
+        m_pBspWin->SetFtRight( GetCoreValue( *m_pRMEdit, SFX_MAPUNIT_TWIP ) );
     }
-    aBspWin.Invalidate();
+    m_pBspWin->Invalidate();
 }
 
 void SvxHFPage::ResetBackground_Impl( const SfxItemSet& rSet )
@@ -639,7 +657,7 @@
             if ( rTmpSet.GetItemState( nWhich ) == SFX_ITEM_SET )
             {
                 const SvxBrushItem& rItem = (const SvxBrushItem&)rTmpSet.Get( nWhich );
-                aBspWin.SetHdColor( rItem.GetColor() );
+                m_pBspWin->SetHdColor( rItem.GetColor() );
             }
             nWhich = GetWhich( SID_ATTR_BORDER_OUTER );
 
@@ -647,7 +665,7 @@
             {
                 const SvxBoxItem& rItem =
                     (const SvxBoxItem&)rTmpSet.Get( nWhich );
-                aBspWin.SetHdBorder( rItem );
+                m_pBspWin->SetHdBorder( rItem );
             }
         }
     }
@@ -669,7 +687,7 @@
             if ( rTmpSet.GetItemState( nWhich ) == SFX_ITEM_SET )
             {
                 const SvxBrushItem& rItem = (const SvxBrushItem&)rTmpSet.Get( nWhich );
-                aBspWin.SetFtColor( rItem.GetColor() );
+                m_pBspWin->SetFtColor( rItem.GetColor() );
             }
             nWhich = GetWhich( SID_ATTR_BORDER_OUTER );
 
@@ -677,7 +695,7 @@
             {
                 const SvxBoxItem& rItem =
                     (const SvxBoxItem&)rTmpSet.Get( nWhich );
-                aBspWin.SetFtBorder( rItem );
+                m_pBspWin->SetFtBorder( rItem );
             }
         }
     }
@@ -686,23 +704,23 @@
     if ( rSet.GetItemState( nWhich ) >= SFX_ITEM_AVAILABLE )
     {
         const SvxBrushItem& rItem = (const SvxBrushItem&)rSet.Get( nWhich );
-        aBspWin.SetColor( rItem.GetColor() );
+        m_pBspWin->SetColor( rItem.GetColor() );
         const Graphic* pGrf = rItem.GetGraphic();
 
         if ( pGrf )
         {
             Bitmap aBitmap = pGrf->GetBitmap();
-            aBspWin.SetBitmap( &aBitmap );
+            m_pBspWin->SetBitmap( &aBitmap );
         }
         else
-            aBspWin.SetBitmap( NULL );
+            m_pBspWin->SetBitmap( NULL );
     }
     nWhich = GetWhich( SID_ATTR_BORDER_OUTER );
 
     if ( rSet.GetItemState( nWhich ) >= SFX_ITEM_AVAILABLE )
     {
         const SvxBoxItem& rItem = (const SvxBoxItem&)rSet.Get( nWhich );
-        aBspWin.SetBorder( rItem );
+        m_pBspWin->SetBorder( rItem );
     }
 }
 
@@ -715,13 +733,13 @@
         // Set left and right margins
         const SvxLRSpaceItem& rLRSpace = (const SvxLRSpaceItem&)*pItem;
 
-        aBspWin.SetLeft( rLRSpace.GetLeft() );
-        aBspWin.SetRight( rLRSpace.GetRight() );
+        m_pBspWin->SetLeft( rLRSpace.GetLeft() );
+        m_pBspWin->SetRight( rLRSpace.GetRight() );
     }
     else
     {
-        aBspWin.SetLeft( 0 );
-        aBspWin.SetRight( 0 );
+        m_pBspWin->SetLeft( 0 );
+        m_pBspWin->SetRight( 0 );
     }
 
     pItem = GetItem( rSet, SID_ATTR_ULSPACE );
@@ -731,13 +749,13 @@
         // Set top and bottom margins
         const SvxULSpaceItem& rULSpace = (const SvxULSpaceItem&)*pItem;
 
-        aBspWin.SetTop( rULSpace.GetUpper() );
-        aBspWin.SetBottom( rULSpace.GetLower() );
+        m_pBspWin->SetTop( rULSpace.GetUpper() );
+        m_pBspWin->SetBottom( rULSpace.GetLower() );
     }
     else
     {
-        aBspWin.SetTop( 0 );
-        aBspWin.SetBottom( 0 );
+        m_pBspWin->SetTop( 0 );
+        m_pBspWin->SetBottom( 0 );
     }
 
     sal_uInt16 nUsage = SVX_PAGE_ALL;
@@ -746,14 +764,14 @@
     if ( pItem )
         nUsage = ( (const SvxPageItem*)pItem )->GetPageUsage();
 
-    aBspWin.SetUsage( nUsage );
+    m_pBspWin->SetUsage( nUsage );
 
     if ( SVX_PAGE_RIGHT == nUsage || SVX_PAGE_LEFT == nUsage )
-        aCntSharedBox.Disable();
+        m_pCntSharedBox->Disable();
     else
     {
-        aCntSharedBox.Enable();
-        aCntSharedFirstBox.Enable();
+        m_pCntSharedBox->Enable();
+        m_pCntSharedFirstBox->Enable();
     }
     pItem = GetItem( rSet, SID_ATTR_PAGE_SIZE );
 
@@ -762,7 +780,7 @@
         // Orientation and Size from the PageItem
         const SvxSizeItem& rSize = (const SvxSizeItem&)*pItem;
         // if the size is already swapped (Landscape)
-        aBspWin.SetSize( rSize.GetSize() );
+        m_pBspWin->SetSize( rSize.GetSize() );
     }
 
     // Evaluate Header attribute
@@ -786,11 +804,11 @@
                 rHeaderSet.Get( GetWhich( SID_ATTR_LRSPACE ) );
             long nDist = rUL.GetLower();
 
-            aBspWin.SetHdHeight( rSize.GetSize().Height() - nDist );
-            aBspWin.SetHdDist( nDist );
-            aBspWin.SetHdLeft( rLR.GetLeft() );
-            aBspWin.SetHdRight( rLR.GetRight() );
-            aBspWin.SetHeader( sal_True );
+            m_pBspWin->SetHdHeight( rSize.GetSize().Height() - nDist );
+            m_pBspWin->SetHdDist( nDist );
+            m_pBspWin->SetHdLeft( rLR.GetLeft() );
+            m_pBspWin->SetHdRight( rLR.GetRight() );
+            m_pBspWin->SetHeader( sal_True );
         }
         else
             pSetItem = 0;
@@ -798,12 +816,12 @@
 
     if ( !pSetItem )
     {
-        aBspWin.SetHeader( sal_False );
+        m_pBspWin->SetHeader( sal_False );
 
         if ( SID_ATTR_PAGE_HEADERSET == nId )
         {
-            aCntSharedBox.Disable();
-            aCntSharedFirstBox.Disable();
+            m_pCntSharedBox->Disable();
+            m_pCntSharedFirstBox->Disable();
         }
     }
     pSetItem = 0;
@@ -826,11 +844,11 @@
                 rFooterSet.Get( GetWhich( SID_ATTR_LRSPACE ) );
             long nDist = rUL.GetUpper();
 
-            aBspWin.SetFtHeight( rSize.GetSize().Height() - nDist );
-            aBspWin.SetFtDist( nDist );
-            aBspWin.SetFtLeft( rLR.GetLeft() );
-            aBspWin.SetFtRight( rLR.GetRight() );
-            aBspWin.SetFooter( sal_True );
+            m_pBspWin->SetFtHeight( rSize.GetSize().Height() - nDist );
+            m_pBspWin->SetFtDist( nDist );
+            m_pBspWin->SetFtLeft( rLR.GetLeft() );
+            m_pBspWin->SetFtRight( rLR.GetRight() );
+            m_pBspWin->SetFooter( sal_True );
         }
         else
             pSetItem = 0;
@@ -838,12 +856,12 @@
 
     if ( !pSetItem )
     {
-        aBspWin.SetFooter( sal_False );
+        m_pBspWin->SetFooter( sal_False );
 
         if ( SID_ATTR_PAGE_FOOTERSET == nId )
         {
-            aCntSharedBox.Disable();
-            aCntSharedFirstBox.Disable();
+            m_pCntSharedBox->Disable();
+            m_pCntSharedFirstBox->Disable();
         }
     }
 
@@ -851,16 +869,16 @@
 
     if ( pItem && pItem->ISA(SfxBoolItem) )
     {
-        aBspWin.SetTable( sal_True );
-        aBspWin.SetHorz( ( (SfxBoolItem*)pItem )->GetValue() );
+        m_pBspWin->SetTable( sal_True );
+        m_pBspWin->SetHorz( ( (SfxBoolItem*)pItem )->GetValue() );
     }
 
     pItem = GetItem( rSet, SID_ATTR_PAGE_EXT2 );
 
     if ( pItem && pItem->ISA(SfxBoolItem) )
     {
-        aBspWin.SetTable( sal_True );
-        aBspWin.SetVert( ( (SfxBoolItem*)pItem )->GetValue() );
+        m_pBspWin->SetTable( sal_True );
+        m_pBspWin->SetVert( ( (SfxBoolItem*)pItem )->GetValue() );
     }
     ResetBackground_Impl( rSet );
     RangeHdl( 0 );
@@ -875,16 +893,16 @@
 
 IMPL_LINK_NOARG(SvxHFPage, RangeHdl)
 {
-    long nHHeight = aBspWin.GetHdHeight();
-    long nHDist   = aBspWin.GetHdDist();
+    long nHHeight = m_pBspWin->GetHdHeight();
+    long nHDist   = m_pBspWin->GetHdDist();
 
-    long nFHeight = aBspWin.GetFtHeight();
-    long nFDist   = aBspWin.GetFtDist();
+    long nFHeight = m_pBspWin->GetFtHeight();
+    long nFDist   = m_pBspWin->GetFtDist();
 
     long nHeight = Max( (long)MINBODY,
-        static_cast<long>(aHeightEdit.Denormalize( aHeightEdit.GetValue( FUNIT_TWIP ) ) ) );
-    long nDist   = aTurnOnBox.IsChecked() ?
-        static_cast<long>(aDistEdit.Denormalize( aDistEdit.GetValue( FUNIT_TWIP ) )) : 0;
+        static_cast<long>(m_pHeightEdit->Denormalize( m_pHeightEdit->GetValue( FUNIT_TWIP ) ) ) );
+    long nDist   = m_pTurnOnBox->IsChecked() ?
+        static_cast<long>(m_pDistEdit->Denormalize( m_pDistEdit->GetValue( FUNIT_TWIP ) )) : 0;
 
     long nMin;
     long nMax;
@@ -901,13 +919,13 @@
     }
 
     // Current values of the side edges
-    long nBT = aBspWin.GetTop();
-    long nBB = aBspWin.GetBottom();
-    long nBL = aBspWin.GetLeft();
-    long nBR = aBspWin.GetRight();
+    long nBT = m_pBspWin->GetTop();
+    long nBB = m_pBspWin->GetBottom();
+    long nBL = m_pBspWin->GetLeft();
+    long nBR = m_pBspWin->GetRight();
 
-    long nH  = aBspWin.GetSize().Height();
-    long nW  = aBspWin.GetSize().Width();
+    long nH  = m_pBspWin->GetSize().Height();
+    long nW  = m_pBspWin->GetSize().Width();
 
     // Borders
     if ( nId == SID_ATTR_PAGE_HEADERSET )
@@ -916,11 +934,11 @@
         nMin = ( nH - nBB - nBT ) / 5; // 20%
         nMax = Max( nH - nMin - nHDist - nFDist - nFHeight - nBB - nBT,
                     nMin );
-        aHeightEdit.SetMax( aHeightEdit.Normalize( nMax ), FUNIT_TWIP );
+        m_pHeightEdit->SetMax( m_pHeightEdit->Normalize( nMax ), FUNIT_TWIP );
         nMin = ( nH - nBB - nBT ) / 5; // 20%
         nDist = Max( nH - nMin - nHHeight - nFDist - nFHeight - nBB - nBT,
                      long(0) );
-        aDistEdit.SetMax( aDistEdit.Normalize( nDist ), FUNIT_TWIP );
+        m_pDistEdit->SetMax( m_pDistEdit->Normalize( nDist ), FUNIT_TWIP );
     }
     else
     {
@@ -928,21 +946,21 @@
         nMin = ( nH - nBT - nBB ) / 5; // 20%
         nMax = Max( nH - nMin - nFDist - nHDist - nHHeight - nBT - nBB,
                     nMin );
-        aHeightEdit.SetMax( aHeightEdit.Normalize( nMax ), FUNIT_TWIP );
+        m_pHeightEdit->SetMax( m_pHeightEdit->Normalize( nMax ), FUNIT_TWIP );
         nMin = ( nH - nBT - nBB ) / 5; // 20%
         nDist = Max( nH - nMin - nFHeight - nHDist - nHHeight - nBT - nBB,
                      long(0) );
-        aDistEdit.SetMax( aDistEdit.Normalize( nDist ), FUNIT_TWIP );
+        m_pDistEdit->SetMax( m_pDistEdit->Normalize( nDist ), FUNIT_TWIP );
     }
 
     // Limit Indentation
     nMax = nW - nBL - nBR -
-           static_cast<long>(aRMEdit.Denormalize( aRMEdit.GetValue( FUNIT_TWIP ) )) - MINBODY;
-    aLMEdit.SetMax( aLMEdit.Normalize( nMax ), FUNIT_TWIP );
+           static_cast<long>(m_pRMEdit->Denormalize( m_pRMEdit->GetValue( FUNIT_TWIP ) )) - 
MINBODY;
+    m_pLMEdit->SetMax( m_pLMEdit->Normalize( nMax ), FUNIT_TWIP );
 
     nMax = nW - nBL - nBR -
-           static_cast<long>(aLMEdit.Denormalize( aLMEdit.GetValue( FUNIT_TWIP ) )) - MINBODY;
-    aRMEdit.SetMax( aLMEdit.Normalize( nMax ), FUNIT_TWIP );
+           static_cast<long>(m_pLMEdit->Denormalize( m_pLMEdit->GetValue( FUNIT_TWIP ) )) - 
MINBODY;
+    m_pRMEdit->SetMax( m_pLMEdit->Normalize( nMax ), FUNIT_TWIP );
     return 0;
 }
 
@@ -954,17 +972,17 @@
 }
 void SvxHFPage::EnableDynamicSpacing()
 {
-    aDynSpacingCB.Show();
+    m_pDynSpacingCB->Show();
     //move all following controls
     Window* aMoveWindows[] =
     {
-        &aHeightFT,
-        &aHeightEdit,
-        &aHeightDynBtn,
-        &aBackgroundBtn,
+        m_pHeightFT,
+        m_pHeightEdit,
+        m_pHeightDynBtn,
+        m_pBackgroundBtn,
         0
     };
-    sal_Int32 nOffset = aTurnOnBox.GetPosPixel().Y() - aCntSharedBox.GetPosPixel().Y();
+    sal_Int32 nOffset = m_pTurnOnBox->GetPosPixel().Y() - m_pCntSharedBox->GetPosPixel().Y();
     sal_Int32 nIdx = 0;
     while(aMoveWindows[nIdx])
         lcl_Move(*aMoveWindows[nIdx++], nOffset);
diff --git a/svx/source/dialog/hdft.hrc b/svx/source/dialog/hdft.hrc
deleted file mode 100644
index 7bed549..0000000
--- a/svx/source/dialog/hdft.hrc
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * 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 _SVX_HDFT_HRC
-#define _SVX_HDFT_HRC
-
-// defines ---------------------------------------------------------------
-
-#define CB_TURNON       10
-#define FT_DIST         11
-#define ED_DIST         12
-#define FT_HEIGHT       13
-#define ED_HEIGHT       14
-#define CB_HEIGHT_DYN   15
-#define FT_LMARGIN      16
-#define ED_LMARGIN      17
-#define FT_RMARGIN      18
-#define ED_RMARGIN      19
-#define CB_SHARED       20
-#define FL_FRAME        21
-#define CB_DYNSPACING   22
-#define CB_SHARED_FIRST 23
-
-#define WN_BSP          30
-
-#define BTN_EXTRAS      40
-
-
-#endif
-
diff --git a/svx/source/dialog/hdft.src b/svx/source/dialog/hdft.src
deleted file mode 100644
index 37bc152..0000000
--- a/svx/source/dialog/hdft.src
+++ /dev/null
@@ -1,348 +0,0 @@
-/*
- * 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 "helpid.hrc"
-#include <svx/dialogs.hrc>
-#include "hdft.hrc"
-
-#define  _TEXT_FT_LMARGIN \
-        Text [ en-US ] = "~Left margin" ;                              \
-
-#define _TEXT_FT_RMARGIN \
-        Text [ en-US ] = "R~ight margin" ;                             \
-
-
- // RID_SVXPAGE_HEADER ----------------------------------------------------
-TabPage RID_SVXPAGE_HEADER
-{
-    HelpId = HID_FORMAT_HEADER ;
-    Hide = TRUE ;
-    Text [ en-US ] = "Header" ;
-    Size = MAP_APPFONT ( TP_WIDTH , TP_HEIGHT ) ;
-    CheckBox CB_TURNON
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_HEADER:CB_TURNON";
-        Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "Hea~der on" ;
-    };
-    CheckBox CB_SHARED
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_HEADER:CB_SHARED";
-        Pos = MAP_APPFONT ( 12 , 30 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "Same ~content left/right" ;
-    };
-    CheckBox CB_SHARED_FIRST
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_HEADER:CB_SHARED_FIRST";
-        Pos = MAP_APPFONT ( 12 , 46 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "Same content on first page" ;
-    };
-    FixedText FT_LMARGIN
-    {
-        Pos = MAP_APPFONT ( 12 , 64 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        _TEXT_FT_LMARGIN
-        Left = TRUE ;
-    };
-    MetricField ED_LMARGIN
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_HEADER:ED_LMARGIN";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 62 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Maximum = 9999 ;
-        Minimum = 0 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    FixedText FT_RMARGIN
-    {
-        Pos = MAP_APPFONT ( 12 , 80 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        _TEXT_FT_RMARGIN
-        Left = TRUE ;
-    };
-    MetricField ED_RMARGIN
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_HEADER:ED_RMARGIN";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 78 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Minimum = 0 ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-
-    FixedText FT_DIST
-    {
-        Pos = MAP_APPFONT ( 12 , 98 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        Text [ en-US ] = "~Spacing" ;
-    };
-    MetricField ED_DIST
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_HEADER:ED_DIST";
-        Disable = TRUE ;
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 96 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    CheckBox CB_DYNSPACING
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_HEADER:CB_DYNSPACING";
-        Pos = MAP_APPFONT ( 12 , 112 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Hide = TRUE;
-        Text [ en-US ] = "Use d~ynamic spacing" ;
-    };
-    FixedText FT_HEIGHT
-    {
-        Pos = MAP_APPFONT ( 12 , 114 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        Text [ en-US ] = "~Height" ;
-    };
-    MetricField ED_HEIGHT
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_HEADER:ED_HEIGHT";
-        Disable = TRUE ;
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 112 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Minimum = 10 ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        First = 50 ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    CheckBox CB_HEIGHT_DYN
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_HEADER:CB_HEIGHT_DYN";
-        Pos = MAP_APPFONT ( 12 , 128 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "~AutoFit height" ;
-    };
-    FixedLine FL_FRAME
-    {
-        Pos = MAP_APPFONT ( 6 , 3 ) ;
-        Size = MAP_APPFONT ( 164 , 8 ) ;
-        Text [ en-US ] = "Header" ;
-    };
-    Window WN_BSP
-    {
-        Pos = MAP_APPFONT ( 176 , 6 ) ;
-        Size = MAP_APPFONT ( 75 , 46 ) ;
-    };
-    PushButton BTN_EXTRAS
-    {
-        HelpID = "svx:PushButton:RID_SVXPAGE_HEADER:BTN_EXTRAS";
-        Pos = MAP_APPFONT ( 12 , 146 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        Text [ en-US ] = "~More..." ;
-    };
-};
- // RID_SVXPAGE_FOOTER ----------------------------------------------------
-TabPage RID_SVXPAGE_FOOTER
-{
-    HelpId = HID_FORMAT_FOOTER ;
-    Hide = TRUE ;
-    Text [ en-US ] = "Footer" ;
-    Size = MAP_APPFONT ( TP_WIDTH , TP_HEIGHT ) ;
-    CheckBox CB_TURNON
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_FOOTER:CB_TURNON";
-        Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "~Footer on" ;
-    };
-    CheckBox CB_SHARED
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_FOOTER:CB_SHARED";
-        Pos = MAP_APPFONT ( 12 , 30 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "Same ~content left/right" ;
-    };
-    CheckBox CB_SHARED_FIRST
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_FOOTER:CB_SHARED_FIRST";
-        Pos = MAP_APPFONT ( 12 , 46 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "Same content on first page" ;
-    };
-    FixedText FT_LMARGIN
-    {
-        Pos = MAP_APPFONT ( 12 , 64 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        Left = TRUE ;
-        _TEXT_FT_LMARGIN
-    };
-    MetricField ED_LMARGIN
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_FOOTER:ED_LMARGIN";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 62 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Minimum = 0 ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    FixedText FT_RMARGIN
-    {
-        Pos = MAP_APPFONT ( 12 , 80 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        _TEXT_FT_RMARGIN
-        Left = TRUE ;
-    };
-    MetricField ED_RMARGIN
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_FOOTER:ED_RMARGIN";
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 78 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Minimum = 0 ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    FixedText FT_DIST
-    {
-        Pos = MAP_APPFONT ( 12 , 98 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        Text [ en-US ] = "~Spacing" ;
-    };
-    MetricField ED_DIST
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_FOOTER:ED_DIST";
-        Disable = TRUE ;
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 96 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    CheckBox CB_DYNSPACING
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_FOOTER:CB_DYNSPACING";
-        Pos = MAP_APPFONT ( 12 , 112 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Hide = TRUE;
-        Text [ en-US ] = "Use d~ynamic spacing" ;
-    };
-    FixedText FT_HEIGHT
-    {
-        Pos = MAP_APPFONT ( 12 , 114 ) ;
-        Size = MAP_APPFONT ( 102 , 8 ) ;
-        Disable = TRUE ;
-        Text [ en-US ] = "~Height" ;
-    };
-    MetricField ED_HEIGHT
-    {
-        HelpID = "svx:MetricField:RID_SVXPAGE_FOOTER:ED_HEIGHT";
-        Disable = TRUE ;
-        Border = TRUE ;
-        Pos = MAP_APPFONT ( 124 , 112 ) ;
-        Size = MAP_APPFONT ( 40 , 12 ) ;
-        Left = TRUE ;
-        Repeat = TRUE ;
-        Spin = TRUE ;
-        Minimum = 10 ;
-        Maximum = 9999 ;
-        DecimalDigits = 2 ;
-        Unit = FUNIT_CM ;
-        First = 50 ;
-        Last = 9999 ;
-        SpinSize = 10 ;
-    };
-    CheckBox CB_HEIGHT_DYN
-    {
-        HelpID = "svx:CheckBox:RID_SVXPAGE_FOOTER:CB_HEIGHT_DYN";
-        Pos = MAP_APPFONT ( 12 , 128 ) ;
-        Size = MAP_APPFONT ( 152 , 10 ) ;
-        Text [ en-US ] = "~AutoFit height" ;
-    };
-
-    FixedLine FL_FRAME
-    {
-        Pos = MAP_APPFONT ( 6 , 3 ) ;
-        Size = MAP_APPFONT ( 164 , 8 ) ;
-        Text [ en-US ] = "Footer" ;
-    };
-    Window WN_BSP
-    {
-        Pos = MAP_APPFONT ( 176 , 6 ) ;
-        Size = MAP_APPFONT ( 75 , 46 ) ;
-    };
-    PushButton BTN_EXTRAS
-    {
-        HelpID = "svx:PushButton:RID_SVXPAGE_FOOTER:BTN_EXTRAS";
-        Pos = MAP_APPFONT ( 12 , 146 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        Text [ en-US ] = "~More..." ;
-    };
-};
-QueryBox RID_SVXQBX_DELETE_HEADFOOT
-{
-    Buttons = WB_YES_NO ;
-    DefButton = WB_DEF_NO ;
-    Message [ en-US ] = "Removing headers or footers deletes the contents.\nDo you want to delete 
this text?" ;
-};
-
- // ********************************************************************** EOF
diff --git a/svx/uiconfig/ui/headfootformatpage.ui b/svx/uiconfig/ui/headfootformatpage.ui
new file mode 100644
index 0000000..b6a26ba
--- /dev/null
+++ b/svx/uiconfig/ui/headfootformatpage.ui
@@ -0,0 +1,477 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <!-- interface-requires LibreOffice 1.0 -->
+  <object class="GtkGrid" id="HFFormatPage">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="halign">start</property>
+    <property name="valign">start</property>
+    <property name="border_width">6</property>
+    <property name="row_spacing">6</property>
+    <property name="column_spacing">12</property>
+    <child>
+      <object class="GtkFrame" id="frame1">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="hexpand">True</property>
+        <property name="vexpand">True</property>
+        <property name="label_xalign">0</property>
+        <property name="shadow_type">none</property>
+        <child>
+          <object class="GtkAlignment" id="alignment2">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="hexpand">True</property>
+            <property name="vexpand">True</property>
+            <property name="top_padding">6</property>
+            <property name="left_padding">12</property>
+            <child>
+              <object class="GtkBox" id="box1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="halign">start</property>
+                <property name="valign">start</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">6</property>
+                <child>
+                  <object class="GtkCheckButton" id="checkHeaderOn">
+                    <property name="label" translatable="yes">Hea_der on</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">False</property>
+                    <property name="use_underline">True</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="GtkFrame" id="frameHdrOn">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="label_xalign">0</property>
+                    <property name="label_yalign">0</property>
+                    <property name="shadow_type">none</property>
+                    <child>
+                      <object class="GtkAlignment" id="alignment4">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="halign">start</property>
+                        <property name="valign">start</property>
+                        <property name="left_padding">12</property>
+                        <child>
+                          <object class="GtkGrid" id="grid5">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">start</property>
+                            <property name="valign">start</property>
+                            <property name="row_spacing">6</property>
+                            <property name="column_spacing">12</property>
+                            <child>
+                              <object class="GtkCheckButton" id="checkSameLR">
+                                <property name="label" translatable="yes">Same _content 
left/right</property>
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="receives_default">False</property>
+                                <property name="use_underline">True</property>
+                                <property name="xalign">0</property>
+                                <property name="draw_indicator">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">0</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkCheckButton" id="checkSameFP">
+                                <property name="label" translatable="yes">Same content on first 
page</property>
+                                <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="left_attach">0</property>
+                                <property name="top_attach">1</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkLabel" id="labelLeftMarg">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="xalign">0</property>
+                                <property name="label" translatable="yes">_Left margin:</property>
+                                <property name="use_underline">True</property>
+                                <property name="mnemonic_widget">spinMargLeft:0.00cm</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">2</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkSpinButton" id="spinMargLeft:0.00cm">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="invisible_char">•</property>
+                                <property name="invisible_char_set">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">1</property>
+                                <property name="top_attach">2</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkLabel" id="labelRightMarg">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="xalign">0</property>
+                                <property name="label" translatable="yes">R_ight margin:</property>
+                                <property name="use_underline">True</property>
+                                <property name="mnemonic_widget">spinMargRight:0.00cm</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">3</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkSpinButton" id="spinMargRight:0.00cm">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="invisible_char">•</property>
+                                <property name="invisible_char_set">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">1</property>
+                                <property name="top_attach">3</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkLabel" id="labelSpacing">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="xalign">0</property>
+                                <property name="label" translatable="yes">_Spacing:</property>
+                                <property name="use_underline">True</property>
+                                <property name="mnemonic_widget">spinSpacing:0.00cm</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">4</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkSpinButton" id="spinSpacing:0.00cm">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="invisible_char">•</property>
+                                <property name="invisible_char_set">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">1</property>
+                                <property name="top_attach">4</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkCheckButton" id="checkDynSpacing">
+                                <property name="label" translatable="yes">Use d_ynamic 
spacing</property>
+                                <property name="can_focus">True</property>
+                                <property name="receives_default">False</property>
+                                <property name="use_underline">True</property>
+                                <property name="xalign">0</property>
+                                <property name="draw_indicator">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">5</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkLabel" id="labelHeight">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="xalign">0</property>
+                                <property name="label" translatable="yes">_Height:</property>
+                                <property name="use_underline">True</property>
+                                <property name="mnemonic_widget">spinHeight:0.00cm</property>
+                                <property name="ellipsize">end</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">6</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkSpinButton" id="spinHeight:0.00cm">
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="invisible_char">•</property>
+                                <property name="invisible_char_set">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">1</property>
+                                <property name="top_attach">6</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkCheckButton" id="checkAutofit">
+                                <property name="label" translatable="yes">_AutoFit 
height</property>
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="receives_default">False</property>
+                                <property name="use_underline">True</property>
+                                <property name="xalign">0</property>
+                                <property name="draw_indicator">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">7</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkButton" id="buttonMore">
+                                <property name="label" translatable="yes">More...</property>
+                                <property name="visible">True</property>
+                                <property name="can_focus">True</property>
+                                <property name="receives_default">True</property>
+                              </object>
+                              <packing>
+                                <property name="left_attach">0</property>
+                                <property name="top_attach">8</property>
+                                <property name="width">1</property>
+                                <property name="height">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <placeholder/>
+                            </child>
+                            <child>
+                              <placeholder/>
+                            </child>
+                            <child>
+                              <placeholder/>
+                            </child>
+                            <child>
+                              <placeholder/>
+                            </child>
+                            <child>
+                              <placeholder/>
+                            </child>
+                          </object>
+                        </child>
+                      </object>
+                    </child>
+                    <child type="label_item">
+                      <placeholder/>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label">
+          <object class="GtkLabel" id="labelHeaderFooterFormat">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="xalign">0</property>
+            <property name="label" translatable="yes">Header</property>
+            <attributes>
+              <attribute name="weight" value="bold"/>
+            </attributes>
+          </object>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">0</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkGrid" id="grid1">
+        <property name="can_focus">False</property>
+        <child>
+          <object class="GtkLabel" id="labelFooterOn">
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Footer on</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="labelFooter">
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Footer</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">1</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="labelHeaderOn">
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Header on</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">0</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkLabel" id="labelHeader">
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Header</property>
+          </object>
+          <packing>
+            <property name="left_attach">1</property>
+            <property name="top_attach">1</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+        <child>
+          <placeholder/>
+        </child>
+        <child>
+          <object class="GtkLabel" id="labelMsg">
+            <property name="can_focus">False</property>
+            <property name="label" translatable="yes">Removing headers or footers deletes the 
contents.
+Do you want to delete this text?</property>
+          </object>
+          <packing>
+            <property name="left_attach">0</property>
+            <property name="top_attach">2</property>
+            <property name="width">1</property>
+            <property name="height">1</property>
+          </packing>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">0</property>
+        <property name="top_attach">1</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <object class="GtkFrame" id="frame2">
+        <property name="visible">True</property>
+        <property name="can_focus">False</property>
+        <property name="label_xalign">0</property>
+        <property name="shadow_type">none</property>
+        <child>
+          <object class="GtkAlignment" id="alignment3">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="left_padding">6</property>
+            <child>
+              <object class="GtkBox" id="box2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">6</property>
+                <child>
+                  <object class="svxlo-SvxPageWindow" id="drawingareaPageHF">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="halign">center</property>
+                    <property name="valign">center</property>
+                    <property name="hexpand">True</property>
+                    <property name="vexpand">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkButton" id="buttonEdit">
+                    <property name="label">gtk-edit</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="use_underline">True</property>
+                    <property name="use_stock">True</property>
+                    <property name="xalign">0.51999998092651367</property>
+                    <property name="always_show_image">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+              </object>
+            </child>
+          </object>
+        </child>
+        <child type="label_item">
+          <placeholder/>
+        </child>
+      </object>
+      <packing>
+        <property name="left_attach">1</property>
+        <property name="top_attach">0</property>
+        <property name="width">1</property>
+        <property name="height">1</property>
+      </packing>
+    </child>
+    <child>
+      <placeholder/>
+    </child>
+  </object>
+  <object class="GtkSizeGroup" id="sizegroup1">
+    <property name="ignore_hidden">True</property>
+    <widgets>
+      <widget name="spinMargLeft:0.00cm"/>
+      <widget name="frame2"/>
+    </widgets>
+  </object>
+</interface>

-- 
To view, visit https://gerrit.libreoffice.org/2478
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iab4eec4fb2497d17c8eb1ab2bab7c31b028af7b0
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Olivier Hallot <olivier.hallot@alta.org.br>


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.