cui/source/dialogs/hlmarkwn.cxx                 |   11 
 cui/source/dialogs/hyperlinkdoctabpage.cxx      |    6 
 cui/source/dialogs/hyperlinkinternettabpage.cxx |   15 
 cui/source/dialogs/hyperlinktabpagebase.cxx     |    2 
 cui/source/inc/hlmarkwn.hxx                     |    2 
 cui/source/inc/hyperlinkdoctabpage.hxx          |    1 
 cui/source/inc/hyperlinkinternettabpage.hxx     |    1 
 cui/source/inc/hyperlinktabpagebase.hxx         |    1 
 editeng/source/items/legacyitem.cxx             |  621 ------------------------
 include/editeng/adjustitem.hxx                  |   20 
 include/editeng/fhgtitem.hxx                    |    3 
 include/editeng/legacyitem.hxx                  |  112 ----
 include/oox/helper/propertymap.hxx              |    3 
 include/sfx2/ctrlitem.hxx                       |   13 
 include/svl/legacyitem.hxx                      |   52 --
 include/svx/algitem.hxx                         |    5 
 include/svx/autoformathelper.hxx                |   45 -
 include/svx/svxdlg.hxx                          |    3 
 include/vcl/toolbox.hxx                         |    2 
 oox/source/helper/propertymap.cxx               |   16 
 sc/Library_sc.mk                                |    1 
 sc/inc/autoform.hxx                             |    2 
 sc/inc/document.hxx                             |    2 
 sc/inc/global.hxx                               |    1 
 sc/inc/scabstdlg.hxx                            |    2 
 sc/inc/table.hxx                                |    3 
 sc/inc/zforauto.hxx                             |   49 -
 sc/source/core/data/documen3.cxx                |   11 
 sc/source/core/data/global.cxx                  |    5 
 sc/source/core/data/table4.cxx                  |  146 -----
 sc/source/core/tool/autoform.cxx                |   41 -
 sc/source/core/tool/zforauto.cxx                |   88 ---
 sc/source/ui/inc/viewfunc.hxx                   |    1 
 sc/source/ui/view/viewfun2.cxx                  |   21 
 sfx2/source/control/ctrlitem.cxx                |   21 
 svl/Library_svl.mk                              |    1 
 svl/source/items/legacyitem.cxx                 |   69 --
 svx/Library_svx.mk                              |    1 
 svx/inc/legacyitem.hxx                          |   60 --
 svx/source/items/algitem.cxx                    |   17 
 svx/source/items/autoformathelper.cxx           |  232 --------
 svx/source/items/legacyitem.cxx                 |  105 ----
 sw/Library_sw.mk                                |    1 
 sw/inc/fesh.hxx                                 |    1 
 sw/inc/legacyitem.hxx                           |   42 -
 sw/inc/swabstdlg.hxx                            |    3 
 sw/inc/swmodule.hxx                             |    1 
 sw/inc/tblafmt.hxx                              |    1 
 sw/source/core/doc/tblafmt.cxx                  |    5 
 sw/source/core/frmedt/fetab.cxx                 |   10 
 sw/source/core/layout/legacyitem.cxx            |   78 ---
 sw/source/ui/table/convert.cxx                  |    3 
 sw/source/uibase/app/swmodule.cxx               |    5 
 sw/source/uibase/inc/convert.hxx                |    1 
 sw/source/uibase/inc/swcont.hxx                 |    1 
 vcl/source/window/toolbox2.cxx                  |   39 -
 56 files changed, 2 insertions(+), 2002 deletions(-)

New commits:
commit 5648ba78d7880c8555348103408796e6216c7115
Author:     Noel Grandin <[email protected]>
AuthorDate: Fri Feb 13 15:52:51 2026 +0200
Commit:     Noel Grandin <[email protected]>
CommitDate: Sun Feb 15 12:35:31 2026 +0100

    loplugin:unusedmethods
    
    Change-Id: Ibac145ec75271e740871ecb03d838d5f85b8f643
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199374
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <[email protected]>

diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx
index b6f78eaa2b90..e605cd422edd 100644
--- a/cui/source/dialogs/hlmarkwn.cxx
+++ b/cui/source/dialogs/hlmarkwn.cxx
@@ -71,7 +71,6 @@ struct TargetData
 // Constructor for new HyperlinkDialog
 SvxHlinkDlgMarkWnd::SvxHlinkDlgMarkWnd(weld::Window* pParentDialog)
     : GenericDialogController(pParentDialog, 
u"cui/ui/hyperlinkmarkdialog.ui"_ustr, u"HyperlinkMark"_ustr)
-    , mpParent(nullptr)
     , mnError(LERR_NOERROR)
 {
     mxBtApply = m_xBuilder->weld_button(u"ok"_ustr);
@@ -484,15 +483,7 @@ IMPL_LINK_NOARG(SvxHlinkDlgMarkWnd, ClickApplyHdl_Impl, 
weld::Button&, void)
         if (pData->bIsTarget)
         {
             maSelectedMark = pData->aUStrLinkname;
-
-            if (mpParent)
-            {
-                mpParent->SetMarkStr(pData->aUStrLinkname);
-            }
-            else
-            {
-                m_xDialog->response(RET_OK);
-            }
+            m_xDialog->response(RET_OK);
         }
     }
 }
diff --git a/cui/source/dialogs/hyperlinkdoctabpage.cxx 
b/cui/source/dialogs/hyperlinkdoctabpage.cxx
index fa76cbd2432a..a61bf932177f 100644
--- a/cui/source/dialogs/hyperlinkdoctabpage.cxx
+++ b/cui/source/dialogs/hyperlinkdoctabpage.cxx
@@ -145,12 +145,6 @@ OUString HyperlinkDocTabPage::GetCurrentURL() const
 
 void HyperlinkDocTabPage::SetInitFocus() { m_xCbbPath->grab_focus(); }
 
-void HyperlinkDocTabPage::SetMarkStr(const OUString& aStrMark)
-{
-    m_xEdTarget->set_text(aStrMark);
-    ModifiedTargetHdl_Impl(*m_xEdTarget);
-}
-
 bool HyperlinkDocTabPage::ShouldOpenMarkWnd() { return m_bMarkWndOpen; }
 
 void HyperlinkDocTabPage::SetMarkWndShouldOpen(bool bOpen) { m_bMarkWndOpen = 
bOpen; }
diff --git a/cui/source/dialogs/hyperlinkinternettabpage.cxx 
b/cui/source/dialogs/hyperlinkinternettabpage.cxx
index a712a5e66f42..8d1e2f458c40 100644
--- a/cui/source/dialogs/hyperlinkinternettabpage.cxx
+++ b/cui/source/dialogs/hyperlinkinternettabpage.cxx
@@ -176,21 +176,6 @@ void HyperlinkInternetTP::RefreshMarkWindow()
     }
 }
 
-void HyperlinkInternetTP::SetMarkStr(const OUString& aStrMark)
-{
-    OUString aStrURL(m_xCbbTarget->get_active_text());
-
-    const sal_Unicode sUHash = '#';
-    sal_Int32 nPos = aStrURL.lastIndexOf(sUHash);
-
-    if (nPos != -1)
-        aStrURL = aStrURL.copy(0, nPos);
-
-    aStrURL += OUStringChar(sUHash) + aStrMark;
-
-    m_xCbbTarget->set_entry_text(aStrURL);
-}
-
 void HyperlinkInternetTP::SetInitFocus() { m_xCbbTarget->grab_focus(); }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/cui/source/dialogs/hyperlinktabpagebase.cxx 
b/cui/source/dialogs/hyperlinktabpagebase.cxx
index 33d83ea125de..64736f8acd0e 100644
--- a/cui/source/dialogs/hyperlinktabpagebase.cxx
+++ b/cui/source/dialogs/hyperlinktabpagebase.cxx
@@ -155,8 +155,6 @@ void HyperlinkTabPageBase::SetInitFocus()
         m_xIndication->grab_focus();
 }
 
-void HyperlinkTabPageBase::SetMarkStr(const OUString&) {}
-
 void HyperlinkTabPageBase::Reset(const SfxItemSet* pItemSet)
 {
     // Get hyperlink item from the item set
diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx
index d179cc1f1c22..7cf92136eb57 100644
--- a/cui/source/inc/hlmarkwn.hxx
+++ b/cui/source/inc/hlmarkwn.hxx
@@ -32,8 +32,6 @@ class HyperlinkTabPageBase;
 class SvxHlinkDlgMarkWnd : public weld::GenericDialogController
 {
 private:
-    HyperlinkTabPageBase* mpParent;
-
     sal_uInt16          mnError;
 
     std::unique_ptr<weld::Button> mxBtApply;
diff --git a/cui/source/inc/hyperlinkdoctabpage.hxx 
b/cui/source/inc/hyperlinkdoctabpage.hxx
index dd49b5941b65..039860537544 100644
--- a/cui/source/inc/hyperlinkdoctabpage.hxx
+++ b/cui/source/inc/hyperlinkdoctabpage.hxx
@@ -57,7 +57,6 @@ public:
     static std::unique_ptr<SfxTabPage>
     Create(weld::Container* pParent, weld::DialogController* pController, 
const SfxItemSet* pSet);
 
-    virtual void SetMarkStr(const OUString& aStrMark) override;
     virtual void SetInitFocus() override;
 };
 
diff --git a/cui/source/inc/hyperlinkinternettabpage.hxx 
b/cui/source/inc/hyperlinkinternettabpage.hxx
index 9775f5aeff2e..94cb3944ec54 100644
--- a/cui/source/inc/hyperlinkinternettabpage.hxx
+++ b/cui/source/inc/hyperlinkinternettabpage.hxx
@@ -46,7 +46,6 @@ public:
     static std::unique_ptr<SfxTabPage>
     Create(weld::Container* pParent, weld::DialogController* pController, 
const SfxItemSet* pSet);
 
-    virtual void SetMarkStr(const OUString& aStrMark) override;
     virtual void SetInitFocus() override;
 };
 
diff --git a/cui/source/inc/hyperlinktabpagebase.hxx 
b/cui/source/inc/hyperlinktabpagebase.hxx
index fb99ae769596..270ffb8d942d 100644
--- a/cui/source/inc/hyperlinktabpagebase.hxx
+++ b/cui/source/inc/hyperlinktabpagebase.hxx
@@ -89,7 +89,6 @@ public:
     bool FillItemSet(SfxItemSet* pItemSet) override;
 
     virtual void SetInitFocus();
-    virtual void SetMarkStr(const OUString& aStrMark);
 
     bool IsMarkWndVisible() const { return static_cast<bool>(mxMarkWnd); }
 };
diff --git a/editeng/source/items/legacyitem.cxx 
b/editeng/source/items/legacyitem.cxx
index c7dd147ee253..28d6ba8ecbf2 100644
--- a/editeng/source/items/legacyitem.cxx
+++ b/editeng/source/items/legacyitem.cxx
@@ -49,440 +49,10 @@
 #include <tools/GenericTypeSerializer.hxx>
 
 
