Introduce *_MARK_NONFINAL_CLASS and *_MARK_NONFINAL_METHOD macroses to suppress GCC warning Wsuggest-final-types.

This commit is contained in:
Roman Telezhynskyi 2021-09-25 11:43:05 +03:00
parent d996f7335a
commit 2ffda9a073
74 changed files with 237 additions and 63 deletions

View File

@ -28,7 +28,7 @@
#include <QUrl>
#include <QtGlobal>
class FvAvailableUpdate : public QObject
class FvAvailableUpdate final : public QObject
{
Q_OBJECT
public:

View File

@ -35,7 +35,7 @@
#include "fvavailableupdate.h"
#include "fvupdatewindow.h"
class FvUpdater : public QObject
class FvUpdater final : public QObject
{
Q_OBJECT

View File

@ -39,7 +39,7 @@
/**
* @brief The VExceptionBadId class for exception bad id
*/
class VExceptionBadId : public VException
class VExceptionBadId final : public VException
{
public:
VExceptionBadId(const QString &error, const quint32 &id) V_NOEXCEPT_EXPR (true);

View File

@ -38,7 +38,7 @@
/**
* @brief The VExceptionConversionError class for exception of conversion error
*/
class VExceptionConversionError : public VException
class VExceptionConversionError final : public VException
{
public:
VExceptionConversionError(const QString &error, const QString &str) V_NOEXCEPT_EXPR (true);

View File

@ -41,7 +41,7 @@ class QDomElement;
/**
* @brief The VExceptionEmptyParameter class for exception empty parameter
*/
class VExceptionEmptyParameter : public VException
class VExceptionEmptyParameter final : public VException
{
public:
VExceptionEmptyParameter(const QString &what, const QString &name,

View File

@ -43,7 +43,7 @@
class QDomElement;
class VPatternConverter : public VAbstractConverter
class VPatternConverter final : public VAbstractConverter
{
Q_DECLARE_TR_FUNCTIONS(VPatternConverter)
public:

View File

@ -39,7 +39,7 @@
class QDomElement;
class VVITConverter : public VAbstractMConverter
class VVITConverter final : public VAbstractMConverter
{
Q_DECLARE_TR_FUNCTIONS(VVITConverter)
public:

View File

@ -39,7 +39,7 @@
class QDomElement;
class VVSTConverter : public VAbstractMConverter
class VVSTConverter final : public VAbstractMConverter
{
Q_DECLARE_TR_FUNCTIONS(VVSTConverter)
public:

View File

@ -30,7 +30,7 @@
#include "vabstractconverter.h"
class VWatermarkConverter : public VAbstractConverter
class VWatermarkConverter final : public VAbstractConverter
{
public:
explicit VWatermarkConverter(const QString &fileName);

View File

@ -113,6 +113,56 @@ QMUPARSERSHARED_EXPORT QString NameRegExp();
QT_WARNING_POP
#ifndef QMU_ATTRIBUTE_UNUSED
# if defined(Q_CC_GNU) || defined(Q_CC_CLANG)
# define QMU_ATTRIBUTE_UNUSED [[gnu::unused]]
#elif defined(Q_CC_MSVC)
# define QMU_ATTRIBUTE_UNUSED __declspec(unused)
# else
# define QMU_ATTRIBUTE_UNUSED
# endif
#endif
// Example of use
//class Base
//{
// virtual ~Base()
// {
// }
// virtual int a(float f)
// {
// }
// virtual void b(double)
// {
// }
//};
//QMU_MARK_NONFINAL_CLASS(Base)
//QMU_ATTRIBUTE_UNUSED(Base, int, a(float))
//QMU_ATTRIBUTE_UNUSED(Base, void, b(double)
#ifndef QMU_MARK_NONFINAL_CLASS
#define QMU_MARK_NONFINAL_CLASS(base) \
namespace qmu_void_namespace_for_class_##base \
{ \
struct QMU_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
}; \
}
#endif
#ifndef QMU_MARK_NONFINAL_METHOD
#define QMU_MARK_NONFINAL_METHOD(base, return_type, method) \
namespace qmu_void_namespace_for_class_##base##_methos_##method \
{ \
struct QMU_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
inline return_type QMU_ATTRIBUTE_UNUSED method override {} \
}; \
}
#endif
Q_REQUIRED_RESULT static inline bool QmuFuzzyComparePossibleNulls(double p1, double p2);
static inline bool QmuFuzzyComparePossibleNulls(double p1, double p2)
{

View File

@ -99,6 +99,8 @@ namespace qmu
static qreal Max(const qreal*, int); // maximum
};
QMU_MARK_NONFINAL_CLASS(QmuParser)
//---------------------------------------------------------------------------------------------------------------------
/**
* @brief Callback for the unary minus operator.

View File

@ -37,7 +37,7 @@ QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
namespace qmu
{
class QmuParserCallbackData : public QSharedData
class QmuParserCallbackData final : public QSharedData
{
public:
QmuParserCallbackData();

View File

@ -50,6 +50,8 @@ private:
QmuTokenParser();
};
QMU_MARK_NONFINAL_CLASS(QmuTokenParser)
} // namespace qmu
#endif // QMUTOKENPARSER_H

View File

@ -93,7 +93,7 @@ private:
};
class dx_iface : public DRW_Interface
class dx_iface final : public DRW_Interface
{
public:
dx_iface(const std::string& file, DRW::Version v, VarMeasurement varMeasurement, VarInsunits varInsunits);

View File

@ -761,7 +761,7 @@ private:
* Class to handle vertex for polyline entity
* @author Rallaz
*/
class DRW_Vertex : public DRW_Point {
class DRW_Vertex final : public DRW_Point {
SETENTFRIENDS
public:
DRW_Vertex()

View File

@ -93,7 +93,7 @@ public:
virtual bool readBool() override;
};
class dxfReaderAscii : public dxfReader {
class dxfReaderAscii final : public dxfReader {
public:
explicit dxfReaderAscii(std::istream *stream)
: dxfReader(stream)

View File

@ -56,7 +56,7 @@ public:
virtual bool writeBool(int code, bool data) override;
};
class dxfWriterAscii : public dxfWriter {
class dxfWriterAscii final : public dxfWriter {
public:
explicit dxfWriterAscii(std::ofstream *stream);
virtual ~dxfWriterAscii() = default;

View File

@ -50,7 +50,7 @@ class VLayoutPiece;
class DRW_Entity;
class dx_ifaceBlock;
class VDxfEngine : public QPaintEngine
class VDxfEngine final : public QPaintEngine
{
friend class VDxfPaintDevice;
public:

View File

@ -38,7 +38,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VAbstractCurveData : public QSharedData
class VAbstractCurveData final : public QSharedData
{
public:

View File

@ -38,7 +38,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VArcData : public QSharedData
class VArcData final : public QSharedData
{
public:
VArcData();

View File

@ -44,7 +44,7 @@
class VEllipticalArcData;
class VEllipticalArc : public VAbstractArc
class VEllipticalArc final : public VAbstractArc
{
Q_DECLARE_TR_FUNCTIONS(VEllipticalArc)
public:

View File

@ -10,7 +10,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VEllipticalArcData : public QSharedData
class VEllipticalArcData final : public QSharedData
{
public:
VEllipticalArcData ();

View File

@ -38,7 +38,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VGObjectData : public QSharedData
class VGObjectData final : public QSharedData
{
public:
VGObjectData()

View File

@ -97,6 +97,7 @@ private:
Q_DECLARE_METATYPE(VPointF)
Q_DECLARE_TYPEINFO(VPointF, Q_MOVABLE_TYPE);
V_MARK_NONFINAL_CLASS(VPointF)
QT_WARNING_POP

View File

@ -38,7 +38,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VPointFData : public QSharedData
class VPointFData final : public QSharedData
{
public:

View File

@ -40,7 +40,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VSplineData : public QSharedData
class VSplineData final : public QSharedData
{
public:
VSplineData();

View File

@ -36,7 +36,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VSplinePathData : public QSharedData
class VSplinePathData final : public QSharedData
{
public:

View File

@ -41,7 +41,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VFSplinePointData : public QSharedData
class VFSplinePointData final : public QSharedData
{
public:
@ -101,7 +101,7 @@ VFSplinePointData::~VFSplinePointData()
//--------------------------------------VSplinePointData---------------------------------------------------------------
class VSplinePointData : public QSharedData
class VSplinePointData final : public QSharedData
{
public:
VSplinePointData()

View File

@ -35,7 +35,7 @@ namespace Ui
class DialogLayoutScale;
}
class DialogLayoutScale : public QDialog
class DialogLayoutScale final : public QDialog
{
Q_OBJECT

View File

@ -354,6 +354,56 @@ if (!(cond)) \
#endif // defined(__cplusplus)
#endif // QT_VERSION < QT_VERSION_CHECK(5, 8, 0)
#ifndef V_ATTRIBUTE_UNUSED
# if defined(Q_CC_GNU) || defined(Q_CC_CLANG)
# define V_ATTRIBUTE_UNUSED [[gnu::unused]]
#elif defined(Q_CC_MSVC)
# define V_ATTRIBUTE_UNUSED __declspec(unused)
# else
# define V_ATTRIBUTE_UNUSED
# endif
#endif
// Example of use
//class Base
//{
// virtual ~Base()
// {
// }
// virtual int a(float f)
// {
// }
// virtual void b(double)
// {
// }
//};
//V_MARK_NONFINAL_CLASS(Base)
//V_ATTRIBUTE_UNUSED(Base, int, a(float))
//V_ATTRIBUTE_UNUSED(Base, void, b(double)
#ifndef V_MARK_NONFINAL_CLASS
#define V_MARK_NONFINAL_CLASS(base) \
namespace v_void_namespace_for_class_##base \
{ \
struct V_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
}; \
}
#endif
#ifndef V_MARK_NONFINAL_METHOD
#define V_MARK_NONFINAL_METHOD(base, return_type, method) \
namespace v_void_namespace_for_class_##base##_methos_##method \
{ \
struct V_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
inline return_type V_ATTRIBUTE_UNUSED method override {} \
}; \
}
#endif
bool IsOptionSet(int argc, char *argv[], const char *option);
void InitHighDpiScaling(int argc, char *argv[]);

View File

@ -50,7 +50,7 @@
class QxtCsvModelPrivate;
class QxtCsvModel : public QAbstractTableModel
class QxtCsvModel final : public QAbstractTableModel
{
Q_OBJECT
public:

View File

@ -45,7 +45,7 @@ public:
}
};
class TestVApplication : public VAbstractValApplication
class TestVApplication final : public VAbstractValApplication
{
Q_OBJECT
public:

View File

@ -49,6 +49,9 @@ class QUndoStack;
class VAbstractApplication;// use in define
class VCommonSettings;
QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Wsuggest-final-types")
class VAbstractApplication : public QApplication
{
Q_OBJECT
@ -111,6 +114,8 @@ private:
void ClearTranslation();
};
QT_WARNING_POP
//---------------------------------------------------------------------------------------------------------------------
template <typename T>
inline QString VAbstractApplication::LocaleToString(const T &value)

View File

@ -44,7 +44,7 @@ class QTextStream;
#define MAX_POINTS 512
class VObjEngine : public QPaintEngine
class VObjEngine final : public QPaintEngine
{
public:
VObjEngine();

View File

@ -52,7 +52,7 @@ protected:
VCurveAngle(const quint32 &id, const quint32 &parentId);
};
class VEllipticalArcRotation : public VCurveAngle
class VEllipticalArcRotation final : public VCurveAngle
{
public:
VEllipticalArcRotation();

View File

@ -40,7 +40,7 @@ enum class CurveCLength : qint8 { C1, C2 };
class VAbstractBezier;
class VSpline;
class VCurveCLength : public VCurveVariable
class VCurveCLength final : public VCurveVariable
{
public:
VCurveCLength();

View File

@ -40,7 +40,7 @@
class VAbstractCurve;
class VSpline;
class VCurveLength : public VCurveVariable
class VCurveLength final : public VCurveVariable
{
public:
VCurveLength();

View File

@ -40,7 +40,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
// cppcheck-suppress copyCtorAndEqOperator
class VCurveVariableData : public QSharedData
class VCurveVariableData final : public QSharedData
{
public:

View File

@ -39,7 +39,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VIncrementData : public QSharedData
class VIncrementData final : public QSharedData
{
public:

View File

@ -39,7 +39,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
// cppcheck-suppress copyCtorAndEqOperator
class VInternalVariableData : public QSharedData
class VInternalVariableData final : public QSharedData
{
public:
VInternalVariableData()

View File

@ -40,7 +40,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
// cppcheck-suppress copyCtorAndEqOperator
class VLineAngleData : public QSharedData
class VLineAngleData final : public QSharedData
{
public:

View File

@ -40,7 +40,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
// cppcheck-suppress copyCtorAndEqOperator
class VLengthLineData : public QSharedData
class VLengthLineData final : public QSharedData
{
public:

View File

@ -38,7 +38,7 @@ QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VMeasurementData : public QSharedData
class VMeasurementData final : public QSharedData
{
public:

View File

@ -39,7 +39,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
// cppcheck-suppress copyCtorAndEqOperator
class VVariableData : public QSharedData
class VVariableData final : public QSharedData
{
public:

View File

@ -64,7 +64,7 @@ QT_WARNING_DISABLE_GCC("-Weffc++")
QT_WARNING_DISABLE_INTEL(2021)
QT_WARNING_DISABLE_GCC("-Wnon-virtual-dtor")
class VContainerData : public QSharedData //-V690
class VContainerData final : public QSharedData //-V690
{
public:

View File

@ -86,6 +86,8 @@ private:
Q_DISABLE_COPY(VTextProperty)
};
VPE_MARK_NONFINAL_CLASS(VTextProperty)
}
#endif // VTEXTPROPERTY_H

View File

@ -40,7 +40,7 @@ namespace VPE
//! This property holds a QWidget and displays it, if the view supports that. If not, it will behave like an empty
//! property
class VPROPERTYEXPLORERSHARED_EXPORT VWidgetProperty : public VEmptyProperty
class VPROPERTYEXPLORERSHARED_EXPORT VWidgetProperty: public VEmptyProperty
{
public:
//! Constructor
@ -67,6 +67,8 @@ public:
VProperty* container = nullptr) const override;
};
VPE_MARK_NONFINAL_CLASS(VWidgetProperty)
}
#endif // VWIDGETROPERTY_H

View File

@ -226,6 +226,8 @@ private:
Q_DISABLE_COPY(VProperty)
};
VPE_MARK_NONFINAL_CLASS(VProperty)
}
#endif // VPROPERTY_H

View File

@ -29,4 +29,54 @@
# define VPROPERTYEXPLORERSHARED_EXPORT Q_DECL_IMPORT
#endif
#ifndef VPE_ATTRIBUTE_UNUSED
# if defined(Q_CC_GNU) || defined(Q_CC_CLANG)
# define VPE_ATTRIBUTE_UNUSED [[gnu::unused]]
#elif defined(Q_CC_MSVC)
# define VPE_ATTRIBUTE_UNUSED __declspec(unused)
# else
# define VPE_ATTRIBUTE_UNUSED
# endif
#endif
// Example of use
//class Base
//{
// virtual ~Base()
// {
// }
// virtual int a(float f)
// {
// }
// virtual void b(double)
// {
// }
//};
//VPE_MARK_NONFINAL_CLASS(Base)
//VPE_ATTRIBUTE_UNUSED(Base, int, a(float))
//VPE_ATTRIBUTE_UNUSED(Base, void, b(double)
#ifndef VPE_MARK_NONFINAL_CLASS
#define VPE_MARK_NONFINAL_CLASS(base) \
namespace vpe_void_namespace_for_class_##base \
{ \
struct VPE_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
}; \
}
#endif
#ifndef VPE_MARK_NONFINAL_METHOD
#define VPE_MARK_NONFINAL_METHOD(base, return_type, method) \
namespace vpe_void_namespace_for_class_##base##_methos_##method \
{ \
struct VPE_ATTRIBUTE_UNUSED temp_marker final : base \
{ \
inline return_type VPE_ATTRIBUTE_UNUSED method override {} \
}; \
}
#endif
#endif // VPROPERTYEXPLORER_GLOBAL_H

View File

@ -103,6 +103,8 @@ private:
Q_DISABLE_COPY(VPropertyFormView)
};
VPE_MARK_NONFINAL_CLASS(VPropertyFormView)
} // Namespace VPE
#endif // VPROPERTYFORMVIEW_H

View File

@ -169,6 +169,8 @@ private:
Q_DISABLE_COPY(VPropertyModel)
};
VPE_MARK_NONFINAL_CLASS(VPropertyModel)
}
#endif // VPROPERTYMODEL_H

View File

@ -138,6 +138,8 @@ private:
Q_DISABLE_COPY(VPropertySet)
};
VPE_MARK_NONFINAL_CLASS(VPropertySet)
}
#endif // VPROPERTYMODEL_H

View File

@ -55,7 +55,7 @@ class DialogEditWrongFormula;
*
* Don't implemant button "Apply" for this dialog!!
*/
class DialogEditWrongFormula : public QDialog
class DialogEditWrongFormula final : public QDialog
{
Q_OBJECT
public:

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogAlongLine class dialog for ToolAlongLine. Help create point and edit option.
*/
class DialogAlongLine : public DialogTool
class DialogAlongLine final : public DialogTool
{
Q_OBJECT
public:

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogBisector class dialog for ToolBisector. Help create point and edit option.
*/
class DialogBisector : public DialogTool
class DialogBisector final : public DialogTool
{
Q_OBJECT
public:

View File

@ -43,7 +43,7 @@ namespace Ui
class DialogCurveIntersectAxis;
}
class DialogCurveIntersectAxis : public DialogTool
class DialogCurveIntersectAxis final : public DialogTool
{
Q_OBJECT

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogCutArc class dialog for ToolCutArc.
*/
class DialogCutArc : public DialogTool
class DialogCutArc final : public DialogTool
{
Q_OBJECT
public:

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogCutSpline class dialog for ToolCutSpline.
*/
class DialogCutSpline : public DialogTool
class DialogCutSpline final : public DialogTool
{
Q_OBJECT
public:

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogCutSplinePath class dialog for ToolCutSplinePath.
*/
class DialogCutSplinePath : public DialogTool
class DialogCutSplinePath final : public DialogTool
{
Q_OBJECT
public:

View File

@ -46,7 +46,7 @@ namespace Ui
/**
* @brief The DialogHeight class dialog for ToolHeight. Help create point and edit option.
*/
class DialogHeight : public DialogTool
class DialogHeight final : public DialogTool
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "visline.h"
class VisToolAlongLine :public VisLine
class VisToolAlongLine final :public VisLine
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "visline.h"
class VisToolCurveIntersectAxis : public VisLine
class VisToolCurveIntersectAxis final : public VisLine
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "visline.h"
class VisToolEndLine : public VisLine
class VisToolEndLine final : public VisLine
{
Q_OBJECT
public:

View File

@ -40,7 +40,7 @@
#include "../vmisc/def.h"
#include "visline.h"
class VisToolHeight : public VisLine
class VisToolHeight final : public VisLine
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "vispath.h"
class VisToolArc : public VisPath
class VisToolArc final : public VisPath
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "vispath.h"
class VisToolArcWithLength : public VisPath
class VisToolArcWithLength final : public VisPath
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "vispath.h"
class VisToolCutArc : public VisPath
class VisToolCutArc final : public VisPath
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "vispath.h"
class VisToolCutSpline : public VisPath
class VisToolCutSpline final : public VisPath
{
Q_OBJECT
public:

View File

@ -39,7 +39,7 @@
#include "../vmisc/def.h"
#include "vispath.h"
class VisToolCutSplinePath : public VisPath
class VisToolCutSplinePath final : public VisPath
{
Q_OBJECT
public:

View File

@ -33,7 +33,7 @@
#include <QIcon>
#include <QPropertyAnimation>
class FancyTab : public QObject
class FancyTab final : public QObject
{
friend class FancyTabBar;
Q_OBJECT

View File

@ -39,7 +39,9 @@ VCurvePathItem::VCurvePathItem(QGraphicsItem *parent)
m_directionArrows(),
m_points(),
m_defaultWidth(VAbstractApplication::VApp()->Settings()->WidthMainLine())
{}
{
SCASSERT(parent != nullptr);
}
//---------------------------------------------------------------------------------------------------------------------
QPainterPath VCurvePathItem::shape() const

View File

@ -33,7 +33,7 @@
#include "../vpatterndb/floatItemData/vgrainlinedata.h"
#include "../vmisc/def.h"
class VGrainlineItem : public VPieceItem
class VGrainlineItem final : public VPieceItem
{
Q_OBJECT
public:

View File

@ -40,7 +40,7 @@ struct ParenthesisInfo
int position;
};
class VTextBlockData : public QTextBlockUserData
class VTextBlockData final : public QTextBlockUserData
{
public:
VTextBlockData();

View File

@ -48,7 +48,7 @@
* which can be dragged around, resized and rotated within the parent item. The text font
* size will be automatically updated, so that the entire text will fit into the item.
*/
class VTextGraphicsItem : public VPieceItem
class VTextGraphicsItem final : public VPieceItem
{
Q_OBJECT
public: