tdf#42949 Fix IWYU warnings in sw/source/core/inc/[g-S]*hxx
Found with bin/find-unneeded-includes
Only removal proposals are dealt with here.
Change-Id: I4ebebbbbad31b29c1e63a30685493042462bb52f
Reviewed-on: https://gerrit.libreoffice.org/71832
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
diff --git a/sw/IwyuFilter_sw.yaml b/sw/IwyuFilter_sw.yaml
index 7405d42..15e849e 100644
--- a/sw/IwyuFilter_sw.yaml
+++ b/sw/IwyuFilter_sw.yaml
@@ -262,6 +262,14 @@ blacklist:
sw/source/core/inc/frame.hxx:
# Needed for direct member access
- com/sun/star/style/TabStop.hpp
sw/source/core/inc/SwXTextDefaults.hxx:
# Base class needs complete type
- com/sun/star/beans/XPropertySet.hpp
- com/sun/star/beans/XPropertyState.hpp
- com/sun/star/lang/XServiceInfo.hpp
sw/source/core/inc/swthreadjoiner.hxx:
# Needed for css shortcut
- sal/types.h
sw/qa/extras/odfexport/odfexport.cxx:
# Needed for getProperty template
- com/sun/star/graphic/XGraphic.hpp
diff --git a/sw/inc/hintids.hxx b/sw/inc/hintids.hxx
index 609c705..72c20b2 100644
--- a/sw/inc/hintids.hxx
+++ b/sw/inc/hintids.hxx
@@ -36,6 +36,7 @@ class SwMsgPoolItem;
class SwPtrMsgPoolItem;
class SfxBoolItem;
class SvxColorItem;
class SvxLRSpaceItem;
// For SwTextHints without end index the following char is added:
diff --git a/sw/source/core/doc/docdesc.cxx b/sw/source/core/doc/docdesc.cxx
index fe9cb3f..ca14991 100644
--- a/sw/source/core/doc/docdesc.cxx
+++ b/sw/source/core/doc/docdesc.cxx
@@ -20,6 +20,7 @@
#include <cmdid.h>
#include <init.hxx>
#include <svx/svdmodel.hxx>
#include <editeng/lrspitem.hxx>
#include <editeng/ulspitem.hxx>
#include <editeng/paperinf.hxx>
#include <editeng/frmdiritem.hxx>
diff --git a/sw/source/core/docnode/observablethread.cxx b/sw/source/core/docnode/observablethread.cxx
index 479eb2c..273dd45 100644
--- a/sw/source/core/docnode/observablethread.cxx
+++ b/sw/source/core/docnode/observablethread.cxx
@@ -18,6 +18,7 @@
*/
#include <observablethread.hxx>
#include <ifinishedthreadlistener.hxx>
#include <memory>
/* class for an observable thread
diff --git a/sw/source/core/inc/DropDownFormFieldButton.hxx b/sw/source/core/inc/DropDownFormFieldButton.hxx
index e8b9153..1147f59 100644
--- a/sw/source/core/inc/DropDownFormFieldButton.hxx
+++ b/sw/source/core/inc/DropDownFormFieldButton.hxx
@@ -13,7 +13,6 @@
#include <vcl/menubtn.hxx>
#include <swrect.hxx>
class SwFieldFormDropDownPortion;
class SwEditWin;
class FloatingWindow;
namespace sw
diff --git a/sw/source/core/inc/GetMetricVal.hxx b/sw/source/core/inc/GetMetricVal.hxx
index eca6b9e..9b17975 100644
--- a/sw/source/core/inc/GetMetricVal.hxx
+++ b/sw/source/core/inc/GetMetricVal.hxx
@@ -20,7 +20,7 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_GETMETRICVAL_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_GETMETRICVAL_HXX
#include <tools/solar.h>
#include <sal/types.h>
#define CM_1 0 // 1 centimeter or 1/2 inch
#define CM_05 1 // 0.5 centimeter or 1/4 inch
diff --git a/sw/source/core/inc/MarkManager.hxx b/sw/source/core/inc/MarkManager.hxx
index 11291f7..fd0d19b 100644
--- a/sw/source/core/inc/MarkManager.hxx
+++ b/sw/source/core/inc/MarkManager.hxx
@@ -22,7 +22,6 @@
#include <IMark.hxx>
#include <IDocumentMarkAccess.hxx>
#include <unordered_set>
#include <unordered_map>
#include <memory>
diff --git a/sw/source/core/inc/SwPortionHandler.hxx b/sw/source/core/inc/SwPortionHandler.hxx
index 0a2e4ee..2036b0a 100644
--- a/sw/source/core/inc/SwPortionHandler.hxx
+++ b/sw/source/core/inc/SwPortionHandler.hxx
@@ -20,7 +20,8 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_SWPORTIONHANDLER_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_SWPORTIONHANDLER_HXX
#include <swtypes.hxx>
#include <swdllapi.h>
#include <rtl/ustring.hxx>
#include "TextFrameIndex.hxx"
class SwFont;
diff --git a/sw/source/core/inc/SwUndoFmt.hxx b/sw/source/core/inc/SwUndoFmt.hxx
index f097a18..552a61f 100644
--- a/sw/source/core/inc/SwUndoFmt.hxx
+++ b/sw/source/core/inc/SwUndoFmt.hxx
@@ -28,7 +28,6 @@ class SwDoc;
class SwTextFormatColl;
class SwConditionTextFormatColl;
class SwRewriter;
class SfxItemSet;
class SwUndoFormatCreate : public SwUndo
{
diff --git a/sw/source/core/inc/SwUndoPageDesc.hxx b/sw/source/core/inc/SwUndoPageDesc.hxx
index 04094ab..79a8911 100644
--- a/sw/source/core/inc/SwUndoPageDesc.hxx
+++ b/sw/source/core/inc/SwUndoPageDesc.hxx
@@ -24,7 +24,6 @@
#include <pagedesc.hxx>
class SwDoc;
class SwPageDesc;
class SwUndoPageDesc : public SwUndo
{
diff --git a/sw/source/core/inc/SwXMLBlockImport.hxx b/sw/source/core/inc/SwXMLBlockImport.hxx
index 95515d2..3de78a1 100644
--- a/sw/source/core/inc/SwXMLBlockImport.hxx
+++ b/sw/source/core/inc/SwXMLBlockImport.hxx
@@ -21,13 +21,13 @@
#define INCLUDED_SW_SOURCE_CORE_INC_SWXMLBLOCKIMPORT_HXX
#include <xmloff/xmlimp.hxx>
#include <xmloff/nmspmap.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <com/sun/star/xml/sax/XFastTokenHandler.hpp>
#include <com/sun/star/xml/sax/FastToken.hpp>
#include <sax/fastattribs.hxx>
#include <cppuhelper/implbase.hxx>
namespace com::sun::star::xml::sax { class XFastTokenHandler; }
using namespace css::xml::sax;
using namespace xmloff::token;
diff --git a/sw/source/core/inc/SwXMLTextBlocks.hxx b/sw/source/core/inc/SwXMLTextBlocks.hxx
index e294eb9..d4cfd80 100644
--- a/sw/source/core/inc/SwXMLTextBlocks.hxx
+++ b/sw/source/core/inc/SwXMLTextBlocks.hxx
@@ -21,11 +21,9 @@
#define INCLUDED_SW_SOURCE_CORE_INC_SWXMLTEXTBLOCKS_HXX
#include <sfx2/objsh.hxx>
#include <sfx2/docfile.hxx>
#include "swblocks.hxx"
#include <o3tl/typed_flags_set.hxx>
class SwPaM;
class SwDoc;
class SvxMacroTableDtor;
diff --git a/sw/source/core/inc/SwXTextDefaults.hxx b/sw/source/core/inc/SwXTextDefaults.hxx
index 773259e..f989600 100644
--- a/sw/source/core/inc/SwXTextDefaults.hxx
+++ b/sw/source/core/inc/SwXTextDefaults.hxx
@@ -23,9 +23,9 @@
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/XPropertyState.hpp>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <svl/itemprop.hxx>
class SwDoc;
class SfxItemPropertySet;
class SwXTextDefaults : public cppu::WeakImplHelper
<
diff --git a/sw/source/core/inc/frmtool.hxx b/sw/source/core/inc/frmtool.hxx
index 8765dd0..4340e40 100644
--- a/sw/source/core/inc/frmtool.hxx
+++ b/sw/source/core/inc/frmtool.hxx
@@ -23,7 +23,6 @@
#include <swtypes.hxx>
#include "frame.hxx"
#include "swcache.hxx"
#include <editeng/lrspitem.hxx>
#include <swatrset.hxx>
class SwLayoutFrame;
diff --git a/sw/source/core/inc/layact.hxx b/sw/source/core/inc/layact.hxx
index 1253233..da2250e 100644
--- a/sw/source/core/inc/layact.hxx
+++ b/sw/source/core/inc/layact.hxx
@@ -22,12 +22,14 @@
#include <sal/config.h>
#include <vcl/inputtypes.hxx>
#include <tools/color.hxx>
#include <ctime>
#include <memory>
#include <swtypes.hxx>
#include <swrect.hxx>
class OutputDevice;
class SwRootFrame;
class SwLayoutFrame;
class SwPageFrame;
diff --git a/sw/source/core/inc/laycache.hxx b/sw/source/core/inc/laycache.hxx
index 38f4647..6f3a5a0 100644
--- a/sw/source/core/inc/laycache.hxx
+++ b/sw/source/core/inc/laycache.hxx
@@ -20,7 +20,7 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_LAYCACHE_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_LAYCACHE_HXX
#include <tools/solar.h>
#include <sal/types.h>
#include <memory>
class SwDoc;
diff --git a/sw/source/core/inc/layfrm.hxx b/sw/source/core/inc/layfrm.hxx
index 8fd0e5f..f39c9ae 100644
--- a/sw/source/core/inc/layfrm.hxx
+++ b/sw/source/core/inc/layfrm.hxx
@@ -24,7 +24,6 @@
class SwAnchoredObject;
class SwContentFrame;
class SwFlowFrame;
class SwFormatCol;
struct SwCursorMoveState;
class SwFrameFormat;
diff --git a/sw/source/core/inc/observablethread.hxx b/sw/source/core/inc/observablethread.hxx
index 5d7231b..3d10a7f 100644
--- a/sw/source/core/inc/observablethread.hxx
+++ b/sw/source/core/inc/observablethread.hxx
@@ -20,12 +20,12 @@
#define INCLUDED_SW_SOURCE_CORE_INC_OBSERVABLETHREAD_HXX
#include <osl/thread.hxx>
#include <rtl/ref.hxx>
#include <osl/interlck.h>
#include <salhelper/simplereferenceobject.hxx>
#include "ifinishedthreadlistener.hxx"
#include <memory>
class IFinishedThreadListener;
/** class for an observable thread
OD 2007-01-29 #i73788#
diff --git a/sw/source/core/inc/pamtyp.hxx b/sw/source/core/inc/pamtyp.hxx
index c9fc812..ae0f1b3 100644
--- a/sw/source/core/inc/pamtyp.hxx
+++ b/sw/source/core/inc/pamtyp.hxx
@@ -21,7 +21,9 @@
#define INCLUDED_SW_SOURCE_CORE_INC_PAMTYP_HXX
#include <unotools/textsearch.hxx>
#include <node.hxx>
#include <swdllapi.h>
#include <memory>
class SwpHints;
struct SwPosition;
@@ -30,13 +32,14 @@ class SwTextAttr;
class SwFormat;
class SfxPoolItem;
class SwRootFrame;
class SwNode;
class SwNodeIndex;
class SwContentNode;
class SwIndex;
namespace i18nutil {
struct SearchOptions2;
}
namespace utl {
class TextSearch;
}
// function prototypes for the move/find methods of SwPaM
diff --git a/sw/source/core/inc/retrievedinputstreamdata.hxx b/sw/source/core/inc/retrievedinputstreamdata.hxx
index cb8666c..505f18f 100644
--- a/sw/source/core/inc/retrievedinputstreamdata.hxx
+++ b/sw/source/core/inc/retrievedinputstreamdata.hxx
@@ -22,13 +22,13 @@
#include <tools/link.hxx>
#include <sal/types.h>
#include <osl/mutex.hxx>
#include <rtl/instance.hxx>
#include <com/sun/star/uno/Reference.hxx>
#include <com/sun/star/io/XInputStream.hpp>
#include <map>
#include <memory>
namespace com::sun::star::io { class XInputStream; }
class SwAsyncRetrieveInputStreamThreadConsumer;
/** Singleton class to manage retrieved input stream data in Writer
diff --git a/sw/source/core/inc/retrieveinputstream.hxx b/sw/source/core/inc/retrieveinputstream.hxx
index 44a1ba7..579efb2 100644
--- a/sw/source/core/inc/retrieveinputstream.hxx
+++ b/sw/source/core/inc/retrieveinputstream.hxx
@@ -20,6 +20,7 @@
#define INCLUDED_SW_SOURCE_CORE_INC_RETRIEVEINPUTSTREAM_HXX
#include "observablethread.hxx"
#include <rtl/ref.hxx>
#include <rtl/ustring.hxx>
#include "retrievedinputstreamdata.hxx"
diff --git a/sw/source/core/inc/retrieveinputstreamconsumer.hxx b/sw/source/core/inc/retrieveinputstreamconsumer.hxx
index 952433f..ba6424e 100644
--- a/sw/source/core/inc/retrieveinputstreamconsumer.hxx
+++ b/sw/source/core/inc/retrieveinputstreamconsumer.hxx
@@ -19,10 +19,11 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_RETRIEVEINPUTSTREAMCONSUMER_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_RETRIEVEINPUTSTREAMCONSUMER_HXX
#include <com/sun/star/uno/Reference.hxx>
#include <com/sun/star/io/XInputStream.hpp>
#include <osl/interlck.h>
#include "retrievedinputstreamdata.hxx"
#include <rtl/ustring.hxx>
namespace com::sun::star::io { class XInputStream; }
namespace com::sun::star::uno { template <typename > class Reference; }
class SwGrfNode;
diff --git a/sw/source/core/inc/rolbck.hxx b/sw/source/core/inc/rolbck.hxx
index 2feec7e..eafb74f 100644
--- a/sw/source/core/inc/rolbck.hxx
+++ b/sw/source/core/inc/rolbck.hxx
@@ -25,7 +25,6 @@
#include <vcl/keycod.hxx>
#include <tox.hxx>
#include <SwNumberTreeTypes.hxx>
#include <IDocumentMarkAccess.hxx>
#include <memory>
diff --git a/sw/source/core/inc/rootfrm.hxx b/sw/source/core/inc/rootfrm.hxx
index 9124488..b1d459e 100644
--- a/sw/source/core/inc/rootfrm.hxx
+++ b/sw/source/core/inc/rootfrm.hxx
@@ -28,7 +28,6 @@
#include <vector>
class SwContentFrame;
class SwViewShell;
class SdrPage;
class SwFrameFormat;
class SwPaM;
diff --git a/sw/source/core/inc/scriptinfo.hxx b/sw/source/core/inc/scriptinfo.hxx
index 956a95b..4fae597 100644
--- a/sw/source/core/inc/scriptinfo.hxx
+++ b/sw/source/core/inc/scriptinfo.hxx
@@ -23,9 +23,8 @@
#include <vector>
#include <deque>
#include <unordered_set>
#include <swscanner.hxx>
#include <rtl/ustrbuf.hxx>
#include <osl/diagnose.h>
#include <i18nlangtag/lang.h>
#include "TextFrameIndex.hxx"
class SwTextNode;
diff --git a/sw/source/core/inc/sortedobjs.hxx b/sw/source/core/inc/sortedobjs.hxx
index 5e5dcc4..6d524f4 100644
--- a/sw/source/core/inc/sortedobjs.hxx
+++ b/sw/source/core/inc/sortedobjs.hxx
@@ -19,7 +19,6 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_SORTEDOBJS_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_SORTEDOBJS_HXX
#include <sal/types.h>
#include <vector>
#include <swdllapi.h>
diff --git a/sw/source/core/inc/swblocks.hxx b/sw/source/core/inc/swblocks.hxx
index d1a3116..9043fb8 100644
--- a/sw/source/core/inc/swblocks.hxx
+++ b/sw/source/core/inc/swblocks.hxx
@@ -19,7 +19,8 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_SWBLOCKS_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_SWBLOCKS_HXX
#include <tools/datetime.hxx>
#include <tools/date.hxx>
#include <tools/time.hxx>
#include <o3tl/sorted_vector.hxx>
#include <vcl/errcode.hxx>
#include <rtl/ref.hxx>
diff --git a/sw/source/core/inc/swcache.hxx b/sw/source/core/inc/swcache.hxx
index 00f3351..fe2d516 100644
--- a/sw/source/core/inc/swcache.hxx
+++ b/sw/source/core/inc/swcache.hxx
@@ -46,7 +46,7 @@
#include <memory>
#include <vector>
#include <rtl/ustring.hxx>
#include <rtl/string.hxx>
class SwCacheObj;
diff --git a/sw/source/core/inc/swfont.hxx b/sw/source/core/inc/swfont.hxx
index c8a938e..175c7c0 100644
--- a/sw/source/core/inc/swfont.hxx
+++ b/sw/source/core/inc/swfont.hxx
@@ -34,7 +34,6 @@
class SfxItemSet;
class SwAttrSet;
class SwDoCapitals; // DoCapitals
class SwDrawTextInfo; // DrawText_
class SwScriptInfo; // GetTextSize_
class SwViewShell;
class IDocumentSettingAccess;
diff --git a/sw/source/core/inc/swthreadjoiner.hxx b/sw/source/core/inc/swthreadjoiner.hxx
index 1bab117..e22fb90 100644
--- a/sw/source/core/inc/swthreadjoiner.hxx
+++ b/sw/source/core/inc/swthreadjoiner.hxx
@@ -19,7 +19,10 @@
#ifndef INCLUDED_SW_SOURCE_CORE_INC_SWTHREADJOINER_HXX
#define INCLUDED_SW_SOURCE_CORE_INC_SWTHREADJOINER_HXX
#include <com/sun/star/util/XJobManager.hpp>
#include <sal/types.h>
namespace com::sun::star::uno { template <class interface_type> class Reference; }
namespace com::sun::star::util { class XJobManager; }
/** Testing */
namespace SwThreadJoiner
diff --git a/sw/source/core/inc/swthreadmanager.hxx b/sw/source/core/inc/swthreadmanager.hxx
index 178f1411..2895268 100644
--- a/sw/source/core/inc/swthreadmanager.hxx
+++ b/sw/source/core/inc/swthreadmanager.hxx
@@ -20,10 +20,11 @@
#define INCLUDED_SW_SOURCE_CORE_INC_SWTHREADMANAGER_HXX
#include <osl/interlck.h>
#include <rtl/ref.hxx>
#include <memory>
namespace rtl { template <class reference_type> class Reference; }
class ObservableThread;
class ThreadManager;
diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx
index 312a7a7..871ced3 100644
--- a/sw/source/core/text/porlay.cxx
+++ b/sw/source/core/text/porlay.cxx
@@ -52,6 +52,7 @@
#include <section.hxx>
#include <calbck.hxx>
#include <doc.hxx>
#include <swscanner.hxx>
#include <IDocumentRedlineAccess.hxx>
#include <IDocumentSettingAccess.hxx>
#include <IDocumentContentOperations.hxx>
diff --git a/sw/source/core/txtnode/txtedt.cxx b/sw/source/core/txtnode/txtedt.cxx
index 54dbe39..c4dd0d0 100644
--- a/sw/source/core/txtnode/txtedt.cxx
+++ b/sw/source/core/txtnode/txtedt.cxx
@@ -52,6 +52,7 @@
#include <txtfrm.hxx>
#include <SwGrammarMarkUp.hxx>
#include <rootfrm.hxx>
#include <swscanner.hxx>
#include <breakit.hxx>
#include <crstate.hxx>
diff --git a/sw/source/core/unocore/SwXTextDefaults.cxx b/sw/source/core/unocore/SwXTextDefaults.cxx
index 5f094af..ffbbb29 100644
--- a/sw/source/core/unocore/SwXTextDefaults.cxx
+++ b/sw/source/core/unocore/SwXTextDefaults.cxx
@@ -21,6 +21,7 @@
#include <vcl/svapp.hxx>
#include <osl/diagnose.h>
#include <svl/itemprop.hxx>
#include <SwXTextDefaults.hxx>
#include <SwStyleNameMapper.hxx>