-void Create_legacy_direct_set(SvxFontHeightItem& rItem, sal_uInt32 nH, 
sal_uInt16 nP, MapUnit eP)
-{
-    rItem.legacy_direct_set(nH, nP, eP);
-}
-
 namespace legacy
 {
-    namespace SvxFont
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxFontItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt8 _eFamily, eFontPitch, eFontTextEncoding;
-            OUString aName, aStyle;
-            rStrm.ReadUChar( _eFamily );
-            rStrm.ReadUChar( eFontPitch );
-            rStrm.ReadUChar( eFontTextEncoding );
-
-            // UNICODE: rStrm >> aName;
-            aName = rStrm.ReadUniOrByteString(rStrm.GetStreamCharSet());
-
-            // UNICODE: rStrm >> aStyle;
-            aStyle = rStrm.ReadUniOrByteString(rStrm.GetStreamCharSet());
-
-            // Set the "correct" textencoding
-            eFontTextEncoding = static_cast<sal_uInt8>(GetSOLoadTextEncoding( 
eFontTextEncoding ));
-
-            // at some point, the StarBats changes from  ANSI font to SYMBOL 
font
-            if ( RTL_TEXTENCODING_SYMBOL != eFontTextEncoding && aName == 
"StarBats" )
-                eFontTextEncoding = RTL_TEXTENCODING_SYMBOL;
-
-            // Check if we have stored unicode
-            sal_uInt64 const nStreamPos = rStrm.Tell();
-            // #define STORE_UNICODE_MAGIC_MARKER  0xFE331188
-            sal_uInt32 nMagic = 0xFE331188;
-            rStrm.ReadUInt32( nMagic );
-            if ( nMagic == 0xFE331188 )
-            {
-                aName = rStrm.ReadUniOrByteString( RTL_TEXTENCODING_UNICODE );
-                aStyle = rStrm.ReadUniOrByteString( RTL_TEXTENCODING_UNICODE );
-            }
-            else
-            {
-                rStrm.Seek( nStreamPos );
-            }
-
-            rItem.SetFamilyName(aName);
-            rItem.SetStyleName(aStyle);
-            rItem.SetFamily(static_cast<FontFamily>(_eFamily));
-            rItem.SetPitch(static_cast<FontPitch>(eFontPitch));
-            rItem.SetCharSet(static_cast<rtl_TextEncoding>(eFontTextEncoding));
-        }
-
-        SvStream& Store(const SvxFontItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            const bool bToBats(IsOpenSymbol(rItem.GetFamilyName()));
-
-            
rStrm.WriteUChar(rItem.GetFamily()).WriteUChar(rItem.GetPitch()).WriteUChar(bToBats
 ?
-                    RTL_TEXTENCODING_SYMBOL :
-                    GetSOStoreTextEncoding(rItem.GetCharSet()));
-
-            const OUString aStoreFamilyName(bToBats ? u"StarBats"_ustr : 
rItem.GetFamilyName());
-
-            rStrm.WriteUniOrByteString(aStoreFamilyName, 
rStrm.GetStreamCharSet());
-            rStrm.WriteUniOrByteString(rItem.GetStyleName(), 
rStrm.GetStreamCharSet());
-
-            return rStrm;
-        }
-    }
-
-    namespace SvxFontHeight
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            return (nFileFormatVersion <= SOFFICE_FILEFORMAT_40)
-                    ? FONTHEIGHT_16_VERSION
-                    : FONTHEIGHT_UNIT_VERSION;
-        }
-
-        void Create(SvxFontHeightItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            sal_uInt16 nsize, nprop = 0;
-            MapUnit nPropUnit = MapUnit::MapRelative;
-
-            rStrm.ReadUInt16( nsize );
-
-            if( FONTHEIGHT_16_VERSION <= nItemVersion )
-                rStrm.ReadUInt16( nprop );
-            else
-            {
-                sal_uInt8 nP;
-                rStrm .ReadUChar( nP );
-                nprop = static_cast<sal_uInt16>(nP);
-            }
-
-            if( FONTHEIGHT_UNIT_VERSION <= nItemVersion )
-            {
-                sal_uInt16 nTmp;
-                rStrm.ReadUInt16( nTmp );
-                nPropUnit = static_cast<MapUnit>(nTmp);
-            }
-
-            Create_legacy_direct_set(rItem, nsize, nprop, nPropUnit);
-        }
-
-        SvStream& Store(const SvxFontHeightItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion)
-        {
-            rStrm.WriteUInt16( rItem.GetHeight() );
-
-            if( FONTHEIGHT_UNIT_VERSION <= nItemVersion )
-                rStrm.WriteUInt16( rItem.GetProp() ).WriteUInt16( 
static_cast<sal_uInt16>(rItem.GetPropUnit()) );
-            else
-            {
-                // When exporting to the old versions the relative information 
is lost
-                // when there is no percentage
-                sal_uInt16 _nProp = rItem.GetProp();
-                if( MapUnit::MapRelative != rItem.GetPropUnit() )
-                    _nProp = 100;
-                rStrm.WriteUInt16( _nProp );
-            }
-            return rStrm;
-        }
-    }
-
-    namespace SvxWeight
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxWeightItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt8 nWeight(0);
-            rStrm.ReadUChar(nWeight);
-            rItem.SetValue(static_cast<FontWeight>(nWeight));
-        }
-
-        SvStream& Store(const SvxWeightItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUChar(rItem.GetValue());
-            return rStrm;
-        }
-    }
-
-    namespace SvxPosture
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxPostureItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt8 nPosture(0);
-            rStrm.ReadUChar(nPosture);
-            rItem.SetValue(static_cast<FontItalic>(nPosture));
-        }
-
-        SvStream& Store(const SvxPostureItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUChar( rItem.GetValue() );
-            return rStrm;
-        }
-    }
-
-    namespace SvxTextLine // SvxUnderlineItem, SvxOverlineItem -> 
SvxTextLineItem
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxTextLineItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt8 nState(0);
-            rStrm.ReadUChar(nState);
-            rItem.SetValue(static_cast<FontLineStyle>(nState));
-            // GetColor() is *not* saved/loaded ?!?
-        }
-
-        SvStream& Store(const SvxTextLineItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUChar(rItem.GetValue());
-            // GetColor() is *not* saved/loaded ?!?
-            return rStrm;
-        }
-    }
-
-    namespace SvxCrossedOut
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxCrossedOutItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt8 eCross(0);
-            rStrm.ReadUChar(eCross);
-            rItem.SetValue(static_cast<FontStrikeout>(eCross));
-        }
-
-        SvStream& Store(const SvxCrossedOutItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUChar(rItem.GetValue());
-            return rStrm;
-        }
-    }
-
-    namespace SvxColor
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            DBG_ASSERT( SOFFICE_FILEFORMAT_31==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_40==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_50==nFileFormatVersion,
-                    "SvxColorItem: Is there a new file format? ");
-            return  SOFFICE_FILEFORMAT_50 >= nFileFormatVersion ? 
VERSION_USEAUTOCOLOR : 0;
-        }
-
-        void Create(SvxColorItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            Color aColor(COL_AUTO);
-            tools::GenericTypeSerializer aSerializer(rStrm);
-            aSerializer.readColor(aColor);
-            rItem.SetValue(aColor);
-        }
-
-        SvStream& Store(const SvxColorItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            tools::GenericTypeSerializer aSerializer(rStrm);
-            if( VERSION_USEAUTOCOLOR == nItemVersion && COL_AUTO == 
rItem.GetValue() )
-                aSerializer.writeColor(COL_BLACK);
-            else
-                aSerializer.writeColor(rItem.GetValue());
-            return rStrm;
-        }
-    }
-
-    namespace SvxBox
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            DBG_ASSERT( SOFFICE_FILEFORMAT_31==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_40==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_50==nFileFormatVersion,
-                    "SvxBoxItem: Is there a new file format?" );
-            return SOFFICE_FILEFORMAT_31==nFileFormatVersion ||
-                SOFFICE_FILEFORMAT_40==nFileFormatVersion ? 0 : 
BOX_BORDER_STYLE_VERSION;
-        }
-
-        /// Item version for saved border lines. The old version saves the 
line without style information.
-        const int BORDER_LINE_OLD_VERSION = 0;
-        /// Item version for saved border lies. The new version includes line 
style.
-        const int BORDER_LINE_WITH_STYLE_VERSION = 1;
-
-        /// Creates a border line from a stream.
-        static ::editeng::SvxBorderLine CreateBorderLine(SvStream &stream, 
sal_uInt16 version)
-        {
-            sal_uInt16 nOutline, nInline, nDistance;
-            sal_uInt16 nStyle = css::table::BorderLineStyle::NONE;
-            Color aColor;
-            tools::GenericTypeSerializer aSerializer(stream);
-            aSerializer.readColor(aColor);
-            stream.ReadUInt16( nOutline ).ReadUInt16( nInline ).ReadUInt16( 
nDistance );
-
-            if (version >= BORDER_LINE_WITH_STYLE_VERSION)
-                stream.ReadUInt16( nStyle );
-
-            ::editeng::SvxBorderLine border(&aColor);
-            border.GuessLinesWidths(static_cast<SvxBorderLineStyle>(nStyle), 
nOutline, nInline, nDistance);
-            return border;
-        }
-
-        /// Retrieves a BORDER_LINE_* version from a BOX_BORDER_* version.
-        static sal_uInt16 BorderLineVersionFromBoxVersion(sal_uInt16 
boxVersion)
-        {
-            return (boxVersion >= BOX_BORDER_STYLE_VERSION)? 
BORDER_LINE_WITH_STYLE_VERSION : BORDER_LINE_OLD_VERSION;
-        }
-
-        void Create(SvxBoxItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            sal_uInt16 nDistance(0);
-            rStrm.ReadUInt16( nDistance );
-            SvxBoxItemLine aLineMap[4] = { SvxBoxItemLine::TOP, 
SvxBoxItemLine::LEFT,
-                                SvxBoxItemLine::RIGHT, SvxBoxItemLine::BOTTOM 
};
-            sal_Int8 cLine(0);
-
-            while (rStrm.good())
-            {
-                rStrm.ReadSChar( cLine );
-
-                if( cLine > 3 )
-                    break;
-
-                ::editeng::SvxBorderLine aBorder = CreateBorderLine(rStrm, 
BorderLineVersionFromBoxVersion(nItemVersion));
-                rItem.SetLine( &aBorder, aLineMap[cLine] );
-            }
-
-            if( nItemVersion >= BOX_4DISTS_VERSION && (cLine&0x10) != 0 )
-            {
-                for(const SvxBoxItemLine & i : aLineMap)
-                {
-                    sal_uInt16 nDist;
-                    rStrm.ReadUInt16( nDist );
-                    rItem.SetDistance( nDist, i );
-                }
-            }
-            else
-            {
-                rItem.SetAllDistances(nDistance);
-            }
-        }
-
-        /// Store a border line to a stream.
-        static SvStream& StoreBorderLine(SvStream &stream, const 
::editeng::SvxBorderLine &l, sal_uInt16 version)
-        {
-            tools::GenericTypeSerializer aSerializer(stream);
-            aSerializer.writeColor(l.GetColor());
-
-            stream.WriteUInt16( l.GetOutWidth() )
-                .WriteUInt16( l.GetInWidth() )
-                .WriteUInt16( l.GetDistance() );
-
-            if (version >= BORDER_LINE_WITH_STYLE_VERSION)
-                stream.WriteUInt16( 
static_cast<sal_uInt16>(l.GetBorderLineStyle()) );
-
-            return stream;
-        }
-
-        SvStream& Store(const SvxBoxItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            rStrm.WriteUInt16( rItem.GetSmallestDistance() );
-            const ::editeng::SvxBorderLine* pLine[ 4 ];    // top, left, 
right, bottom
-            pLine[ 0 ] = rItem.GetTop();
-            pLine[ 1 ] = rItem.GetLeft();
-            pLine[ 2 ] = rItem.GetRight();
-            pLine[ 3 ] = rItem.GetBottom();
-
-            for( int i = 0; i < 4; i++ )
-            {
-                const ::editeng::SvxBorderLine* l = pLine[ i ];
-                if( l )
-                {
-                    rStrm.WriteSChar(i);
-                    StoreBorderLine(rStrm, *l, 
BorderLineVersionFromBoxVersion(nItemVersion));
-                }
-            }
-            sal_Int8 cLine = 4;
-            const sal_uInt16 nTopDist(rItem.GetDistance(SvxBoxItemLine::TOP));
-            const sal_uInt16 
nLeftDist(rItem.GetDistance(SvxBoxItemLine::LEFT));
-            const sal_uInt16 
nRightDist(rItem.GetDistance(SvxBoxItemLine::RIGHT));
-            const sal_uInt16 
nBottomDist(rItem.GetDistance(SvxBoxItemLine::BOTTOM));
-
-            if( nItemVersion >= BOX_4DISTS_VERSION &&
-                !(nTopDist == nLeftDist &&
-                nTopDist == nRightDist &&
-                nTopDist == nBottomDist) )
-            {
-                cLine |= 0x10;
-            }
-
-            rStrm.WriteSChar( cLine );
-
-            if( nItemVersion >= BOX_4DISTS_VERSION && (cLine & 0x10) != 0 )
-            {
-                rStrm.WriteUInt16( nTopDist )
-                    .WriteUInt16( nLeftDist )
-                    .WriteUInt16( nRightDist )
-                    .WriteUInt16( nBottomDist );
-            }
-
-            return rStrm;
-        }
-    }
-
-    namespace SvxLine
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxLineItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            short        nOutline, nInline, nDistance;
-            Color        aColor;
-
-            tools::GenericTypeSerializer aSerializer(rStrm);
-            aSerializer.readColor(aColor);
-            rStrm.ReadInt16( nOutline ).ReadInt16( nInline ).ReadInt16( 
nDistance );
-            if( nOutline )
-            {
-                ::editeng::SvxBorderLine aLine( &aColor );
-                aLine.GuessLinesWidths(SvxBorderLineStyle::NONE, nOutline, 
nInline, nDistance);
-                rItem.SetLine( &aLine );
-            }
-        }
-
-        SvStream& Store(const SvxLineItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            const ::editeng::SvxBorderLine* pLine(rItem.GetLine());
-
-            if(nullptr != pLine)
-            {
-                tools::GenericTypeSerializer aSerializer(rStrm);
-                aSerializer.writeColor(pLine->GetColor());
-                rStrm.WriteInt16( pLine->GetOutWidth() )
-                    .WriteInt16( pLine->GetInWidth() )
-                    .WriteInt16( pLine->GetDistance() );
-            }
-            else
-            {
-                tools::GenericTypeSerializer aSerializer(rStrm);
-                aSerializer.writeColor(Color());
-                rStrm.WriteInt16( 0 ).WriteInt16( 0 ).WriteInt16( 0 );
-            }
-
-            return rStrm;
-        }
-    }
-
     namespace SvxBrush
     {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return BRUSH_GRAPHIC_VERSION;
-        }
-
         const sal_uInt16 LOAD_GRAPHIC = (sal_uInt16(0x0001));
         const sal_uInt16 LOAD_LINK = (sal_uInt16(0x0002));
         const sal_uInt16 LOAD_FILTER = (sal_uInt16(0x0004));
@@ -631,197 +201,6 @@ namespace legacy
         }
     }
 
