From 2a594d3e90a673c56df9766658a79cf0bcaeb9a8 Mon Sep 17 00:00:00 2001 From: Yuriy Skalko Date: Tue, 13 Oct 2020 09:40:24 +0300 Subject: [PATCH] Remove unused forward declarations --- src/Buffer.h | 4 ---- src/BufferView.h | 3 --- src/Citation.h | 2 -- src/CoordCache.h | 2 -- src/CutAndPaste.h | 1 - src/LayoutFile.h | 2 -- src/ParIterator.h | 1 - src/Paragraph.h | 6 ------ src/ParagraphMetrics.h | 6 ------ src/buffer_funcs.h | 2 -- src/frontends/Application.h | 7 ------- src/frontends/Delegates.h | 1 - src/frontends/WorkArea.h | 3 --- src/frontends/qt/GuiApplication.h | 6 +++--- src/frontends/qt/GuiCitation.h | 2 -- src/frontends/qt/GuiCompleter.h | 2 -- src/frontends/qt/GuiDocument.h | 2 -- src/frontends/qt/GuiErrorList.h | 2 -- src/frontends/qt/GuiLyXFiles.h | 4 ---- src/frontends/qt/GuiPainter.h | 2 -- src/frontends/qt/GuiPrefs.h | 4 ---- src/frontends/qt/GuiSelectionManager.h | 2 -- src/frontends/qt/GuiSpellchecker.h | 2 -- src/frontends/qt/GuiToc.h | 1 - src/frontends/qt/GuiToolbar.h | 5 ----- src/frontends/qt/GuiWorkArea.h | 3 +-- src/frontends/qt/GuiWorkArea_Private.h | 2 -- src/frontends/qt/LayoutBox.h | 3 --- src/frontends/qt/LyXFileDialog.h | 2 -- src/frontends/qt/PanelStack.h | 3 --- src/frontends/qt/TocModel.h | 1 - src/frontends/qt/qt_helpers.h | 4 ---- src/graphics/GraphicsCacheItem.h | 1 - src/graphics/PreviewImage.h | 1 - src/insets/ExternalTransforms.h | 2 -- src/insets/Inset.h | 3 --- src/insets/InsetBibitem.h | 2 -- src/insets/InsetBibtex.h | 1 - src/insets/InsetCaptionable.h | 2 ++ src/insets/InsetCollapsible.h | 2 -- src/insets/InsetERT.h | 2 -- src/insets/InsetInclude.h | 1 - src/insets/InsetLabel.h | 2 -- src/insets/InsetLine.h | 2 -- src/insets/InsetTabular.h | 1 - src/insets/InsetText.h | 3 --- src/mathed/InsetMath.h | 1 - src/mathed/InsetMathComment.h | 2 -- src/mathed/InsetMathGrid.h | 1 - src/mathed/MacroTable.h | 1 - src/mathed/MathAtom.h | 1 - src/support/SystemcallPrivate.h | 2 -- 52 files changed, 6 insertions(+), 119 deletions(-) diff --git a/src/Buffer.h b/src/Buffer.h index e8f0aea875..8aa8478500 100644 --- a/src/Buffer.h +++ b/src/Buffer.h @@ -39,9 +39,6 @@ class FuncRequest; class FuncStatus; class Inset; class InsetLabel; -class InsetRef; -class Font; -class Format; class Lexer; class Text; class LyXVC; @@ -52,7 +49,6 @@ class MacroNameSet; class MacroSet; class OutputParams; class otexstream; -class Paragraph; class ParConstIterator; class ParIterator; class ParagraphList; diff --git a/src/BufferView.h b/src/BufferView.h index 2f6e429dd0..4a020eb3b2 100644 --- a/src/BufferView.h +++ b/src/BufferView.h @@ -37,7 +37,6 @@ class CursorSlice; class Dimension; class DispatchResult; class DocIterator; -class DocumentClass; class FuncRequest; class FuncStatus; class Intl; @@ -45,10 +44,8 @@ class Inset; class Length; class MathData; class MathRow; -class ParIterator; class ParagraphMetrics; class Point; -class Row; class TexRow; class Text; class TextMetrics; diff --git a/src/Citation.h b/src/Citation.h index 8aeb56c3e5..b7af22b751 100644 --- a/src/Citation.h +++ b/src/Citation.h @@ -18,8 +18,6 @@ namespace lyx { -class Buffer; - enum CiteEngineType { ENGINE_TYPE_AUTHORYEAR = 1, diff --git a/src/CoordCache.h b/src/CoordCache.h index 9871819c10..38842be83c 100644 --- a/src/CoordCache.h +++ b/src/CoordCache.h @@ -21,9 +21,7 @@ namespace lyx { class Inset; -class Text; class MathData; -class Paragraph; void lyxbreaker(void const * data, const char * hint, int size); diff --git a/src/CutAndPaste.h b/src/CutAndPaste.h index a6ce3fc74d..54ca4e3dfd 100644 --- a/src/CutAndPaste.h +++ b/src/CutAndPaste.h @@ -25,7 +25,6 @@ namespace lyx { -class DocumentClass; class ErrorList; class InsetText; class Cursor; diff --git a/src/LayoutFile.h b/src/LayoutFile.h index 7fcc820bbf..fe86532266 100644 --- a/src/LayoutFile.h +++ b/src/LayoutFile.h @@ -24,8 +24,6 @@ namespace lyx { -class Layout; - /// Index into LayoutFileList. Basically a 'strong typedef'. class LayoutFileIndex { public: diff --git a/src/ParIterator.h b/src/ParIterator.h index a763183838..a4e410b7e2 100644 --- a/src/ParIterator.h +++ b/src/ParIterator.h @@ -21,7 +21,6 @@ namespace lyx { class Buffer; class Inset; -class Text; class ParagraphList; diff --git a/src/Paragraph.h b/src/Paragraph.h index 597a10b764..0752dfeb0a 100644 --- a/src/Paragraph.h +++ b/src/Paragraph.h @@ -32,22 +32,16 @@ class AuthorList; class Buffer; class BufferParams; class Change; -class Counters; -class Cursor; -class CursorSlice; class DocIterator; class docstring_list; class DocumentClass; class Inset; -class InsetBibitem; class LaTeXFeatures; class InsetList; class Language; class Layout; class Font; -class MetricsInfo; class OutputParams; -class PainterInfo; class ParagraphParameters; class TocBackend; class WordLangTuple; diff --git a/src/ParagraphMetrics.h b/src/ParagraphMetrics.h index 9ddc1b0211..17d68b5ba8 100644 --- a/src/ParagraphMetrics.h +++ b/src/ParagraphMetrics.h @@ -32,14 +32,8 @@ namespace lyx { */ typedef std::vector RowList; -class Buffer; class BufferView; -class BufferParams; -class Font; -class Inset; class Paragraph; -class MetricsInfo; -class PainterInfo; /// Helper class for paragraph metrics. class ParagraphMetrics { diff --git a/src/buffer_funcs.h b/src/buffer_funcs.h index 12aa84123e..7d0bd07f84 100644 --- a/src/buffer_funcs.h +++ b/src/buffer_funcs.h @@ -19,8 +19,6 @@ namespace lyx { namespace support { class FileName; } class Buffer; -class DocIterator; -class ParIterator; /** * Checks and loads a LyX file \param filename. diff --git a/src/frontends/Application.h b/src/frontends/Application.h index 49bf68ddd0..5e3b37a7f1 100644 --- a/src/frontends/Application.h +++ b/src/frontends/Application.h @@ -25,22 +25,15 @@ namespace lyx { -class BufferView; class Buffer; class DispatchResult; class docstring_list; class FuncRequest; class FuncStatus; class Inset; -class Lexer; -struct RGBColor; namespace frontend { -class Clipboard; -class FontLoader; -class Selection; - /// The main application class /** There should be only one instance of this class. No Qt object diff --git a/src/frontends/Delegates.h b/src/frontends/Delegates.h index b5844470e1..c50df6b33f 100644 --- a/src/frontends/Delegates.h +++ b/src/frontends/Delegates.h @@ -16,7 +16,6 @@ namespace lyx { -class Buffer; class DocIterator; class Inset; diff --git a/src/frontends/WorkArea.h b/src/frontends/WorkArea.h index 743c1145a5..d6912fc7fa 100644 --- a/src/frontends/WorkArea.h +++ b/src/frontends/WorkArea.h @@ -18,9 +18,6 @@ namespace lyx { -class BufferView; -class KeySymbol; - namespace frontend { /** diff --git a/src/frontends/qt/GuiApplication.h b/src/frontends/qt/GuiApplication.h index 4e0983b134..a121b957a6 100644 --- a/src/frontends/qt/GuiApplication.h +++ b/src/frontends/qt/GuiApplication.h @@ -29,7 +29,6 @@ class QFont; namespace lyx { -class BufferView; class ColorCache; class KeySymbol; @@ -39,10 +38,11 @@ class FileName; namespace frontend { +class Clipboard; +class FontLoader; class GuiView; -class GuiWorkArea; class Menus; -class SocketNotifier; +class Selection; class Toolbars; /// The Qt main application class diff --git a/src/frontends/qt/GuiCitation.h b/src/frontends/qt/GuiCitation.h index db7ac31249..7e65fe64cb 100644 --- a/src/frontends/qt/GuiCitation.h +++ b/src/frontends/qt/GuiCitation.h @@ -31,8 +31,6 @@ namespace lyx { -class BiblioInfo; - namespace frontend { class GuiSelectionManager; diff --git a/src/frontends/qt/GuiCompleter.h b/src/frontends/qt/GuiCompleter.h index 54ea5f0559..9cf5ad96d6 100644 --- a/src/frontends/qt/GuiCompleter.h +++ b/src/frontends/qt/GuiCompleter.h @@ -20,8 +20,6 @@ namespace lyx { -class Buffer; - namespace frontend { class GuiWorkArea; diff --git a/src/frontends/qt/GuiDocument.h b/src/frontends/qt/GuiDocument.h index 2ef9d250f9..73cc4d6b8b 100644 --- a/src/frontends/qt/GuiDocument.h +++ b/src/frontends/qt/GuiDocument.h @@ -42,10 +42,8 @@ namespace lyx { -class BufferParams; class LayoutModuleList; class LyXModule; -class TextClass; namespace support { class TempFile; diff --git a/src/frontends/qt/GuiErrorList.h b/src/frontends/qt/GuiErrorList.h index 30d9e44350..bc84888253 100644 --- a/src/frontends/qt/GuiErrorList.h +++ b/src/frontends/qt/GuiErrorList.h @@ -16,8 +16,6 @@ #include "ErrorList.h" #include "ui_ErrorListUi.h" -class QListWidgetItem; - namespace lyx { namespace frontend { diff --git a/src/frontends/qt/GuiLyXFiles.h b/src/frontends/qt/GuiLyXFiles.h index 4d762fc20c..e22dafc2ef 100644 --- a/src/frontends/qt/GuiLyXFiles.h +++ b/src/frontends/qt/GuiLyXFiles.h @@ -18,12 +18,8 @@ #include -class QListWidgetItem; - namespace lyx { -class Format; - namespace frontend { class GuiLyXFiles : public GuiDialog, public Ui::LyXFilesUi diff --git a/src/frontends/qt/GuiPainter.h b/src/frontends/qt/GuiPainter.h index 22d69a7fe3..2e2a7f2ec8 100644 --- a/src/frontends/qt/GuiPainter.h +++ b/src/frontends/qt/GuiPainter.h @@ -21,8 +21,6 @@ #include #include -class QString; - namespace lyx { class FontInfo; diff --git a/src/frontends/qt/GuiPrefs.h b/src/frontends/qt/GuiPrefs.h index cb810c57f7..90cf142185 100644 --- a/src/frontends/qt/GuiPrefs.h +++ b/src/frontends/qt/GuiPrefs.h @@ -50,10 +50,6 @@ namespace lyx { -class Converters; -class Formats; -class Movers; - namespace frontend { class PrefModule; diff --git a/src/frontends/qt/GuiSelectionManager.h b/src/frontends/qt/GuiSelectionManager.h index 7a7d71d7e7..dbf93893e9 100644 --- a/src/frontends/qt/GuiSelectionManager.h +++ b/src/frontends/qt/GuiSelectionManager.h @@ -15,9 +15,7 @@ #include class QAbstractItemModel; -class QAbstractListModel; class QModelIndex; -class QListView; class QPushButton; class QVariant; class QAbstractItemView; diff --git a/src/frontends/qt/GuiSpellchecker.h b/src/frontends/qt/GuiSpellchecker.h index 79c70880f0..b113e75513 100644 --- a/src/frontends/qt/GuiSpellchecker.h +++ b/src/frontends/qt/GuiSpellchecker.h @@ -22,8 +22,6 @@ class QListWidgetItem; namespace lyx { -class docstring_list; - namespace frontend { class SpellcheckerWidget : public QTabWidget diff --git a/src/frontends/qt/GuiToc.h b/src/frontends/qt/GuiToc.h index 7e6df1db1b..7add981050 100644 --- a/src/frontends/qt/GuiToc.h +++ b/src/frontends/qt/GuiToc.h @@ -20,7 +20,6 @@ namespace lyx { namespace frontend { -class TocModel; class TocWidget; class GuiToc : public DockView diff --git a/src/frontends/qt/GuiToolbar.h b/src/frontends/qt/GuiToolbar.h index 8f4d4d927f..53f3c9a454 100644 --- a/src/frontends/qt/GuiToolbar.h +++ b/src/frontends/qt/GuiToolbar.h @@ -26,17 +26,12 @@ class QSettings; namespace lyx { -class DocumentClass; -class Inset; - namespace frontend { class Action; class GuiCommandBuffer; -class GuiLayoutFilterModel; class GuiToolbar; class GuiView; -class LayoutBox; class ToolbarInfo; class ToolbarItem; diff --git a/src/frontends/qt/GuiWorkArea.h b/src/frontends/qt/GuiWorkArea.h index d64dfe85ce..2f155bf7c1 100644 --- a/src/frontends/qt/GuiWorkArea.h +++ b/src/frontends/qt/GuiWorkArea.h @@ -22,14 +22,13 @@ #include #include -class QDragEnterEvent; -class QDropEvent; class QToolButton; class QWidget; namespace lyx { class Buffer; +class BufferView; class FuncRequest; namespace frontend { diff --git a/src/frontends/qt/GuiWorkArea_Private.h b/src/frontends/qt/GuiWorkArea_Private.h index 39130162ad..e716323916 100644 --- a/src/frontends/qt/GuiWorkArea_Private.h +++ b/src/frontends/qt/GuiWorkArea_Private.h @@ -22,8 +22,6 @@ namespace lyx { -class Buffer; - namespace frontend { class GuiCompleter; diff --git a/src/frontends/qt/LayoutBox.h b/src/frontends/qt/LayoutBox.h index 3980b6f0e6..a3d174e01a 100644 --- a/src/frontends/qt/LayoutBox.h +++ b/src/frontends/qt/LayoutBox.h @@ -22,9 +22,6 @@ namespace lyx { -class DocumentClass; -class Inset; - namespace frontend { class GuiView; diff --git a/src/frontends/qt/LyXFileDialog.h b/src/frontends/qt/LyXFileDialog.h index 60d7fd2d6d..769dc60d8c 100644 --- a/src/frontends/qt/LyXFileDialog.h +++ b/src/frontends/qt/LyXFileDialog.h @@ -16,8 +16,6 @@ #include -class QToolButton; - namespace lyx { class LyXFileDialog : public QFileDialog diff --git a/src/frontends/qt/PanelStack.h b/src/frontends/qt/PanelStack.h index 5c470aae21..220afeec79 100644 --- a/src/frontends/qt/PanelStack.h +++ b/src/frontends/qt/PanelStack.h @@ -18,10 +18,7 @@ #include #include -class QAbstractButton; class QHideEvent; -class QLineEdit; -class QPushButton; class QStackedWidget; class QTimer; class QTreeWidget; diff --git a/src/frontends/qt/TocModel.h b/src/frontends/qt/TocModel.h index ad65cdc288..b2d74a2b51 100644 --- a/src/frontends/qt/TocModel.h +++ b/src/frontends/qt/TocModel.h @@ -19,7 +19,6 @@ namespace lyx { -class Buffer; class BufferView; class DocIterator; class FuncRequest; diff --git a/src/frontends/qt/qt_helpers.h b/src/frontends/qt/qt_helpers.h index f0e535fe81..aff144b055 100644 --- a/src/frontends/qt/qt_helpers.h +++ b/src/frontends/qt/qt_helpers.h @@ -25,17 +25,13 @@ class QComboBox; class QLineEdit; -class QCheckBox; class QString; class QWidget; -template class QList; namespace lyx { namespace support { class FileName; } -class BufferParams; - namespace frontend { class LengthCombo; diff --git a/src/graphics/GraphicsCacheItem.h b/src/graphics/GraphicsCacheItem.h index 6f7f968bc6..ba5efe6b2a 100644 --- a/src/graphics/GraphicsCacheItem.h +++ b/src/graphics/GraphicsCacheItem.h @@ -40,7 +40,6 @@ namespace support { class FileName; } namespace graphics { class Image; -class Converter; /// A graphics::Cache item holder. class CacheItem { diff --git a/src/graphics/PreviewImage.h b/src/graphics/PreviewImage.h index 6b5ac7e66c..bea2553eeb 100644 --- a/src/graphics/PreviewImage.h +++ b/src/graphics/PreviewImage.h @@ -22,7 +22,6 @@ class Dimension; namespace graphics { -class Cache; class PreviewLoader; class Image; diff --git a/src/insets/ExternalTransforms.h b/src/insets/ExternalTransforms.h index e880158dc1..10c3dccd12 100644 --- a/src/insets/ExternalTransforms.h +++ b/src/insets/ExternalTransforms.h @@ -27,8 +27,6 @@ namespace lyx { -class Lexer; - namespace external { /* diff --git a/src/insets/Inset.h b/src/insets/Inset.h index 5557e25fc9..d2be340195 100644 --- a/src/insets/Inset.h +++ b/src/insets/Inset.h @@ -31,7 +31,6 @@ namespace lyx { -class BiblioInfo; class Buffer; class BufferView; class Change; @@ -59,11 +58,9 @@ class MathAtom; class MetricsInfo; class OutputParams; class PainterInfo; -class ParConstIterator; class ParIterator; class Text; class TocBackend; -class TocList; class XMLStream; class otexstream; diff --git a/src/insets/InsetBibitem.h b/src/insets/InsetBibitem.h index 6eae701f27..2a210e8c90 100644 --- a/src/insets/InsetBibitem.h +++ b/src/insets/InsetBibitem.h @@ -18,8 +18,6 @@ namespace lyx { -class BiblioInfo; - ///////////////////////////////////////////////////////////////////////// // // InsetBibItem diff --git a/src/insets/InsetBibtex.h b/src/insets/InsetBibtex.h index d82d8adab4..be7659f223 100644 --- a/src/insets/InsetBibtex.h +++ b/src/insets/InsetBibtex.h @@ -16,7 +16,6 @@ namespace lyx { -class BiblioInfo; class docstring_list; namespace support { diff --git a/src/insets/InsetCaptionable.h b/src/insets/InsetCaptionable.h index 2d5175ffd9..aa9a4cc426 100644 --- a/src/insets/InsetCaptionable.h +++ b/src/insets/InsetCaptionable.h @@ -20,6 +20,8 @@ namespace lyx { +class InsetCaption; + class InsetCaptionable : public InsetCollapsible { public: diff --git a/src/insets/InsetCollapsible.h b/src/insets/InsetCollapsible.h index f07aec09f7..55044b47de 100644 --- a/src/insets/InsetCollapsible.h +++ b/src/insets/InsetCollapsible.h @@ -27,8 +27,6 @@ class InsetLayout; namespace support { class TempFile; } -namespace frontend { class Painter; } - /** A collapsible text inset */ diff --git a/src/insets/InsetERT.h b/src/insets/InsetERT.h index 1e127fc095..72220d07d0 100644 --- a/src/insets/InsetERT.h +++ b/src/insets/InsetERT.h @@ -26,8 +26,6 @@ namespace lyx { versions of this inset. */ -class Language; - class InsetERT : public InsetCollapsible { public: /// diff --git a/src/insets/InsetInclude.h b/src/insets/InsetInclude.h index 5a9958cec8..a2542543e3 100644 --- a/src/insets/InsetInclude.h +++ b/src/insets/InsetInclude.h @@ -22,7 +22,6 @@ namespace lyx { -class BiblioInfo; class Buffer; class Dimension; class InsetCommandParams; diff --git a/src/insets/InsetLabel.h b/src/insets/InsetLabel.h index a5b9fefd82..54bfa07141 100644 --- a/src/insets/InsetLabel.h +++ b/src/insets/InsetLabel.h @@ -17,8 +17,6 @@ namespace lyx { -class Counter; - class InsetLabel : public InsetCommand { public: diff --git a/src/insets/InsetLine.h b/src/insets/InsetLine.h index a6935445f2..361fbe5d6d 100644 --- a/src/insets/InsetLine.h +++ b/src/insets/InsetLine.h @@ -20,8 +20,6 @@ namespace lyx { -class LaTeXFeatures; - class InsetLine : public InsetCommand { public: diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h index d71c25bd71..2ee107a192 100644 --- a/src/insets/InsetTabular.h +++ b/src/insets/InsetTabular.h @@ -44,7 +44,6 @@ class CursorSlice; class FuncStatus; class Lexer; class OutputParams; -class Paragraph; class XMLStream; diff --git a/src/insets/InsetText.h b/src/insets/InsetText.h index 2f32bd2539..6ce6b5af07 100644 --- a/src/insets/InsetText.h +++ b/src/insets/InsetText.h @@ -23,9 +23,6 @@ class CompletionList; class CursorSlice; class Dimension; class ParagraphList; -class InsetCaption; -class InsetTabular; -class TocBuilder; /** A text inset is like a TeX box to write full text diff --git a/src/mathed/InsetMath.h b/src/mathed/InsetMath.h index 157fcb1a9b..3eae9295a4 100644 --- a/src/mathed/InsetMath.h +++ b/src/mathed/InsetMath.h @@ -64,7 +64,6 @@ inclusion in the "real LyX insets" FormulaInset and FormulaMacroInset. */ -class Cursor; class OutputParams; class MetricsInfo; diff --git a/src/mathed/InsetMathComment.h b/src/mathed/InsetMathComment.h index e4dcf65869..0134f6cfa9 100644 --- a/src/mathed/InsetMathComment.h +++ b/src/mathed/InsetMathComment.h @@ -17,8 +17,6 @@ namespace lyx { -class latexkeys; - /// Inset for end-of-line comments class InsetMathComment : public InsetMathNest { public: diff --git a/src/mathed/InsetMathGrid.h b/src/mathed/InsetMathGrid.h index d78e0891a5..87f781aa7a 100644 --- a/src/mathed/InsetMathGrid.h +++ b/src/mathed/InsetMathGrid.h @@ -20,7 +20,6 @@ namespace lyx { -class BufferParams; class BufferView; /** Gridded math inset base class. diff --git a/src/mathed/MacroTable.h b/src/mathed/MacroTable.h index acc4004109..e83be84b75 100644 --- a/src/mathed/MacroTable.h +++ b/src/mathed/MacroTable.h @@ -26,7 +26,6 @@ namespace lyx { class Buffer; class MathData; class InsetMathMacroTemplate; -class Paragraph; class latexkeys; enum MacroType { diff --git a/src/mathed/MathAtom.h b/src/mathed/MathAtom.h index 5d20e69bbf..aa6e317f89 100644 --- a/src/mathed/MathAtom.h +++ b/src/mathed/MathAtom.h @@ -44,7 +44,6 @@ Andre' namespace lyx { -class Inset; class InsetMath; class MathAtom { diff --git a/src/support/SystemcallPrivate.h b/src/support/SystemcallPrivate.h index 6ab479f73c..19771dfc73 100644 --- a/src/support/SystemcallPrivate.h +++ b/src/support/SystemcallPrivate.h @@ -20,8 +20,6 @@ namespace lyx { namespace support { -class Systemcall; - /** * Outputs to the console terminal the line buffered standard output and * error of a spawned process when there is a controlling terminal and -- 2.39.2