-    namespace SvxAdjust
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            return (nFileFormatVersion == SOFFICE_FILEFORMAT_31)
-                    ? 0 : ADJUST_LASTBLOCK_VERSION;
-        }
-
-        void Create(SvxAdjustItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            char eAdjustment;
-            rStrm.ReadChar(eAdjustment);
-            rItem.SetAdjust(static_cast<::SvxAdjust>(eAdjustment));
-
-            if( nItemVersion >= ADJUST_LASTBLOCK_VERSION )
-            {
-                sal_Int8 nFlags;
-                rStrm.ReadSChar( nFlags );
-                rItem.SetAsFlags(nFlags);
-            }
-        }
-
-        SvStream& Store(const SvxAdjustItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion)
-        {
-            rStrm.WriteChar( static_cast<char>(rItem.GetAdjust()) );
-            if ( nItemVersion >= ADJUST_LASTBLOCK_VERSION )
-            {
-                const sal_Int8 nFlags(rItem.GetAsFlags());
-                rStrm.WriteSChar( nFlags );
-            }
-            return rStrm;
-        }
-    }
-
-    namespace SvxHorJustify
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxHorJustifyItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt16 nVal(0);
-            rStrm.ReadUInt16( nVal );
-            rItem.SetValue(static_cast<::SvxCellHorJustify>(nVal));
-        }
-
-        SvStream& Store(const SvxHorJustifyItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUInt16( static_cast<sal_uInt16>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-
-    namespace SvxVerJustify
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxVerJustifyItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt16 nVal(0);
-            rStrm.ReadUInt16( nVal );
-            rItem.SetValue(static_cast<::SvxCellVerJustify>(nVal));
-        }
-
-        SvStream& Store(const SvxVerJustifyItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUInt16( static_cast<sal_uInt16>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-
-    namespace SvxFrameDirection
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            return SOFFICE_FILEFORMAT_50 > nFileFormatVersion ? USHRT_MAX : 0;
-        }
-
-        void Create(SvxFrameDirectionItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt16 nVal(0);
-            rStrm.ReadUInt16( nVal );
-            rItem.SetValue(static_cast<::SvxFrameDirection>(nVal));
-        }
-
-        SvStream& Store(const SvxFrameDirectionItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUInt16( static_cast<sal_uInt16>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-
-    namespace SvxFormatBreak
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion)
-        {
-            DBG_ASSERT( SOFFICE_FILEFORMAT_31==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_40==nFileFormatVersion ||
-                    SOFFICE_FILEFORMAT_50==nFileFormatVersion,
-                    "SvxFormatBreakItem: Is there a new file format? ");
-            return SOFFICE_FILEFORMAT_31==nFileFormatVersion ||
-                SOFFICE_FILEFORMAT_40==nFileFormatVersion ? 0 : 
FMTBREAK_NOAUTO;
-        }
-
-        void Create(SvxFormatBreakItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion)
-        {
-            sal_Int8 eBreak, bDummy;
-            rStrm.ReadSChar( eBreak );
-            if( FMTBREAK_NOAUTO > nItemVersion )
-                rStrm.ReadSChar( bDummy );
-            rItem.SetValue(static_cast<::SvxBreak>(eBreak));
-        }
-
-        SvStream& Store(const SvxFormatBreakItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion)
-        {
-            rStrm.WriteSChar( rItem.GetEnumValue() );
-            if( FMTBREAK_NOAUTO > nItemVersion )
-                rStrm.WriteSChar( 0x01 );
-            return rStrm;
-        }
-    }
-
-    namespace SvxFormatKeep
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxFormatKeepItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            // derived from SfxBoolItem, but that uses
-            //    rStream.ReadCharAsBool( tmp );
-            sal_Int8 bIsKeep;
-            rStrm.ReadSChar( bIsKeep );
-            rItem.SetValue(static_cast<bool>(bIsKeep));
-        }
-
-        SvStream& Store(const SvxFormatKeepItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            // derived from SfxBoolItem, but that uses
-            //    rStream.WriteBool( m_bValue ); // not bool for serialization!
-            rStrm.WriteSChar( static_cast<sal_Int8>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-
-    namespace SvxShadow
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxShadowItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_Int8 cLoc;
-            sal_uInt16 _nWidth;
-            bool bTrans;
-            Color aColor;
-            Color aFillColor;
-            sal_Int8 nStyle;
-            rStrm.ReadSChar( cLoc ).ReadUInt16( _nWidth ).ReadCharAsBool( 
bTrans );
-            tools::GenericTypeSerializer aSerializer(rStrm);
-            aSerializer.readColor(aColor);
-            aSerializer.readColor(aFillColor);
-            rStrm.ReadSChar(nStyle);
-            aColor.SetAlpha(bTrans ? 0 : 255);
-
-            rItem.SetLocation(static_cast<SvxShadowLocation>(cLoc));
-            rItem.SetWidth(_nWidth);
-            rItem.SetColor(aColor);
-        }
-
-        SvStream& Store(const SvxShadowItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteSChar( static_cast<sal_uInt8>(rItem.GetLocation()) )
-                .WriteUInt16( rItem.GetWidth() )
-                .WriteBool( rItem.GetColor().IsTransparent() );
-            tools::GenericTypeSerializer aSerializer(rStrm);
-            aSerializer.writeColor(rItem.GetColor());
-            aSerializer.writeColor(rItem.GetColor());
-            rStrm.WriteSChar( rItem.GetColor().IsTransparent() ? 0 : 1 ); 
//BRUSH_NULL : BRUSH_SOLID
-            return rStrm;
-        }
-    }
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/editeng/adjustitem.hxx b/include/editeng/adjustitem.hxx
index 0a57417bc073..9a82e4334214 100644
--- a/include/editeng/adjustitem.hxx
+++ b/include/editeng/adjustitem.hxx
@@ -146,26 +146,6 @@ public:
         return eRet;
     }
 
-    sal_Int8 GetAsFlags() const
-    {
-        sal_Int8 nFlags = 0;
-        if ( bOneBlock )
-            nFlags |= 0x0001;
-        if ( bLastCenter )
-            nFlags |= 0x0002;
-        if ( bLastBlock )
-            nFlags |= 0x0004;
-        return nFlags;
-    }
-
-    void SetAsFlags(sal_Int8 nFlags)
-    {
-        ASSERT_CHANGE_REFCOUNTED_ITEM;
-        bOneBlock = 0 != (nFlags & 0x0001);
-        bLastCenter = 0 != (nFlags & 0x0002);
-        bLastBlock = 0 != (nFlags & 0x0004);
-    }
-
     sal_uInt16 GetPropWordSpacing() const
     {
         return nPropWordSpacing;
diff --git a/include/editeng/fhgtitem.hxx b/include/editeng/fhgtitem.hxx
index 530d310d1e40..b696a3b52919 100644
--- a/include/editeng/fhgtitem.hxx
+++ b/include/editeng/fhgtitem.hxx
@@ -41,9 +41,6 @@ class EDITENG_DLLPUBLIC SvxFontHeightItem final : public 
SfxPoolItem
     sal_uInt16  nProp;       // default 100%
     MapUnit ePropUnit;       // Percent, Twip, ...
 
-    friend void Create_legacy_direct_set(SvxFontHeightItem& rItem, sal_uInt32 
nH, sal_uInt16 nP, MapUnit eP);
-    void legacy_direct_set(sal_uInt32 nH, sal_uInt16 nP, MapUnit eP) { nHeight 
= nH; nProp = nP; ePropUnit = eP; }
-
 protected:
     virtual ItemInstanceManager* getItemInstanceManager() const override;
 
diff --git a/include/editeng/legacyitem.hxx b/include/editeng/legacyitem.hxx
index ddeb7c4e64bd..4c7eba50b1f0 100644
--- a/include/editeng/legacyitem.hxx
+++ b/include/editeng/legacyitem.hxx
@@ -64,127 +64,15 @@ class SvxShadowItem;
 
 namespace legacy
 {
-    namespace SvxFont
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxFontItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const SvxFontItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxFontHeight
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxFontHeightItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxFontHeightItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxWeight
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxWeightItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxWeightItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxPosture
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxPostureItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxPostureItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxTextLine // SvxUnderlineItem, SvxOverlineItem -> 
SvxTextLineItem
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxTextLineItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxTextLineItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxCrossedOut
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxCrossedOutItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxCrossedOutItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
     // SvxContourItem -> SfxBoolItem
     // SvxShadowedItem -> SfxBoolItem
 
-    namespace SvxColor
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxColorItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxColorItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxBox
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxBoxItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const SvxBoxItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxLine
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxLineItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const SvxLineItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
     namespace SvxBrush
     {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
         void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxBrushItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
         UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxBrushItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
     }
 
-    namespace SvxAdjust
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxAdjustItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxAdjustItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxHorJustify
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxHorJustifyItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxHorJustifyItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxVerJustify
-    {
-        sal_uInt16 UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) GetVersion(sal_uInt16 
nFileFormatVersion);
-        void UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) Create(SvxVerJustifyItem& 
rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-        UNLESS_MERGELIBS(EDITENG_DLLPUBLIC) SvStream& Store(const 
SvxVerJustifyItem& rItem, SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxFrameDirection
-    {
-        sal_uInt16 EDITENG_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void EDITENG_DLLPUBLIC Create(SvxFrameDirectionItem& rItem, SvStream& 
rStrm, sal_uInt16 nItemVersion);
-        EDITENG_DLLPUBLIC SvStream& Store(const SvxFrameDirectionItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxFormatBreak
-    {
-        sal_uInt16 EDITENG_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void EDITENG_DLLPUBLIC Create(SvxFormatBreakItem& rItem, SvStream& 
rStrm, sal_uInt16 nItemVersion);
-        EDITENG_DLLPUBLIC SvStream& Store(const SvxFormatBreakItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxFormatKeep
-    {
-        sal_uInt16 EDITENG_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void EDITENG_DLLPUBLIC Create(SvxFormatKeepItem& rItem, SvStream& 
rStrm, sal_uInt16 nItemVersion);
-        EDITENG_DLLPUBLIC SvStream& Store(const SvxFormatKeepItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
-
-    namespace SvxShadow
-    {
-        sal_uInt16 EDITENG_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void EDITENG_DLLPUBLIC Create(SvxShadowItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-        EDITENG_DLLPUBLIC SvStream& Store(const SvxShadowItem& rItem, 
SvStream& rStrm, sal_uInt16 nItemVersion);
-    }
 }
 
 #endif // INCLUDED_EDITENG_LEGACYITEM_HXX
diff --git a/include/oox/helper/propertymap.hxx 
b/include/oox/helper/propertymap.hxx
index c862a42bdcb3..5405b2473841 100644
--- a/include/oox/helper/propertymap.hxx
+++ b/include/oox/helper/propertymap.hxx
@@ -56,9 +56,6 @@ public:
     /** Returns the name of the passed property identifier. */
     static const OUString& getPropertyName( sal_Int32 nPropId );
 
-    /** Returns the property identifier of the passed name. */
-    static sal_Int32 getPropertyId( std::u16string_view sPropName );
-
     /** Returns true, if the map contains a property with the passed 
identifier. */
     bool                hasProperty( sal_Int32 nPropId ) const;
 
diff --git a/include/sfx2/ctrlitem.hxx b/include/sfx2/ctrlitem.hxx
index 03e530c782d8..0bf711eb0f38 100644
--- a/include/sfx2/ctrlitem.hxx
+++ b/include/sfx2/ctrlitem.hxx
@@ -79,19 +79,6 @@ public:
     SAL_DLLPRIVATE void BindInternal_Impl( sal_uInt16 nNewId, SfxBindings* );
 };
 
-
-class SFX2_DLLPUBLIC SfxStatusForwarder final : public SfxControllerItem
-{
-    SfxControllerItem*      pMaster;
-
-    virtual void        StateChangedAtToolBoxControl( sal_uInt16 nSID, 
SfxItemState eState,
-                                      const SfxPoolItem* pState ) override;
-
-public:
-                            SfxStatusForwarder( sal_uInt16 nSlotId,
-                                   SfxControllerItem&rMaster );
-};
-
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/svl/legacyitem.hxx b/include/svl/legacyitem.hxx
deleted file mode 100644
index b2035aecaf9b..000000000000
--- a/include/svl/legacyitem.hxx
+++ /dev/null
@@ -1,52 +0,0 @@
-/* -*- 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_SVL_LEGACYITEM_HXX
-#define INCLUDED_SVL_LEGACYITEM_HXX
-
-#include <svl/svldllapi.h>
-
-//////////////////////////////////////////////////////////////////////////////
-// // svl
-//     SfxBoolItem                 aLinebreak;
-//     SfxInt32Item                aRotateAngle; -> CntInt32Item
-//////////////////////////////////////////////////////////////////////////////
-
-class SvStream;
-class SfxBoolItem;
-class CntInt32Item;
-
-namespace legacy
-{
-    namespace SfxBool
-    {
-        sal_uInt16 SVL_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void SVL_DLLPUBLIC Create(SfxBoolItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-        SVL_DLLPUBLIC SvStream& Store(const SfxBoolItem& rItem, SvStream& 
rStrm, sal_uInt16 nItemVersion);
-    }
-    namespace CntInt32
-    {
-        sal_uInt16 SVL_DLLPUBLIC GetVersion(sal_uInt16 nFileFormatVersion);
-        void SVL_DLLPUBLIC Create(CntInt32Item& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-        SVL_DLLPUBLIC SvStream& Store(const CntInt32Item& rItem, SvStream& 
rStrm, sal_uInt16 nItemVersion);
-    }
-}
-
-#endif // INCLUDED_SVL_LEGACYITEM_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/svx/algitem.hxx b/include/svx/algitem.hxx
index 0a825bca030f..842fc37c66cc 100644
--- a/include/svx/algitem.hxx
+++ b/include/svx/algitem.hxx
@@ -49,11 +49,6 @@ public:
 
     static OUString         GetValueText( SvxCellOrientation nVal );
     virtual SvxOrientationItem* Clone( SfxItemPool *pPool = nullptr ) const 
override;
-
-    /** Returns sal_True, if the item represents STACKED state. */
-    bool                    IsStacked() const;
-    /** Returns the rotation this item represents (returns nStdAngle for 
STANDARD and STACKED state). */
-    Degree100               GetRotation( Degree100 nStdAngle ) const;
 };
 
 class SAL_WARN_UNUSED SVX_DLLPUBLIC SvxMarginItem final : public SfxPoolItem
diff --git a/include/svx/autoformathelper.hxx b/include/svx/autoformathelper.hxx
index 2d292b1def11..a36ae88cffc3 100644
--- a/include/svx/autoformathelper.hxx
+++ b/include/svx/autoformathelper.hxx
@@ -45,47 +45,6 @@ class SvxMarginItem;
 class SfxInt32Item;
 class SvxRotateModeItem;
 
-//////////////////////////////////////////////////////////////////////////////
-/// Struct with version numbers of the Items
-
-struct SVX_DLLPUBLIC AutoFormatVersions
-{
-public:
-    // BlockA
-    sal_uInt16 nFontVersion;
-    sal_uInt16 nFontHeightVersion;
-    sal_uInt16 nWeightVersion;
-    sal_uInt16 nPostureVersion;
-    sal_uInt16 nUnderlineVersion;
-    sal_uInt16 nOverlineVersion;
-    sal_uInt16 nCrossedOutVersion;
-    sal_uInt16 nContourVersion;
-    sal_uInt16 nShadowedVersion;
-    sal_uInt16 nColorVersion;
-    sal_uInt16 nBoxVersion;
-    sal_uInt16 nLineVersion;
-    sal_uInt16 nBrushVersion;
-    sal_uInt16 nAdjustVersion;
-
-    // BlockB
-    sal_uInt16 nHorJustifyVersion;
-    sal_uInt16 nVerJustifyVersion;
-    sal_uInt16 nOrientationVersion;
-    sal_uInt16 nMarginVersion;
-    sal_uInt16 nBoolVersion;
-    sal_uInt16 nInt32Version;
-    sal_uInt16 nRotateModeVersion;
-    sal_uInt16 nNumFormatVersion;
-
-    AutoFormatVersions();
-
-    void LoadBlockA( SvStream& rStream, sal_uInt16 nVer );
-    void LoadBlockB( SvStream& rStream, sal_uInt16 nVer );
-
-    static void WriteBlockA(SvStream& rStream, sal_uInt16 fileVersion);
-    static void WriteBlockB(SvStream& rStream, sal_uInt16 fileVersion);
-};
-
 //////////////////////////////////////////////////////////////////////////////
 
 class SVX_DLLPUBLIC AutoFormatBase
@@ -209,11 +168,7 @@ public:
     void SetRotateAngle( const SfxInt32Item& rNew );
     void SetRotateMode( const SvxRotateModeItem& rNew );
 
-    bool LoadBlockA( SvStream& rStream, const AutoFormatVersions& rVersions, 
sal_uInt16 nVer );
-    bool LoadBlockB( SvStream& rStream, const AutoFormatVersions& rVersions, 
sal_uInt16 nVer );
 
-    bool SaveBlockA( SvStream& rStream, sal_uInt16 fileVersion ) const;
-    bool SaveBlockB( SvStream& rStream, sal_uInt16 fileVersion ) const;
 };
 
 #endif // INCLUDED_SVX_AUTOFORMATHELPER_HXX
diff --git a/include/svx/svxdlg.hxx b/include/svx/svxdlg.hxx
index 1755be2a7305..4c1190cb50ba 100644
--- a/include/svx/svxdlg.hxx
+++ b/include/svx/svxdlg.hxx
@@ -201,9 +201,6 @@ class AbstractSvxHpLinkDlg : public VclAbstractDialog
 {
 protected:
     virtual ~AbstractSvxHpLinkDlg() override = default;
-public:
-    virtual std::shared_ptr<SfxDialogController> GetController()  = 0;
-    virtual bool       QueryClose() = 0;
 };
 
 struct FmFoundRecordInformation;
diff --git a/include/vcl/toolbox.hxx b/include/vcl/toolbox.hxx
index 2bf4d98f2011..109caa4b6a82 100644
--- a/include/vcl/toolbox.hxx
+++ b/include/vcl/toolbox.hxx
@@ -444,8 +444,6 @@ public:
 
     // enable/disable undocking
     SAL_DLLPRIVATE void Lock( bool bLock );
-    // read configuration to determine locking behaviour
-    static bool         AlwaysLocked();
 
     void                EnableCustomize( bool bEnable = true );
     bool                IsCustomize() const { return mbCustomize; }
diff --git a/oox/source/helper/propertymap.cxx 
b/oox/source/helper/propertymap.cxx
index 3cc8119d80d7..2a311ddc9826 100644
--- a/oox/source/helper/propertymap.cxx
+++ b/oox/source/helper/propertymap.cxx
@@ -224,22 +224,6 @@ const OUString& PropertyMap::getPropertyName( sal_Int32 
nPropId )
     return GetPropertyNameVector()[ nPropId ];
 }
 
-sal_Int32 PropertyMap::getPropertyId( std::u16string_view sPropName )
-{
-    // This may use a std::map to get faster from String to ID in the
-    // future, inside the [0..PROP_COUNT[ entries. Since it is currently
-    // only used for Diagram re-creation I opted for less memory usage here
-    if(sPropName.empty())
-        return -1;
-
-    const std::vector<OUString>& rVec(GetPropertyNameVector());
-    for(size_t a(0); a < rVec.size(); a++)
-        if(rVec[a] == sPropName)
-            return a;
-
-    return -1;
-}
-
 void PropertyMap::assignAll( const PropertyMap& rPropMap )
 {
     for (auto const& prop : rPropMap.maProperties)
diff --git a/sc/Library_sc.mk b/sc/Library_sc.mk
index c188dfd43212..5ccdc3b9a4d7 100644
--- a/sc/Library_sc.mk
+++ b/sc/Library_sc.mk
@@ -306,7 +306,6 @@ $(eval $(call gb_Library_add_exception_objects,sc,\
     sc/source/core/tool/userlist \
     sc/source/core/tool/viewopti \
     sc/source/core/tool/webservicelink \
-    sc/source/core/tool/zforauto \
     sc/source/filter/xml/datastreamimport \
     sc/source/filter/xml/SparklineGroupsExport \
     sc/source/filter/xml/SparklineGroupsImportContext \
diff --git a/sc/inc/autoform.hxx b/sc/inc/autoform.hxx
index 6db6dc2af3cf..2d3d5df8759c 100644
--- a/sc/inc/autoform.hxx
+++ b/sc/inc/autoform.hxx
@@ -61,9 +61,7 @@ public:
     }
     void PutItem(size_t nIndex, const SfxPoolItem& rItem);
 
-    void CopyItem(size_t nToIndex, size_t nFromIndex, sal_uInt16 nWhich);
     void FillToItemSet(size_t nIndex, SfxItemSet& rItemSet) const;
-    void GetFromItemSet(size_t nIndex, const SfxItemSet& rItemSet);
 };
 
 class SAL_DLLPUBLIC_RTTI ScAutoFormat : public SvxAutoFormat
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 75c8e67ef9c1..c203379f75b6 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -2027,8 +2027,6 @@ public:
 
     void                 AutoFormat( SCCOL nStartCol, SCROW nStartRow, SCCOL 
nEndCol, SCROW nEndRow,
                                      sal_uInt16 nFormatNo, const ScMarkData& 
rMark );
-    void                 GetAutoFormatData( SCTAB nTab, SCCOL nStartCol, SCROW 
nStartRow, SCCOL nEndCol, SCROW nEndRow,
-                                            ScAutoFormatData& rData );
     bool                 SearchAndReplace( const SvxSearchItem& rSearchItem,
                                            SCCOL& rCol, SCROW& rRow, SCTAB& 
rTab,
                                            const ScMarkData& rMark, 
ScRangeList& rMatchedRanges,
diff --git a/sc/inc/global.hxx b/sc/inc/global.hxx
index ee0f8fd7bcae..3033095ac82e 100644
--- a/sc/inc/global.hxx
+++ b/sc/inc/global.hxx
@@ -585,7 +585,6 @@ public:
     static void                 SetClipDocName( const OUString& rNew );
     SC_DLLPUBLIC static const SvxSearchItem&    GetSearchItem();
     SC_DLLPUBLIC static void                    SetSearchItem( const 
SvxSearchItem& rNew );
-    SC_DLLPUBLIC static ScAutoFormat*       GetAutoFormat();
     SC_DLLPUBLIC static ScAutoFormat*       GetOrCreateAutoFormat();
     SC_DLLPUBLIC static void                ResetAutoFormat();
     static void                 ClearAutoFormat(); //BugId 54209
diff --git a/sc/inc/scabstdlg.hxx b/sc/inc/scabstdlg.hxx
index 456b627de6c8..41c68ebaeda2 100644
--- a/sc/inc/scabstdlg.hxx
+++ b/sc/inc/scabstdlg.hxx
@@ -72,8 +72,6 @@ class AbstractScAutoFormatDlg : public VclAbstractDialog
 protected:
     virtual             ~AbstractScAutoFormatDlg() override = default;
 public:
-    virtual sal_uInt16 GetIndex() const = 0 ;
-    virtual OUString GetCurrFormatName() = 0;
 };
 
 class AbstractScColRowLabelDlg : public VclAbstractDialog
diff --git a/sc/inc/table.hxx b/sc/inc/table.hxx
index 5c3586990923..c3b8747c9125 100644
--- a/sc/inc/table.hxx
+++ b/sc/inc/table.hxx
@@ -728,7 +728,6 @@ public:
 
     void        AutoFormat( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, 
SCROW nEndRow,
                                     sal_uInt16 nFormatNo, ScProgress* 
pProgress );
-    void        GetAutoFormatData(SCCOL nStartCol, SCROW nStartRow, SCCOL 
nEndCol, SCROW nEndRow, ScAutoFormatData& rData);
     bool        SearchAndReplace(
         const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow, const 
ScMarkData& rMark,
         ScRangeList& rMatchedRanges, OUString& rUndoStr, ScDocument* pUndoDoc, 
bool& bMatchedRangesWereClamped);
@@ -1255,8 +1254,6 @@ private:
 
     void        AutoFormatArea(SCCOL nStartCol, SCROW nStartRow, SCCOL 
nEndCol, SCROW nEndRow,
                                 const ScPatternAttr& rAttr, sal_uInt16 
nFormatNo);
-    void        GetAutoFormatAttr(SCCOL nCol, SCROW nRow, sal_uInt16 nIndex, 
ScAutoFormatData& rData);
-    void        GetAutoFormatFrame(SCCOL nCol, SCROW nRow, sal_uInt16 nFlags, 
sal_uInt16 nIndex, ScAutoFormatData& rData);
     bool        SearchCell(const SvxSearchItem& rSearchItem, SCCOL nCol, 
sc::ColumnBlockConstPosition& rBlockPos, SCROW nRow,
                            const ScMarkData& rMark, OUString& rUndoStr, 
ScDocument* pUndoDoc);
     bool        Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& 
rRow,
diff --git a/sc/inc/zforauto.hxx b/sc/inc/zforauto.hxx
deleted file mode 100644
index d5f0ee956cfd..000000000000
--- a/sc/inc/zforauto.hxx
+++ /dev/null
@@ -1,49 +0,0 @@
-/* -*- 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 .
- */
-
-#pragma once
-
-#include <rtl/ustring.hxx>
-#include <i18nlangtag/lang.h>
-
-class SvStream;
-class SvNumberFormatter;
-
-class ScNumFormatAbbrev
-{
-    OUString sFormatstring;
-    LanguageType eLanguage;
-    LanguageType eSysLanguage;
-
-public:
-    ScNumFormatAbbrev();
-    ScNumFormatAbbrev(sal_uInt32 nFormat, const SvNumberFormatter& rFormatter);
-    void Load(SvStream& rStream, rtl_TextEncoding eByteStrSet); // loading of 
the numberformats
-    void Save(SvStream& rStream, rtl_TextEncoding eByteStrSet) const; // 
saving of the numberformats
-    void PutFormatIndex(sal_uInt32 nFormat, const SvNumberFormatter& 
rFormatter);
-    sal_uInt32 GetFormatIndex(SvNumberFormatter& rFormatter);
-    bool operator==(const ScNumFormatAbbrev& rNumFormat) const
-    {
-        return ((sFormatstring == rNumFormat.sFormatstring) && (eLanguage == 
rNumFormat.eLanguage)
-                && (eSysLanguage == rNumFormat.eSysLanguage));
-    }
-    LanguageType GetLanguage() const { return eLanguage; }
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx
index e1c637e18c56..16a2d32fbdde 100644
--- a/sc/source/core/data/documen3.cxx
+++ b/sc/source/core/data/documen3.cxx
@@ -1242,17 +1242,6 @@ void ScDocument::AutoFormat( SCCOL nStartCol, SCROW 
nStartRow, SCCOL nEndCol, SC
     }
 }
 
-void ScDocument::GetAutoFormatData(SCTAB nTab, SCCOL nStartCol, SCROW 
nStartRow, SCCOL nEndCol, SCROW nEndRow,
-                                    ScAutoFormatData& rData)
-{
-    if (ScTable* pTable = FetchTable(nTab))
-    {
-        PutInOrder(nStartCol, nEndCol);
-        PutInOrder(nStartRow, nEndRow);
-        pTable->GetAutoFormatData(nStartCol, nStartRow, nEndCol, nEndRow, 
rData);
-    }
-}
-
 void ScDocument::GetSearchAndReplaceStart( const SvxSearchItem& rSearchItem,
         SCCOL& rCol, SCROW& rRow )
 {
diff --git a/sc/source/core/data/global.cxx b/sc/source/core/data/global.cxx
index 8e150994fbbe..cf245280a836 100644
--- a/sc/source/core/data/global.cxx
+++ b/sc/source/core/data/global.cxx
@@ -256,11 +256,6 @@ void ScGlobal::ClearAutoFormat()
     }
 }
 
-ScAutoFormat* ScGlobal::GetAutoFormat()
-{
-    return xAutoFormat.get();
-}
-
 ScAutoFormat* ScGlobal::GetOrCreateAutoFormat()
 {
     assert(!bThreadedGroupCalcInProgress);
diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx
index f102150090f5..ab5447041014 100644
--- a/sc/source/core/data/table4.cxx
+++ b/sc/source/core/data/table4.cxx
@@ -42,7 +42,6 @@
 #include <document.hxx>
 #include <autoform.hxx>
 #include <userlist.hxx>
-#include <zforauto.hxx>
 #include <subtotal.hxx>
 #include <formula/errorcodes.hxx>
 #include <docpool.hxx>
@@ -2796,151 +2795,6 @@ void ScTable::AutoFormat( SCCOL nStartCol, SCROW 
nStartRow, SCCOL nEndCol, SCROW
     }
 }
 
-void ScTable::GetAutoFormatAttr(SCCOL nCol, SCROW nRow, sal_uInt16 nIndex, 
ScAutoFormatData& rData)
-{
-    sal_uInt32 nFormatIndex = GetNumberFormat( nCol, nRow );
-    ScNumFormatAbbrev   aNumFormat( nFormatIndex, *rDocument.GetFormatTable() 
);
-    rData.GetFromItemSet( nIndex, GetPattern( nCol, nRow )->GetItemSet());
-}
-
-#define LF_LEFT         1
-#define LF_TOP          2
-#define LF_RIGHT        4
-#define LF_BOTTOM       8
-#define LF_ALL          (LF_LEFT | LF_TOP | LF_RIGHT | LF_BOTTOM)
-
-void ScTable::GetAutoFormatFrame(SCCOL nCol, SCROW nRow, sal_uInt16 nFlags, 
sal_uInt16 nIndex, ScAutoFormatData& rData)
-{
-    const SvxBoxItem* pTheBox = GetAttr(nCol, nRow, ATTR_BORDER);
-    const SvxBoxItem* pLeftBox = GetAttr(nCol - 1, nRow, ATTR_BORDER);
-    const SvxBoxItem* pTopBox = GetAttr(nCol, nRow - 1, ATTR_BORDER);
-    const SvxBoxItem* pRightBox = GetAttr(nCol + 1, nRow, ATTR_BORDER);
-    const SvxBoxItem* pBottomBox = GetAttr(nCol, nRow + 1, ATTR_BORDER);
-
-    SvxBoxItem aBox( ATTR_BORDER );
-    if (nFlags & LF_LEFT)
-    {
-        if (pLeftBox)
-        {
-            if (ScHasPriority(pTheBox->GetLeft(), pLeftBox->GetRight()))
-                aBox.SetLine(pTheBox->GetLeft(), SvxBoxItemLine::LEFT);
-            else
-                aBox.SetLine(pLeftBox->GetRight(), SvxBoxItemLine::LEFT);
-        }
-        else
-            aBox.SetLine(pTheBox->GetLeft(), SvxBoxItemLine::LEFT);
-    }
-    if (nFlags & LF_TOP)
-    {
-        if (pTopBox)
-        {
-            if (ScHasPriority(pTheBox->GetTop(), pTopBox->GetBottom()))
-                aBox.SetLine(pTheBox->GetTop(), SvxBoxItemLine::TOP);
-            else
-                aBox.SetLine(pTopBox->GetBottom(), SvxBoxItemLine::TOP);
-        }
-        else
-            aBox.SetLine(pTheBox->GetTop(), SvxBoxItemLine::TOP);
-    }
-    if (nFlags & LF_RIGHT)
-    {
-        if (pRightBox)
-        {
-            if (ScHasPriority(pTheBox->GetRight(), pRightBox->GetLeft()))
-                aBox.SetLine(pTheBox->GetRight(), SvxBoxItemLine::RIGHT);
-            else
-                aBox.SetLine(pRightBox->GetLeft(), SvxBoxItemLine::RIGHT);
-        }
-        else
-            aBox.SetLine(pTheBox->GetRight(), SvxBoxItemLine::RIGHT);
-    }
-    if (nFlags & LF_BOTTOM)
-    {
-        if (pBottomBox)
-        {
-            if (ScHasPriority(pTheBox->GetBottom(), pBottomBox->GetTop()))
-                aBox.SetLine(pTheBox->GetBottom(), SvxBoxItemLine::BOTTOM);
-            else
-                aBox.SetLine(pBottomBox->GetTop(), SvxBoxItemLine::BOTTOM);
-        }
-        else
-            aBox.SetLine(pTheBox->GetBottom(), SvxBoxItemLine::BOTTOM);
-    }
-    rData.PutItem( nIndex, aBox );
-}
-
-void ScTable::GetAutoFormatData(SCCOL nStartCol, SCROW nStartRow, SCCOL 
nEndCol, SCROW nEndRow, ScAutoFormatData& rData)
-{
-    if (!(ValidColRow(nStartCol, nStartRow) && ValidColRow(nEndCol, nEndRow)))
-        return;
-
-    if ((nEndCol - nStartCol < 3) || (nEndRow - nStartRow < 3))
-        return;
-
-    // Left top corner
-    GetAutoFormatAttr(nStartCol, nStartRow, 0, rData);
-    GetAutoFormatFrame(nStartCol, nStartRow, LF_ALL, 0, rData);
-    // Left column
-    GetAutoFormatAttr(nStartCol, nStartRow + 1, 4, rData);
-    GetAutoFormatAttr(nStartCol, nStartRow + 2, 8, rData);
-    GetAutoFormatFrame(nStartCol, nStartRow + 1, LF_LEFT | LF_RIGHT | 
LF_BOTTOM, 4, rData);
-    if (nEndRow - nStartRow >= 4)
-        GetAutoFormatFrame(nStartCol, nStartRow + 2, LF_LEFT | LF_RIGHT | 
LF_BOTTOM, 8, rData);
-    else
-        rData.CopyItem( 8, 4, ATTR_BORDER );
-    // Left bottom corner
-    GetAutoFormatAttr(nStartCol, nEndRow, 12, rData);
-    GetAutoFormatFrame(nStartCol, nEndRow, LF_ALL, 12, rData);
-    // Right top corner
-    GetAutoFormatAttr(nEndCol, nStartRow, 3, rData);
-    GetAutoFormatFrame(nEndCol, nStartRow, LF_ALL, 3, rData);
-    // Right column
-    GetAutoFormatAttr(nEndCol, nStartRow + 1, 7, rData);
-    GetAutoFormatAttr(nEndCol, nStartRow + 2, 11, rData);
-    GetAutoFormatFrame(nEndCol, nStartRow + 1, LF_LEFT | LF_RIGHT | LF_BOTTOM, 
7, rData);
-    if (nEndRow - nStartRow >= 4)
-        GetAutoFormatFrame(nEndCol, nStartRow + 2, LF_LEFT | LF_RIGHT | 
LF_BOTTOM, 11, rData);
-    else
-        rData.CopyItem( 11, 7, ATTR_BORDER );
-    // Right bottom corner
-    GetAutoFormatAttr(nEndCol, nEndRow, 15, rData);
-    GetAutoFormatFrame(nEndCol, nEndRow, LF_ALL, 15, rData);
-    // Top row
-    GetAutoFormatAttr(nStartCol + 1, nStartRow, 1, rData);
-    GetAutoFormatAttr(nStartCol + 2, nStartRow, 2, rData);
-    GetAutoFormatFrame(nStartCol + 1, nStartRow, LF_TOP | LF_BOTTOM | 
LF_RIGHT, 1, rData);
-    if (nEndCol - nStartCol >= 4)
-        GetAutoFormatFrame(nStartCol + 2, nStartRow, LF_TOP | LF_BOTTOM | 
LF_RIGHT, 2, rData);
-    else
-        rData.CopyItem( 2, 1, ATTR_BORDER );
-    // Bottom row
-    GetAutoFormatAttr(nStartCol + 1, nEndRow, 13, rData);
-    GetAutoFormatAttr(nStartCol + 2, nEndRow, 14, rData);
-    GetAutoFormatFrame(nStartCol + 1, nEndRow, LF_TOP | LF_BOTTOM | LF_RIGHT, 
13, rData);
-    if (nEndCol - nStartCol >= 4)
-        GetAutoFormatFrame(nStartCol + 2, nEndRow, LF_TOP | LF_BOTTOM | 
LF_RIGHT, 14, rData);
-    else
-        rData.CopyItem( 14, 13, ATTR_BORDER );
-    // Body
-    GetAutoFormatAttr(nStartCol + 1, nStartRow + 1, 5, rData);
-    GetAutoFormatAttr(nStartCol + 2, nStartRow + 1, 6, rData);
-    GetAutoFormatAttr(nStartCol + 1, nStartRow + 2, 9, rData);
-    GetAutoFormatAttr(nStartCol + 2, nStartRow + 2, 10, rData);
-    GetAutoFormatFrame(nStartCol + 1, nStartRow + 1, LF_RIGHT | LF_BOTTOM, 5, 
rData);
-    if ((nEndCol - nStartCol >= 4) && (nEndRow - nStartRow >= 4))
-    {
-        GetAutoFormatFrame(nStartCol + 2, nStartRow + 1, LF_RIGHT | LF_BOTTOM, 
6, rData);
-        GetAutoFormatFrame(nStartCol + 1, nStartRow + 2, LF_RIGHT | LF_BOTTOM, 
9, rData);
-        GetAutoFormatFrame(nStartCol + 2, nStartRow + 2, LF_RIGHT | LF_BOTTOM, 
10, rData);
-    }
-    else
-    {
-        rData.CopyItem( 6, 5, ATTR_BORDER );
-        rData.CopyItem( 9, 5, ATTR_BORDER );
-        rData.CopyItem( 10, 5, ATTR_BORDER );
-    }
-}
-
 void ScTable::SetError( SCCOL nCol, SCROW nRow, FormulaError nError)
 {
     if (ValidColRow(nCol, nRow))
diff --git a/sc/source/core/tool/autoform.cxx b/sc/source/core/tool/autoform.cxx
index 41ba083324db..f1e18ed13213 100644
--- a/sc/source/core/tool/autoform.cxx
+++ b/sc/source/core/tool/autoform.cxx
@@ -309,13 +309,6 @@ void ScAutoFormatData::PutItem(size_t nIndex, const 
SfxPoolItem& rItem)
     }
 }
 
-void ScAutoFormatData::CopyItem( size_t nToIndex, size_t nFromIndex, 
sal_uInt16 nWhich )
-{
-    const SfxPoolItem* pItem = GetItem( nFromIndex, nWhich );
-    if( pItem )
-        PutItem( nToIndex, *pItem );
-}
-
 void ScAutoFormatData::FillToItemSet(size_t nIndex, SfxItemSet& rItemSet) const
 {
     SvxAutoFormatData::FillToItemSet(nIndex, rItemSet);
@@ -344,40 +337,6 @@ void ScAutoFormatData::FillToItemSet(size_t nIndex, 
SfxItemSet& rItemSet) const
     }
 }
 
-void ScAutoFormatData::GetFromItemSet(size_t nIndex, const SfxItemSet& 
rItemSet)
-{
-    ScAutoFormatDataField& rField = *GetField(nIndex);
-
-    rField.SetFont(rItemSet.Get(ATTR_FONT));
-    rField.SetHeight(rItemSet.Get(ATTR_FONT_HEIGHT));
-    rField.SetWeight(rItemSet.Get(ATTR_FONT_WEIGHT));
-    rField.SetPosture(rItemSet.Get(ATTR_FONT_POSTURE));
-    rField.SetCJKFont(rItemSet.Get(ATTR_CJK_FONT));
-    rField.SetCJKHeight(rItemSet.Get(ATTR_CJK_FONT_HEIGHT));
-    rField.SetCJKWeight(rItemSet.Get(ATTR_CJK_FONT_WEIGHT));
-    rField.SetCJKPosture(rItemSet.Get(ATTR_CJK_FONT_POSTURE));
-    rField.SetCTLFont(rItemSet.Get(ATTR_CTL_FONT));
-    rField.SetCTLHeight(rItemSet.Get(ATTR_CTL_FONT_HEIGHT));
-    rField.SetCTLWeight(rItemSet.Get(ATTR_CTL_FONT_WEIGHT));
-    rField.SetCTLPosture(rItemSet.Get(ATTR_CTL_FONT_POSTURE));
-    rField.SetUnderline(rItemSet.Get(ATTR_FONT_UNDERLINE));
-    rField.SetOverline(rItemSet.Get(ATTR_FONT_OVERLINE));
-    rField.SetCrossedOut(rItemSet.Get(ATTR_FONT_CROSSEDOUT));
-    rField.SetContour(rItemSet.Get(ATTR_FONT_CONTOUR));
-    rField.SetShadowed(rItemSet.Get(ATTR_FONT_SHADOWED));
-    rField.SetColor(rItemSet.Get(ATTR_FONT_COLOR));
-    rField.SetTLBR(rItemSet.Get(ATTR_BORDER_TLBR));
-    rField.SetBLTR(rItemSet.Get(ATTR_BORDER_BLTR));
-    rField.SetHorJustify(rItemSet.Get(ATTR_HOR_JUSTIFY));
-    rField.SetVerJustify(rItemSet.Get(ATTR_VER_JUSTIFY));
-    rField.SetStacked(rItemSet.Get(ATTR_STACKED));
-    rField.SetLinebreak(rItemSet.Get(ATTR_LINEBREAK));
-    rField.SetMargin(rItemSet.Get(ATTR_MARGIN));
-    rField.SetBackground(rItemSet.Get(ATTR_BACKGROUND));
-    rField.SetRotateAngle(rItemSet.Get(ATTR_ROTATE_VALUE));
-    rField.SetRotateMode(rItemSet.Get(ATTR_ROTATE_MODE));
-}
-
 struct ScAutoFormat::Impl
 {
     std::vector<std::unique_ptr<ScAutoFormatData>> maAutoFormats;
diff --git a/sc/source/core/tool/zforauto.cxx b/sc/source/core/tool/zforauto.cxx
deleted file mode 100644
index a35b015b2333..000000000000
--- a/sc/source/core/tool/zforauto.cxx
+++ /dev/null
@@ -1,88 +0,0 @@
-/* -*- 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 <svl/numformat.hxx>
-#include <svl/zforlist.hxx>
-#include <svl/zformat.hxx>
-#include <vcl/svapp.hxx>
-#include <vcl/settings.hxx>
-#include <osl/diagnose.h>
-
-#include <zforauto.hxx>
-#include <tools/stream.hxx>
-
-ScNumFormatAbbrev::ScNumFormatAbbrev() :
-    sFormatstring   ( u"Standard"_ustr ),
-    eLanguage       (LANGUAGE_SYSTEM),
-    eSysLanguage    (LANGUAGE_GERMAN)       // otherwise "Standard" does not 
fit
-{
-}
-
-ScNumFormatAbbrev::ScNumFormatAbbrev(sal_uInt32 nFormat,
-                                     const SvNumberFormatter& rFormatter)
-{
-    PutFormatIndex(nFormat, rFormatter);
-}
-
-void ScNumFormatAbbrev::Load( SvStream& rStream, rtl_TextEncoding eByteStrSet )
-{
-    sal_uInt16 nSysLang, nLang;
-    sFormatstring = rStream.ReadUniOrByteString( eByteStrSet );
-    rStream.ReadUInt16( nSysLang ).ReadUInt16( nLang );
-    eLanguage = LanguageType(nLang);
-    eSysLanguage = LanguageType(nSysLang);
-    if ( eSysLanguage == LANGUAGE_SYSTEM )          // old versions did write 
it
-        eSysLanguage = 
Application::GetSettings().GetLanguageTag().getLanguageType();
-}
-
-void ScNumFormatAbbrev::Save( SvStream& rStream, rtl_TextEncoding eByteStrSet 
) const
-{
-    rStream.WriteUniOrByteString( sFormatstring, eByteStrSet );
-    rStream.WriteUInt16( static_cast<sal_uInt16>(eSysLanguage) ).WriteUInt16( 
static_cast<sal_uInt16>(eLanguage) );
-}
-
-void ScNumFormatAbbrev::PutFormatIndex(sal_uInt32 nFormat,
-                                       const SvNumberFormatter& rFormatter)
-{
-    const SvNumberformat* pFormat = rFormatter.GetEntry(nFormat);
-    if (pFormat)
-    {
-        eSysLanguage = 
Application::GetSettings().GetLanguageTag().getLanguageType();
-        eLanguage = pFormat->GetLanguage();
-        sFormatstring = pFormat->GetFormatstring();
-    }
-    else
-    {
-        OSL_FAIL("SCNumFormatAbbrev:: unknown number format");
-        eLanguage = LANGUAGE_SYSTEM;
-        eSysLanguage = LANGUAGE_GERMAN;     // otherwise "Standard" does not 
fit
-        sFormatstring = "Standard";
-    }
-}
-
-sal_uInt32 ScNumFormatAbbrev::GetFormatIndex( SvNumberFormatter& rFormatter)
-{
-    SvNumFormatType nType;
-    bool bNewInserted;
-    sal_Int32 nCheckPos;
-    return rFormatter.GetIndexPuttingAndConverting( sFormatstring, eLanguage,
-                                                    eSysLanguage, nType, 
bNewInserted, nCheckPos);
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/inc/viewfunc.hxx b/sc/source/ui/inc/viewfunc.hxx
index 85fb6af0e3d3..075653246171 100644
--- a/sc/source/ui/inc/viewfunc.hxx
+++ b/sc/source/ui/inc/viewfunc.hxx
@@ -268,7 +268,6 @@ public:
 
     void            TransliterateText( TransliterationFlags nType );
 
-    ScAutoFormatData* CreateAutoFormatData();
     void            AutoFormat( sal_uInt16 nFormatNo );
 
     bool            SearchAndReplace( const SvxSearchItem* pSearchItem,
diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 83e83cbc3624..b3df48f276eb 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -1916,27 +1916,6 @@ void ScViewFunc::TransliterateText( TransliterationFlags 
nType )
 
 //  AutoFormat
 
-ScAutoFormatData* ScViewFunc::CreateAutoFormatData()
-{
-    ScAutoFormatData* pData = nullptr;
-    SCCOL nStartCol;
-    SCROW nStartRow;
-    SCTAB nStartTab;
-    SCCOL nEndCol;
-    SCROW nEndRow;
-    SCTAB nEndTab;
-    if 
(GetViewData().GetSimpleArea(nStartCol,nStartRow,nStartTab,nEndCol,nEndRow,nEndTab)
 == SC_MARK_SIMPLE)
-    {
-        if ( nEndCol-nStartCol >= 3 && nEndRow-nStartRow >= 3 )
-        {
-            ScDocument& rDoc = GetViewData().GetDocument();
-            pData = new ScAutoFormatData;
-            rDoc.GetAutoFormatData( nStartTab, 
nStartCol,nStartRow,nEndCol,nEndRow, *pData );
-        }
-    }
-    return pData;
-}
-
 void ScViewFunc::AutoFormat( sal_uInt16 nFormatNo )
 {
     ScRange aRange;
diff --git a/sfx2/source/control/ctrlitem.cxx b/sfx2/source/control/ctrlitem.cxx
index 678bb1da884e..d9fbc2500e79 100644
--- a/sfx2/source/control/ctrlitem.cxx
+++ b/sfx2/source/control/ctrlitem.cxx
@@ -235,27 +235,6 @@ void SfxControllerItem::GetControlState
 {
 }
 
-void SfxStatusForwarder::StateChangedAtToolBoxControl
-(
-    sal_uInt16          nSID,    // <SID> of the triggering slot
-    SfxItemState        eState,  // <SfxItemState> of 'pState'
-    const SfxPoolItem*  pState   // Slot-Status, NULL or IsInvalidItem()
-)
-
-{
-    pMaster->StateChangedAtToolBoxControl( nSID, eState, pState );
-}
-
-
-SfxStatusForwarder::SfxStatusForwarder(
-            sal_uInt16              nSlotId,
-            SfxControllerItem&  rMaster ):
-    SfxControllerItem( nSlotId, rMaster.GetBindings() ),
-    pMaster( &rMaster )
-{
-}
-
-
 SfxItemState SfxControllerItem::GetItemState
 (
     const SfxPoolItem* pState   /*  Pointer to  <SfxPoolItem>, which
diff --git a/svl/Library_svl.mk b/svl/Library_svl.mk
index fd48601e5182..ee8088c51e7d 100644
--- a/svl/Library_svl.mk
+++ b/svl/Library_svl.mk
@@ -130,7 +130,6 @@ $(eval $(call gb_Library_add_exception_objects,svl,\
     svl/source/items/IndexedStyleSheets \
     svl/source/items/itemset \
     svl/source/items/lckbitem \
-    svl/source/items/legacyitem \
     svl/source/items/macitem \
     svl/source/items/poolitem \
     svl/source/items/ptitem \
diff --git a/svl/source/items/legacyitem.cxx b/svl/source/items/legacyitem.cxx
deleted file mode 100644
index b0daa3b9066e..000000000000
--- a/svl/source/items/legacyitem.cxx
+++ /dev/null
@@ -1,69 +0,0 @@
-/* -*- 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 <svl/legacyitem.hxx>
-#include <tools/stream.hxx>
-#include <svl/eitem.hxx>
-#include <svl/cintitem.hxx>
-
-namespace legacy
-{
-    namespace SfxBool
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SfxBoolItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            bool tmp(false);
-            rStrm.ReadCharAsBool(tmp);
-            rItem.SetValue(tmp);
-        }
-
-        SvStream& Store(const SfxBoolItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            rStrm.WriteBool(rItem.GetValue()); // not bool for serialization!
-            return rStrm;
-        }
-    }
-    namespace CntInt32
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(CntInt32Item& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_Int32 tmp(0);
-            rStrm.ReadInt32(tmp);
-            rItem.SetValue(tmp);
-        }
-
-        SvStream& Store(const CntInt32Item& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            rStrm.WriteInt32(rItem.GetValue());
-            return rStrm;
-        }
-    }
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/Library_svx.mk b/svx/Library_svx.mk
index bc810480b69f..e7e72400ad84 100644
--- a/svx/Library_svx.mk
+++ b/svx/Library_svx.mk
@@ -202,7 +202,6 @@ $(eval $(call gb_Library_add_exception_objects,svx,\
        svx/source/items/ehdl \
     svx/source/items/hlnkitem \
     svx/source/items/numfmtsh \
-    svx/source/items/legacyitem \
     svx/source/items/numinf \
     svx/source/items/ofaitem \
     svx/source/items/pageitem \
diff --git a/svx/inc/legacyitem.hxx b/svx/inc/legacyitem.hxx
deleted file mode 100644
index b8d1362b4464..000000000000
--- a/svx/inc/legacyitem.hxx
+++ /dev/null
@@ -1,60 +0,0 @@
-/* -*- 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_SVX_LEGACYITEM_HXX
-#define INCLUDED_SVX_LEGACYITEM_HXX
-
-#include <sal/types.h>
-
-//////////////////////////////////////////////////////////////////////////////
-// // svx
-//     SvxOrientationItem aOrientation( aRotateAngle.GetValue(), 
aStacked.GetValue(), 0 );
-//     SvxMarginItem               aMargin;
-//     SvxRotateModeItem           aRotateMode;
-//////////////////////////////////////////////////////////////////////////////
-
-class SvStream;
-class SvxOrientationItem;
-class SvxMarginItem;
-class SvxRotateModeItem;
-
-namespace legacy
-{
-    namespace SvxOrientation
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion);
-        void Create(SvxOrientationItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion);
-        SvStream& Store(const SvxOrientationItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-    }
-    namespace SvxMargin
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion);
-        void Create(SvxMarginItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion);
-        SvStream& Store(const SvxMarginItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-    }
-    namespace SvxRotateMode
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion);
-        void Create(SvxRotateModeItem& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion);
-        SvStream& Store(const SvxRotateModeItem& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-    }
-}
-
-#endif // INCLUDED_SVX_LEGACYITEM_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/items/algitem.cxx b/svx/source/items/algitem.cxx
index ad153199ff0c..6e9985cffd58 100644
--- a/svx/source/items/algitem.cxx
+++ b/svx/source/items/algitem.cxx
@@ -120,23 +120,6 @@ SvxOrientationItem* SvxOrientationItem::Clone( 
SfxItemPool* ) const
     return new SvxOrientationItem( *this );
 }
 
-bool SvxOrientationItem::IsStacked() const
-{
-    return GetValue() == SvxCellOrientation::Stacked;
-}
-
-Degree100 SvxOrientationItem::GetRotation( Degree100 nStdAngle ) const
-{
-    Degree100 nAngle = nStdAngle;
-    switch( GetValue() )
-    {
-        case SvxCellOrientation::BottomUp: nAngle = 9000_deg100; break;
-        case SvxCellOrientation::TopBottom: nAngle = 27000_deg100; break;
-        default: ; //prevent warning
-    }
-    return nAngle;
-}
-
 SvxMarginItem::SvxMarginItem( const TypedWhichId<SvxMarginItem> nId ) :
 
     SfxPoolItem( nId ),
diff --git a/svx/source/items/autoformathelper.cxx 
b/svx/source/items/autoformathelper.cxx
index cb09ea735e81..fe6437c1bc58 100644
--- a/svx/source/items/autoformathelper.cxx
+++ b/svx/source/items/autoformathelper.cxx
@@ -19,9 +19,7 @@
 
 #include <svx/autoformathelper.hxx>
 #include <tools/stream.hxx>
-#include <svl/legacyitem.hxx>
 #include <editeng/legacyitem.hxx>
-#include <legacyitem.hxx>
 #include <editeng/fontitem.hxx>
 #include <editeng/fhgtitem.hxx>
 #include <editeng/wghtitem.hxx>
@@ -44,103 +42,6 @@
 
 //////////////////////////////////////////////////////////////////////////////
 
-AutoFormatVersions::AutoFormatVersions()
-:   nFontVersion(0),
-    nFontHeightVersion(0),
-    nWeightVersion(0),
-    nPostureVersion(0),
-    nUnderlineVersion(0),
-    nOverlineVersion(0),
-    nCrossedOutVersion(0),
-    nContourVersion(0),
-    nShadowedVersion(0),
-    nColorVersion(0),
-    nBoxVersion(0),
-    nLineVersion(0),
-    nBrushVersion(0),
-    nAdjustVersion(0),
-    nHorJustifyVersion(0),
-    nVerJustifyVersion(0),
-    nOrientationVersion(0),
-    nMarginVersion(0),
-    nBoolVersion(0),
-    nInt32Version(0),
-    nRotateModeVersion(0),
-    nNumFormatVersion(0)
-{
-}
-
-const sal_uInt16 AUTOFORMAT_ID_300OVRLN      = 10031;
-const sal_uInt16 AUTOFORMAT_ID_680DR14      = 10011;
-const sal_uInt16 AUTOFORMAT_ID_504      = 9801;
-
-void AutoFormatVersions::LoadBlockA( SvStream& rStream, sal_uInt16 nVer )
-{
-    rStream.ReadUInt16( nFontVersion );
-    rStream.ReadUInt16( nFontHeightVersion );
-    rStream.ReadUInt16( nWeightVersion );
-    rStream.ReadUInt16( nPostureVersion );
-    rStream.ReadUInt16( nUnderlineVersion );
-    if ( nVer >= AUTOFORMAT_ID_300OVRLN )
-        rStream.ReadUInt16( nOverlineVersion );
-    rStream.ReadUInt16( nCrossedOutVersion );
-    rStream.ReadUInt16( nContourVersion );
-    rStream.ReadUInt16( nShadowedVersion );
-    rStream.ReadUInt16( nColorVersion );
-    rStream.ReadUInt16( nBoxVersion );
-    if ( nVer >= AUTOFORMAT_ID_680DR14 )
-        rStream.ReadUInt16( nLineVersion );
-    rStream.ReadUInt16( nBrushVersion );
-    rStream.ReadUInt16( nAdjustVersion );
-}
-
-void AutoFormatVersions::LoadBlockB( SvStream& rStream, sal_uInt16 nVer )
-{
-    rStream.ReadUInt16( nHorJustifyVersion );
-    rStream.ReadUInt16( nVerJustifyVersion );
-    rStream.ReadUInt16( nOrientationVersion );
-    rStream.ReadUInt16( nMarginVersion );
-    rStream.ReadUInt16( nBoolVersion );
-    if ( nVer >= AUTOFORMAT_ID_504 )
-    {
-        rStream.ReadUInt16( nInt32Version );
-        rStream.ReadUInt16( nRotateModeVersion );
-    }
-    rStream.ReadUInt16( nNumFormatVersion );
-}
-
-void AutoFormatVersions::WriteBlockA(SvStream& rStream, sal_uInt16 fileVersion)
-{
-    rStream.WriteUInt16(legacy::SvxFont::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxFontHeight::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxWeight::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxPosture::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxTextLine::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxTextLine::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxCrossedOut::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SfxBool::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SfxBool::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxColor::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxBox::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxLine::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxBrush::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxAdjust::GetVersion(fileVersion));
-}
-
-void AutoFormatVersions::WriteBlockB(SvStream& rStream, sal_uInt16 fileVersion)
-{
-    rStream.WriteUInt16(legacy::SvxHorJustify::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxVerJustify::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxOrientation::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxMargin::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SfxBool::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::CntInt32::GetVersion(fileVersion));
-    rStream.WriteUInt16(legacy::SvxRotateMode::GetVersion(fileVersion));
-    rStream.WriteUInt16( 0 );       // NumberFormat
-}
-
-//////////////////////////////////////////////////////////////////////////////
-
 void AutoFormatBase::SetFont( const SvxFontItem& rNew )             { 
m_aFont.reset(rNew.Clone()); }
 void AutoFormatBase::SetHeight( const SvxFontHeightItem& rNew )     { 
m_aHeight.reset(rNew.Clone()); }
 void AutoFormatBase::SetWeight( const SvxWeightItem& rNew )         { 
m_aWeight.reset(rNew.Clone()); }
@@ -257,137 +158,4 @@ AutoFormatBase& AutoFormatBase::operator=(const 
AutoFormatBase& rRef)
     return *this;
 }
 
-const sal_uInt16 AUTOFORMAT_DATA_ID_641 = 10002;
-const sal_uInt16 AUTOFORMAT_DATA_ID_300OVRLN = 10032;
-const sal_uInt16 AUTOFORMAT_DATA_ID_680DR14 = 10012;
-const sal_uInt16 AUTOFORMAT_DATA_ID_504 = 9802;
-
-bool AutoFormatBase::LoadBlockA( SvStream& rStream, const AutoFormatVersions& 
rVersions, sal_uInt16 nVer )
-{
-    legacy::SvxFont::Create(*m_aFont, rStream, rVersions.nFontVersion);
-
-    if( rStream.GetStreamCharSet() == m_aFont->GetCharSet() )
-    {
-        m_aFont->SetCharSet(::osl_getThreadTextEncoding());
-    }
-
-    legacy::SvxFontHeight::Create(*m_aHeight, rStream, 
rVersions.nFontHeightVersion);
-    legacy::SvxWeight::Create(*m_aWeight, rStream, rVersions.nWeightVersion);
-    legacy::SvxPosture::Create(*m_aPosture, rStream, 
rVersions.nPostureVersion);
-
-    // --- from 641 on: CJK and CTL font settings
-    if( AUTOFORMAT_DATA_ID_641 <= nVer )
-    {
-        legacy::SvxFont::Create(*m_aCJKFont, rStream, rVersions.nFontVersion);
-        legacy::SvxFontHeight::Create(*m_aCJKHeight, rStream, 
rVersions.nFontHeightVersion);
-        legacy::SvxWeight::Create(*m_aCJKWeight, rStream, 
rVersions.nWeightVersion);
-        legacy::SvxPosture::Create(*m_aCJKPosture, rStream, 
rVersions.nPostureVersion);
-
-        legacy::SvxFont::Create(*m_aCTLFont, rStream, rVersions.nFontVersion);
-        legacy::SvxFontHeight::Create(*m_aCTLHeight, rStream, 
rVersions.nFontHeightVersion);
-        legacy::SvxWeight::Create(*m_aCTLWeight, rStream, 
rVersions.nWeightVersion);
-        legacy::SvxPosture::Create(*m_aCTLPosture, rStream, 
rVersions.nPostureVersion);
-    }
-
-    legacy::SvxTextLine::Create(*m_aUnderline, rStream, 
rVersions.nUnderlineVersion);
-
-    if( nVer >= AUTOFORMAT_DATA_ID_300OVRLN )
-    {
-        legacy::SvxTextLine::Create(*m_aOverline, rStream, 
rVersions.nOverlineVersion);
-    }
-
-    legacy::SvxCrossedOut::Create(*m_aCrossedOut, rStream, 
rVersions.nCrossedOutVersion);
-    legacy::SfxBool::Create(*m_aContour, rStream, rVersions.nContourVersion);
-    legacy::SfxBool::Create(*m_aShadowed, rStream, rVersions.nShadowedVersion);
-    legacy::SvxColor::Create(*m_aColor, rStream, rVersions.nColorVersion);
-    legacy::SvxBox::Create(*m_aBox, rStream, rVersions.nBoxVersion);
-
-    // --- from 680/dr14 on: diagonal frame lines
-    if( nVer >= AUTOFORMAT_DATA_ID_680DR14 )
-    {
-        legacy::SvxLine::Create(*m_aTLBR, rStream, rVersions.nLineVersion);
-        legacy::SvxLine::Create(*m_aBLTR, rStream, rVersions.nLineVersion);
-    }
-
-    legacy::SvxBrush::Create(*m_aBackground, rStream, rVersions.nBrushVersion);
-    legacy::SvxAdjust::Create(*m_aAdjust, rStream, rVersions.nAdjustVersion);
-
-    return ERRCODE_NONE == rStream.GetError();
-}
-
-bool AutoFormatBase::LoadBlockB( SvStream& rStream, const AutoFormatVersions& 
rVersions, sal_uInt16 nVer )
-{
-    legacy::SvxHorJustify::Create(*m_aHorJustify, rStream, 
rVersions.nHorJustifyVersion);
-    legacy::SvxVerJustify::Create(*m_aVerJustify, rStream, 
rVersions.nVerJustifyVersion);
-    SvxOrientationItem aOrientation( SvxCellOrientation::Standard, 
TypedWhichId<SvxOrientationItem>(0));
-    legacy::SvxOrientation::Create(aOrientation, rStream, 
rVersions.nOrientationVersion);
-    legacy::SvxMargin::Create(*m_aMargin, rStream, rVersions.nMarginVersion);
-    legacy::SfxBool::Create(*m_aLinebreak, rStream, rVersions.nBoolVersion);
-
-    if ( nVer >= AUTOFORMAT_DATA_ID_504 )
-    {
-        legacy::CntInt32::Create(*m_aRotateAngle, rStream, 
rVersions.nInt32Version);
-        legacy::SvxRotateMode::Create(*m_aRotateMode, rStream, 
rVersions.nRotateModeVersion);
-    }
-
-    m_aStacked->SetValue( aOrientation.IsStacked() );
-    m_aRotateAngle->SetValue( aOrientation.GetRotation( 
Degree100(m_aRotateAngle->GetValue()) ).get() );
-
-    return ERRCODE_NONE == rStream.GetError();
-}
-
-bool AutoFormatBase::SaveBlockA( SvStream& rStream, sal_uInt16 fileVersion ) 
const
-{
-    legacy::SvxFont::Store(*m_aFont, rStream, 
legacy::SvxFont::GetVersion(fileVersion));
-    legacy::SvxFontHeight::Store(*m_aHeight, rStream, 
legacy::SvxFontHeight::GetVersion(fileVersion));
-    legacy::SvxWeight::Store(*m_aWeight, rStream, 
legacy::SvxWeight::GetVersion(fileVersion));
-    legacy::SvxPosture::Store(*m_aPosture, rStream, 
legacy::SvxPosture::GetVersion(fileVersion));
-
-    // --- from 641 on: CJK and CTL font settings
-    legacy::SvxFont::Store(*m_aCJKFont, rStream, 
legacy::SvxFont::GetVersion(fileVersion));
-    legacy::SvxFontHeight::Store(*m_aCJKHeight, rStream, 
legacy::SvxFontHeight::GetVersion(fileVersion));
-    legacy::SvxWeight::Store(*m_aCJKWeight, rStream, 
legacy::SvxWeight::GetVersion(fileVersion));
-    legacy::SvxPosture::Store(*m_aCJKPosture, rStream, 
legacy::SvxPosture::GetVersion(fileVersion));
-
-    legacy::SvxFont::Store(*m_aCTLFont, rStream, 
legacy::SvxFont::GetVersion(fileVersion));
-    legacy::SvxFontHeight::Store(*m_aCTLHeight, rStream, 
legacy::SvxFontHeight::GetVersion(fileVersion));
-    legacy::SvxWeight::Store(*m_aCTLWeight, rStream, 
legacy::SvxWeight::GetVersion(fileVersion));
-    legacy::SvxPosture::Store(*m_aCTLPosture, rStream, 
legacy::SvxPosture::GetVersion(fileVersion));
-
-    legacy::SvxTextLine::Store(*m_aUnderline, rStream, 
legacy::SvxTextLine::GetVersion(fileVersion));
-
-    // --- from DEV300/overline2 on: overline support
-    legacy::SvxTextLine::Store(*m_aOverline, rStream, 
legacy::SvxTextLine::GetVersion(fileVersion));
-    legacy::SvxCrossedOut::Store(*m_aCrossedOut, rStream, 
legacy::SvxCrossedOut::GetVersion(fileVersion));
-    legacy::SfxBool::Store(*m_aContour, rStream, 
legacy::SfxBool::GetVersion(fileVersion));
-    legacy::SfxBool::Store(*m_aShadowed, rStream, 
legacy::SfxBool::GetVersion(fileVersion));
-    legacy::SvxColor::Store(*m_aColor, rStream, 
legacy::SvxColor::GetVersion(fileVersion));
-    legacy::SvxBox::Store(*m_aBox, rStream, 
legacy::SvxBox::GetVersion(fileVersion));
-
-    // --- from 680/dr14 on: diagonal frame lines
-    legacy::SvxLine::Store(*m_aTLBR, rStream, 
legacy::SvxLine::GetVersion(fileVersion));
-    legacy::SvxLine::Store(*m_aBLTR, rStream, 
legacy::SvxLine::GetVersion(fileVersion));
-    legacy::SvxBrush::Store(*m_aBackground, rStream, 
legacy::SvxBrush::GetVersion(fileVersion));
-    legacy::SvxAdjust::Store(*m_aAdjust, rStream, 
legacy::SvxAdjust::GetVersion(fileVersion));
-
-    return ERRCODE_NONE == rStream.GetError();
-}
-
-bool AutoFormatBase::SaveBlockB( SvStream& rStream, sal_uInt16 fileVersion ) 
const
-{
-    legacy::SvxHorJustify::Store(*m_aHorJustify, rStream, 
legacy::SvxHorJustify::GetVersion(fileVersion));
-    legacy::SvxVerJustify::Store(*m_aVerJustify, rStream, 
legacy::SvxVerJustify::GetVersion(fileVersion));
-    SvxOrientationItem aOrientation( Degree100(m_aRotateAngle->GetValue()), 
m_aStacked->GetValue(), TypedWhichId<SvxOrientationItem>(0) );
-    legacy::SvxOrientation::Store(aOrientation, rStream, 
legacy::SvxOrientation::GetVersion(fileVersion));
-    legacy::SvxMargin::Store(*m_aMargin, rStream, 
legacy::SvxMargin::GetVersion(fileVersion));
-    legacy::SfxBool::Store(*m_aLinebreak, rStream, 
legacy::SfxBool::GetVersion(fileVersion));
-
-    // Calc Rotation from SO5
-    legacy::CntInt32::Store(*m_aRotateAngle, rStream, 
legacy::CntInt32::GetVersion(fileVersion));
-    legacy::SvxRotateMode::Store(*m_aRotateMode, rStream, 
legacy::SvxRotateMode::GetVersion(fileVersion));
-
-    return ERRCODE_NONE == rStream.GetError();
-}
-
-//////////////////////////////////////////////////////////////////////////////
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/items/legacyitem.cxx b/svx/source/items/legacyitem.cxx
deleted file mode 100644
index 6e7e99d8cb5c..000000000000
--- a/svx/source/items/legacyitem.cxx
+++ /dev/null
@@ -1,105 +0,0 @@
-/* -*- 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 <legacyitem.hxx>
-#include <tools/stream.hxx>
-#include <svx/algitem.hxx>
-#include <svx/rotmodit.hxx>
-
-namespace legacy
-{
-    namespace SvxOrientation
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxOrientationItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt16 nVal(0);
-            rStrm.ReadUInt16( nVal );
-            rItem.SetValue(static_cast<::SvxCellOrientation>(nVal));
-        }
-
-        SvStream& Store(const SvxOrientationItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUInt16( static_cast<sal_uInt16>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-
-    namespace SvxMargin
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxMarginItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_Int16 nLeft(0);
-            sal_Int16 nTop(0);
-            sal_Int16 nRight(0);
-            sal_Int16 nBottom(0);
-
-            rStrm.ReadInt16( nLeft );
-            rStrm.ReadInt16( nTop );
-            rStrm.ReadInt16( nRight );
-            rStrm.ReadInt16( nBottom );
-
-            rItem.SetLeftMargin(nLeft);
-            rItem.SetTopMargin(nTop);
-            rItem.SetRightMargin(nRight);
-            rItem.SetBottomMargin(nBottom);
-        }
-
-        SvStream& Store(const SvxMarginItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteInt16( rItem.GetLeftMargin() );
-            rStrm.WriteInt16( rItem.GetTopMargin() );
-            rStrm.WriteInt16( rItem.GetRightMargin() );
-            rStrm.WriteInt16( rItem.GetBottomMargin() );
-            return rStrm;
-        }
-    }
-
-    namespace SvxRotateMode
-    {
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SvxRotateModeItem& rItem, SvStream& rStrm, sal_uInt16)
-        {
-            sal_uInt16 nVal(0);
-            rStrm.ReadUInt16( nVal );
-            rItem.SetValue(static_cast<::SvxRotateMode>(nVal));
-        }
-
-        SvStream& Store(const SvxRotateModeItem& rItem, SvStream& rStrm, 
sal_uInt16)
-        {
-            rStrm.WriteUInt16( static_cast<sal_uInt16>(rItem.GetValue()) );
-            return rStrm;
-        }
-    }
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/Library_sw.mk b/sw/Library_sw.mk
index f03bd8192b23..cd8f026352e0 100644
--- a/sw/Library_sw.mk
+++ b/sw/Library_sw.mk
@@ -352,7 +352,6 @@ $(eval $(call gb_Library_add_exception_objects,sw,\
     sw/source/core/layout/layact \
     sw/source/core/layout/laycache \
     sw/source/core/layout/layouter \
-    sw/source/core/layout/legacyitem \
     sw/source/core/layout/movedfwdfrmsbyobjpos \
     sw/source/core/layout/newfrm \
     sw/source/core/layout/objectformatter \
diff --git a/sw/inc/fesh.hxx b/sw/inc/fesh.hxx
index 3871507b9120..2ee2ddd31323 100644
--- a/sw/inc/fesh.hxx
+++ b/sw/inc/fesh.hxx
@@ -737,7 +737,6 @@ public:
     /// Set table style of the current table.
     void SetTableStyle(const TableStyleName& rStyleName);
     SW_DLLPUBLIC bool SetTableStyle(const SwTableAutoFormat& rNew);
-    SW_DLLPUBLIC bool ResetTableStyle();
 
     /// Update the direct formatting according to the current table style.
     /// @param pTableNode Table node to update.  When nullptr, current cursor 
position is used.
diff --git a/sw/inc/legacyitem.hxx b/sw/inc/legacyitem.hxx
deleted file mode 100644
index 5d284c8afecf..000000000000
--- a/sw/inc/legacyitem.hxx
+++ /dev/null
@@ -1,42 +0,0 @@
-/* -*- 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 .
- */
-
-#pragma once
-
-#include <sal/types.h>
-
-//////////////////////////////////////////////////////////////////////////////
-// // sw
-//     SwFormatVertOrient m_aVerticalAlignment;
-//////////////////////////////////////////////////////////////////////////////
-
-class SvStream;
-class SwFormatVertOrient;
-
-namespace legacy
-{
-    namespace SwFormatVert
-    {
-        sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion);
-        void Create(SwFormatVertOrient& rItem, SvStream& rStrm, sal_uInt16 
nItemVersion);
-        SvStream& Store(const SwFormatVertOrient& rItem, SvStream& rStrm, 
sal_uInt16 nItemVersion);
-    }
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index 433cee285a52..3330d34a7f04 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -325,9 +325,6 @@ class AbstractSwAutoFormatDlg : public VclAbstractDialog
 {
 protected:
     virtual ~AbstractSwAutoFormatDlg() override = default;
-public:
-    virtual std::unique_ptr<SwTableAutoFormat> FillAutoFormatOfIndex() const = 
0;
-    virtual void Apply() = 0;
 };
 
 class AbstractSwFieldDlg : public SfxAbstractTabDialog
diff --git a/sw/inc/swmodule.hxx b/sw/inc/swmodule.hxx
index ee4f0f3aba32..a49911064399 100644
--- a/sw/inc/swmodule.hxx
+++ b/sw/inc/swmodule.hxx
@@ -256,7 +256,6 @@ public:
     void CallAutomationApplicationEventSinks(const OUString& Method, 
css::uno::Sequence< css::uno::Any >& Arguments);
 
     SW_DLLPUBLIC const SwTableAutoFormatTable& GetAutoFormatTable();
-    void InvalidateAutoFormatTable();;
 
 //    Access to SwModule
     static auto get() { return 
static_cast<SwModule*>(SfxApplication::GetModule(SfxToolsModule::Writer)); }
diff --git a/sw/inc/tblafmt.hxx b/sw/inc/tblafmt.hxx
index 4520a568597d..069a8f65c8c5 100644
--- a/sw/inc/tblafmt.hxx
+++ b/sw/inc/tblafmt.hxx
@@ -101,7 +101,6 @@ class SW_DLLPUBLIC SwTableAutoFormat : public 
SvxAutoFormatData
     friend void FinitCore(); // To destroy default pointer.
 
     TableStyleName m_aName; // note that this could be a ProgName __or__ a 
UIName
-    sal_uInt16 m_nStrResId;
     bool m_bHidden;
     bool m_bUserDefined;
 
diff --git a/sw/source/core/doc/tblafmt.cxx b/sw/source/core/doc/tblafmt.cxx
index 516b923c82ae..57fdcb353bbe 100644
--- a/sw/source/core/doc/tblafmt.cxx
+++ b/sw/source/core/doc/tblafmt.cxx
@@ -52,7 +52,6 @@
 #include <editeng/wghtitem.hxx>
 #include <svx/algitem.hxx>
 #include <svx/rotmodit.hxx>
-#include <legacyitem.hxx>
 #include <unostyle.hxx>
 #include <names.hxx>
 
@@ -218,7 +217,6 @@ void 
SwBoxAutoFormat::SetXObject(rtl::Reference<SwXTextCellStyle> const& xObject
 SwTableAutoFormat::SwTableAutoFormat(const TableStyleName& aName)
     : SvxAutoFormatData()
     , m_aName(aName)
-    , m_nStrResId(USHRT_MAX)
     , m_bHidden(false)
     , m_bUserDefined(true)
 {
@@ -244,7 +242,6 @@ SwTableAutoFormat::SwTableAutoFormat(const 
SwTableAutoFormat& rNew)
 SwTableAutoFormat::SwTableAutoFormat(const SvxAutoFormatData& rNew)
     : SvxAutoFormatData(rNew)
     , m_aName(rNew.GetName())
-    , m_nStrResId(USHRT_MAX)
     , m_bHidden(false)
     , m_bUserDefined(true)
 {
@@ -261,7 +258,6 @@ SwTableAutoFormat& SwTableAutoFormat::operator=(const 
SwTableAutoFormat& rNew)
         return *this;
 
     m_aName = rNew.m_aName;
-    m_nStrResId = USHRT_MAX;
     SetParent(rNew.GetParent());
     SetFont(rNew.IsFont());
     SetJustify(rNew.IsJustify());
@@ -285,7 +281,6 @@ void SwTableAutoFormat::SetName(const TableStyleName& rNew)
 {
     m_aName = rNew;
     SvxAutoFormatData::SetName(rNew.toString());
-    m_nStrResId = USHRT_MAX;
 }
 
 void SwTableAutoFormat::SetName(const OUString& rName)
diff --git a/sw/source/core/frmedt/fetab.cxx b/sw/source/core/frmedt/fetab.cxx
index f877e292121c..d8c705b6dc24 100644
--- a/sw/source/core/frmedt/fetab.cxx
+++ b/sw/source/core/frmedt/fetab.cxx
@@ -1407,16 +1407,6 @@ void SwFEShell::SetTableStyle(const TableStyleName& 
rStyleName)
     UpdateTableStyleFormatting(pTableNode, false, &rStyleName);
 }
 
-bool SwFEShell::ResetTableStyle()
-{
-    SwTableNode *pTableNode = const_cast<SwTableNode*>(IsCursorInTable());
-    if (!pTableNode)
-        return false;
-
-    TableStyleName takingAddressOfRValue;
-    return UpdateTableStyleFormatting(pTableNode, false, 
&takingAddressOfRValue);
-}
-
     // AutoFormat for the table/table selection
 bool SwFEShell::SetTableStyle(const SwTableAutoFormat& rStyle)
 {
diff --git a/sw/source/core/layout/legacyitem.cxx 
b/sw/source/core/layout/legacyitem.cxx
deleted file mode 100644
index 281b71d83bc7..000000000000
--- a/sw/source/core/layout/legacyitem.cxx
+++ /dev/null
@@ -1,78 +0,0 @@
-/* -*- 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 <legacyitem.hxx>
-#include <tools/stream.hxx>
-#include <sal/log.hxx>
-#include <fmtornt.hxx>
-
-namespace legacy::SwFormatVert
-{
-        sal_uInt16 GetVersion(sal_uInt16)
-        {
-            return 0;
-        }
-
-        void Create(SwFormatVertOrient& rItem, SvStream& rStrm, sal_uInt16 
nVersionAbusedAsSize)
-        {
-            SwTwips yPos(0);
-            sal_Int16 orient(0);
-            sal_Int16 relation(0);
-
-            switch (nVersionAbusedAsSize)
-            {
-                // compatibility hack for Table Auto Format: SwTwips is "long" 
:(
-                // (this means that the file format is platform dependent)
-                case 14:
-                {
-                    sal_Int64 n(0);
-                    rStrm.ReadInt64(n);
-                    yPos = n;
-                    break;
-                }
-                case 10:
-                {
-                    sal_Int32 n(0);
-e 
... etc. - the rest is truncated

Reply via email to