diff options
| author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2018-06-15 17:02:56 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marcjeanmougin@free.fr> | 2018-06-18 12:27:01 +0000 |
| commit | 004e50d84773242a000f5cadb89466bbc793e1a8 (patch) | |
| tree | 019c32e65caa08fe7cf90b521787531a7b1d2225 /src/object | |
| parent | Run clang-tidy’s modernize-use-nullptr pass. (diff) | |
| download | inkscape-004e50d84773242a000f5cadb89466bbc793e1a8.tar.gz inkscape-004e50d84773242a000f5cadb89466bbc793e1a8.zip | |
Run clang-tidy’s modernize-use-equals-default pass.
This replaces empty constructors and destructors with the default
keyword.
Diffstat (limited to 'src/object')
76 files changed, 86 insertions, 163 deletions
diff --git a/src/object/box3d-side.cpp b/src/object/box3d-side.cpp index b085b88ae..d3ea2c890 100644 --- a/src/object/box3d-side.cpp +++ b/src/object/box3d-side.cpp @@ -32,8 +32,7 @@ Box3DSide::Box3DSide() : SPPolygon() { this->front_or_rear = Box3D::FRONT; } -Box3DSide::~Box3DSide() { -} +Box3DSide::~Box3DSide() = default; void Box3DSide::build(SPDocument * document, Inkscape::XML::Node * repr) { SPPolygon::build(document, repr); diff --git a/src/object/box3d.cpp b/src/object/box3d.cpp index 08190edfd..7b5e44f65 100644 --- a/src/object/box3d.cpp +++ b/src/object/box3d.cpp @@ -53,8 +53,7 @@ SPBox3D::SPBox3D() : SPGroup() { } } -SPBox3D::~SPBox3D() { -} +SPBox3D::~SPBox3D() = default; void SPBox3D::build(SPDocument *document, Inkscape::XML::Node *repr) { SPGroup::build(document, repr); diff --git a/src/object/color-profile.cpp b/src/object/color-profile.cpp index 4b12df21b..15cdf11fe 100644 --- a/src/object/color-profile.cpp +++ b/src/object/color-profile.cpp @@ -215,8 +215,7 @@ ColorProfile::ColorProfile() : SPObject() { this->rendering_intent = Inkscape::RENDERING_INTENT_UNKNOWN; } -ColorProfile::~ColorProfile() { -} +ColorProfile::~ColorProfile() = default; bool ColorProfile::operator<(ColorProfile const &other) const { gchar *a_name_casefold = g_utf8_casefold(this->name, -1 ); @@ -1211,8 +1210,7 @@ MemProfile::MemProfile() : } MemProfile::~MemProfile() -{ -} += default; static std::vector<MemProfile> perMonitorProfiles; diff --git a/src/object/filters/blend.cpp b/src/object/filters/blend.cpp index 6137843a3..400520e5b 100644 --- a/src/object/filters/blend.cpp +++ b/src/object/filters/blend.cpp @@ -32,8 +32,7 @@ SPFeBlend::SPFeBlend() { } -SPFeBlend::~SPFeBlend() { -} +SPFeBlend::~SPFeBlend() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeBlend variables. For this to get called, diff --git a/src/object/filters/colormatrix.cpp b/src/object/filters/colormatrix.cpp index ebeab56c1..4f4498e32 100644 --- a/src/object/filters/colormatrix.cpp +++ b/src/object/filters/colormatrix.cpp @@ -29,8 +29,7 @@ SPFeColorMatrix::SPFeColorMatrix() { } -SPFeColorMatrix::~SPFeColorMatrix() { -} +SPFeColorMatrix::~SPFeColorMatrix() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeColorMatrix variables. For this to get called, diff --git a/src/object/filters/componenttransfer-funcnode.cpp b/src/object/filters/componenttransfer-funcnode.cpp index 23c8dbd96..5fb454075 100644 --- a/src/object/filters/componenttransfer-funcnode.cpp +++ b/src/object/filters/componenttransfer-funcnode.cpp @@ -31,8 +31,7 @@ SPFeFuncNode::SPFeFuncNode(SPFeFuncNode::Channel channel) slope(1), intercept(0), amplitude(1), exponent(1), offset(0), channel(channel) { } -SPFeFuncNode::~SPFeFuncNode() { -} +SPFeFuncNode::~SPFeFuncNode() = default; /** * Reads the Inkscape::XML::Node, and initializes SPDistantLight variables. For this to get called, diff --git a/src/object/filters/componenttransfer.cpp b/src/object/filters/componenttransfer.cpp index fe488ce74..b7a85fbae 100644 --- a/src/object/filters/componenttransfer.cpp +++ b/src/object/filters/componenttransfer.cpp @@ -28,8 +28,7 @@ SPFeComponentTransfer::SPFeComponentTransfer() { } -SPFeComponentTransfer::~SPFeComponentTransfer() { -} +SPFeComponentTransfer::~SPFeComponentTransfer() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeComponentTransfer variables. For this to get called, diff --git a/src/object/filters/composite.cpp b/src/object/filters/composite.cpp index 2b5cdf75e..9954cd7a1 100644 --- a/src/object/filters/composite.cpp +++ b/src/object/filters/composite.cpp @@ -32,8 +32,7 @@ SPFeComposite::SPFeComposite() { } -SPFeComposite::~SPFeComposite() { -} +SPFeComposite::~SPFeComposite() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeComposite variables. For this to get called, diff --git a/src/object/filters/convolvematrix.cpp b/src/object/filters/convolvematrix.cpp index 4f2588695..2466fe396 100644 --- a/src/object/filters/convolvematrix.cpp +++ b/src/object/filters/convolvematrix.cpp @@ -44,8 +44,7 @@ SPFeConvolveMatrix::SPFeConvolveMatrix() : SPFilterPrimitive() { this->kernelMatrixIsSet = false; } -SPFeConvolveMatrix::~SPFeConvolveMatrix() { -} +SPFeConvolveMatrix::~SPFeConvolveMatrix() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeConvolveMatrix variables. For this to get called, diff --git a/src/object/filters/diffuselighting.cpp b/src/object/filters/diffuselighting.cpp index a11ddf507..bad591a22 100644 --- a/src/object/filters/diffuselighting.cpp +++ b/src/object/filters/diffuselighting.cpp @@ -49,8 +49,7 @@ SPFeDiffuseLighting::SPFeDiffuseLighting() : SPFilterPrimitive() { this->lighting_color_set = FALSE; } -SPFeDiffuseLighting::~SPFeDiffuseLighting() { -} +SPFeDiffuseLighting::~SPFeDiffuseLighting() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeDiffuseLighting variables. For this to get called, diff --git a/src/object/filters/displacementmap.cpp b/src/object/filters/displacementmap.cpp index 7d4106648..dccd78dcd 100644 --- a/src/object/filters/displacementmap.cpp +++ b/src/object/filters/displacementmap.cpp @@ -33,8 +33,7 @@ SPFeDisplacementMap::SPFeDisplacementMap() : SPFilterPrimitive() { this->in2 = Inkscape::Filters::NR_FILTER_SLOT_NOT_SET; } -SPFeDisplacementMap::~SPFeDisplacementMap() { -} +SPFeDisplacementMap::~SPFeDisplacementMap() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeDisplacementMap variables. For this to get called, diff --git a/src/object/filters/distantlight.cpp b/src/object/filters/distantlight.cpp index bec28f66f..382cba4eb 100644 --- a/src/object/filters/distantlight.cpp +++ b/src/object/filters/distantlight.cpp @@ -32,8 +32,7 @@ SPFeDistantLight::SPFeDistantLight() : SPObject(), azimuth(0), azimuth_set(FALSE), elevation(0), elevation_set(FALSE) { } -SPFeDistantLight::~SPFeDistantLight() { -} +SPFeDistantLight::~SPFeDistantLight() = default; /** * Reads the Inkscape::XML::Node, and initializes SPDistantLight variables. For this to get called, diff --git a/src/object/filters/flood.cpp b/src/object/filters/flood.cpp index da0af4737..6b7cac482 100644 --- a/src/object/filters/flood.cpp +++ b/src/object/filters/flood.cpp @@ -32,8 +32,7 @@ SPFeFlood::SPFeFlood() : SPFilterPrimitive() { this->icc = nullptr; } -SPFeFlood::~SPFeFlood() { -} +SPFeFlood::~SPFeFlood() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeFlood variables. For this to get called, diff --git a/src/object/filters/gaussian-blur.cpp b/src/object/filters/gaussian-blur.cpp index 81addb8e1..19eb532b4 100644 --- a/src/object/filters/gaussian-blur.cpp +++ b/src/object/filters/gaussian-blur.cpp @@ -31,8 +31,7 @@ SPGaussianBlur::SPGaussianBlur() : SPFilterPrimitive() { } -SPGaussianBlur::~SPGaussianBlur() { -} +SPGaussianBlur::~SPGaussianBlur() = default; /** * Reads the Inkscape::XML::Node, and initializes SPGaussianBlur variables. For this to get called, diff --git a/src/object/filters/image.cpp b/src/object/filters/image.cpp index 25ac3024a..4b58ce464 100644 --- a/src/object/filters/image.cpp +++ b/src/object/filters/image.cpp @@ -43,8 +43,7 @@ SPFeImage::SPFeImage() : SPFilterPrimitive() { this->aspect_clip = SP_ASPECT_MEET; // Default } -SPFeImage::~SPFeImage() { -} +SPFeImage::~SPFeImage() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeImage variables. For this to get called, diff --git a/src/object/filters/merge.cpp b/src/object/filters/merge.cpp index ddd19e732..d96834d73 100644 --- a/src/object/filters/merge.cpp +++ b/src/object/filters/merge.cpp @@ -23,8 +23,7 @@ SPFeMerge::SPFeMerge() : SPFilterPrimitive() { } -SPFeMerge::~SPFeMerge() { -} +SPFeMerge::~SPFeMerge() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeMerge variables. For this to get called, diff --git a/src/object/filters/mergenode.cpp b/src/object/filters/mergenode.cpp index 04ab2af95..a6824c061 100644 --- a/src/object/filters/mergenode.cpp +++ b/src/object/filters/mergenode.cpp @@ -26,8 +26,7 @@ SPFeMergeNode::SPFeMergeNode() : SPObject(), input(Inkscape::Filters::NR_FILTER_SLOT_NOT_SET) { } -SPFeMergeNode::~SPFeMergeNode() { -} +SPFeMergeNode::~SPFeMergeNode() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeMergeNode variables. For this to get called, diff --git a/src/object/filters/morphology.cpp b/src/object/filters/morphology.cpp index 6f1006372..ee7b1eaaa 100644 --- a/src/object/filters/morphology.cpp +++ b/src/object/filters/morphology.cpp @@ -28,8 +28,7 @@ SPFeMorphology::SPFeMorphology() : SPFilterPrimitive() { this->radius.set("0"); } -SPFeMorphology::~SPFeMorphology() { -} +SPFeMorphology::~SPFeMorphology() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeMorphology variables. For this to get called, diff --git a/src/object/filters/offset.cpp b/src/object/filters/offset.cpp index ed674afbf..699a0bfb9 100644 --- a/src/object/filters/offset.cpp +++ b/src/object/filters/offset.cpp @@ -30,8 +30,7 @@ SPFeOffset::SPFeOffset() : SPFilterPrimitive() { this->dy = 0; } -SPFeOffset::~SPFeOffset() { -} +SPFeOffset::~SPFeOffset() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeOffset variables. For this to get called, diff --git a/src/object/filters/pointlight.cpp b/src/object/filters/pointlight.cpp index c12d68ceb..8c8101356 100644 --- a/src/object/filters/pointlight.cpp +++ b/src/object/filters/pointlight.cpp @@ -33,8 +33,7 @@ SPFePointLight::SPFePointLight() : SPObject(), x(0), x_set(FALSE), y(0), y_set(FALSE), z(0), z_set(FALSE) { } -SPFePointLight::~SPFePointLight() { -} +SPFePointLight::~SPFePointLight() = default; /** diff --git a/src/object/filters/sp-filter-primitive.cpp b/src/object/filters/sp-filter-primitive.cpp index 7f93754b9..f418bcb4e 100644 --- a/src/object/filters/sp-filter-primitive.cpp +++ b/src/object/filters/sp-filter-primitive.cpp @@ -48,8 +48,7 @@ SPFilterPrimitive::SPFilterPrimitive() : SPObject() { this->height.unset(SVGLength::PERCENT, 1, 0); } -SPFilterPrimitive::~SPFilterPrimitive() { -} +SPFilterPrimitive::~SPFilterPrimitive() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFilterPrimitive variables. For this to get called, diff --git a/src/object/filters/specularlighting.cpp b/src/object/filters/specularlighting.cpp index 3e66d6f95..81b574fdd 100644 --- a/src/object/filters/specularlighting.cpp +++ b/src/object/filters/specularlighting.cpp @@ -53,8 +53,7 @@ SPFeSpecularLighting::SPFeSpecularLighting() : SPFilterPrimitive() { this->lighting_color_set = FALSE; } -SPFeSpecularLighting::~SPFeSpecularLighting() { -} +SPFeSpecularLighting::~SPFeSpecularLighting() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeSpecularLighting variables. For this to get called, diff --git a/src/object/filters/spotlight.cpp b/src/object/filters/spotlight.cpp index 239391478..9d911047a 100644 --- a/src/object/filters/spotlight.cpp +++ b/src/object/filters/spotlight.cpp @@ -33,8 +33,7 @@ SPFeSpotLight::SPFeSpotLight() { } -SPFeSpotLight::~SPFeSpotLight() { -} +SPFeSpotLight::~SPFeSpotLight() = default; /** diff --git a/src/object/filters/tile.cpp b/src/object/filters/tile.cpp index f36c5a758..da17fa004 100644 --- a/src/object/filters/tile.cpp +++ b/src/object/filters/tile.cpp @@ -25,8 +25,7 @@ SPFeTile::SPFeTile() : SPFilterPrimitive() { } -SPFeTile::~SPFeTile() { -} +SPFeTile::~SPFeTile() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeTile variables. For this to get called, diff --git a/src/object/filters/turbulence.cpp b/src/object/filters/turbulence.cpp index 657e44d6a..b626b2380 100644 --- a/src/object/filters/turbulence.cpp +++ b/src/object/filters/turbulence.cpp @@ -31,8 +31,7 @@ SPFeTurbulence::SPFeTurbulence() : SPFilterPrimitive() { this->updated=false; } -SPFeTurbulence::~SPFeTurbulence() { -} +SPFeTurbulence::~SPFeTurbulence() = default; /** * Reads the Inkscape::XML::Node, and initializes SPFeTurbulence variables. For this to get called, diff --git a/src/object/persp3d.cpp b/src/object/persp3d.cpp index 8020d0221..2183b6236 100644 --- a/src/object/persp3d.cpp +++ b/src/object/persp3d.cpp @@ -57,8 +57,7 @@ Persp3D::Persp3D() : SPObject() { this->perspective_impl = new Persp3DImpl(); } -Persp3D::~Persp3D() { -} +Persp3D::~Persp3D() = default; /** diff --git a/src/object/sp-anchor.cpp b/src/object/sp-anchor.cpp index 3baa7b7ca..4af737125 100644 --- a/src/object/sp-anchor.cpp +++ b/src/object/sp-anchor.cpp @@ -29,8 +29,7 @@ SPAnchor::SPAnchor() : SPGroup() { this->page = nullptr; } -SPAnchor::~SPAnchor() { -} +SPAnchor::~SPAnchor() = default; void SPAnchor::build(SPDocument *document, Inkscape::XML::Node *repr) { SPGroup::build(document, repr); diff --git a/src/object/sp-clippath.cpp b/src/object/sp-clippath.cpp index 3ef849c14..321f6a80f 100644 --- a/src/object/sp-clippath.cpp +++ b/src/object/sp-clippath.cpp @@ -48,8 +48,7 @@ SPClipPath::SPClipPath() : SPObjectGroup() { this->display = nullptr; } -SPClipPath::~SPClipPath() { -} +SPClipPath::~SPClipPath() = default; void SPClipPath::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObjectGroup::build(doc, repr); diff --git a/src/object/sp-defs.cpp b/src/object/sp-defs.cpp index 4fb3e6688..ea507fe87 100644 --- a/src/object/sp-defs.cpp +++ b/src/object/sp-defs.cpp @@ -23,8 +23,7 @@ SPDefs::SPDefs() : SPObject() { } -SPDefs::~SPDefs() { -} +SPDefs::~SPDefs() = default; void SPDefs::release() { SPObject::release(); diff --git a/src/object/sp-desc.cpp b/src/object/sp-desc.cpp index 3c75d087a..08a08bb95 100644 --- a/src/object/sp-desc.cpp +++ b/src/object/sp-desc.cpp @@ -15,8 +15,7 @@ SPDesc::SPDesc() : SPObject() { } -SPDesc::~SPDesc() { -} +SPDesc::~SPDesc() = default; /** * Writes it's settings to an incoming repr object, if any. diff --git a/src/object/sp-ellipse.cpp b/src/object/sp-ellipse.cpp index f30a06ca1..7856429e3 100644 --- a/src/object/sp-ellipse.cpp +++ b/src/object/sp-ellipse.cpp @@ -48,8 +48,7 @@ SPGenericEllipse::SPGenericEllipse() } SPGenericEllipse::~SPGenericEllipse() -{ -} += default; void SPGenericEllipse::build(SPDocument *document, Inkscape::XML::Node *repr) { diff --git a/src/object/sp-filter.cpp b/src/object/sp-filter.cpp index a77ef9e24..5668061ba 100644 --- a/src/object/sp-filter.cpp +++ b/src/object/sp-filter.cpp @@ -59,8 +59,7 @@ SPFilter::SPFilter() this->_image_name->clear(); } -SPFilter::~SPFilter() { -} +SPFilter::~SPFilter() = default; /** diff --git a/src/object/sp-flowdiv.cpp b/src/object/sp-flowdiv.cpp index d79ff349d..b4e32d295 100644 --- a/src/object/sp-flowdiv.cpp +++ b/src/object/sp-flowdiv.cpp @@ -9,8 +9,7 @@ SPFlowdiv::SPFlowdiv() : SPItem() { } -SPFlowdiv::~SPFlowdiv() { -} +SPFlowdiv::~SPFlowdiv() = default; void SPFlowdiv::release() { SPItem::release(); @@ -137,8 +136,7 @@ Inkscape::XML::Node* SPFlowdiv::write(Inkscape::XML::Document *xml_doc, Inkscape SPFlowtspan::SPFlowtspan() : SPItem() { } -SPFlowtspan::~SPFlowtspan() { -} +SPFlowtspan::~SPFlowtspan() = default; void SPFlowtspan::release() { SPItem::release(); @@ -259,8 +257,7 @@ Inkscape::XML::Node *SPFlowtspan::write(Inkscape::XML::Document *xml_doc, Inksca SPFlowpara::SPFlowpara() : SPItem() { } -SPFlowpara::~SPFlowpara() { -} +SPFlowpara::~SPFlowpara() = default; void SPFlowpara::release() { SPItem::release(); @@ -384,8 +381,7 @@ Inkscape::XML::Node *SPFlowpara::write(Inkscape::XML::Document *xml_doc, Inkscap SPFlowline::SPFlowline() : SPObject() { } -SPFlowline::~SPFlowline() { -} +SPFlowline::~SPFlowline() = default; void SPFlowline::release() { SPObject::release(); @@ -421,8 +417,7 @@ Inkscape::XML::Node *SPFlowline::write(Inkscape::XML::Document *xml_doc, Inkscap SPFlowregionbreak::SPFlowregionbreak() : SPObject() { } -SPFlowregionbreak::~SPFlowregionbreak() { -} +SPFlowregionbreak::~SPFlowregionbreak() = default; void SPFlowregionbreak::release() { SPObject::release(); diff --git a/src/object/sp-flowtext.cpp b/src/object/sp-flowtext.cpp index 3811f4072..334282103 100644 --- a/src/object/sp-flowtext.cpp +++ b/src/object/sp-flowtext.cpp @@ -39,8 +39,7 @@ SPFlowtext::SPFlowtext() : SPItem(), { } -SPFlowtext::~SPFlowtext() { -} +SPFlowtext::~SPFlowtext() = default; void SPFlowtext::child_added(Inkscape::XML::Node* child, Inkscape::XML::Node* ref) { SPItem::child_added(child, ref); diff --git a/src/object/sp-font-face.cpp b/src/object/sp-font-face.cpp index 754956058..a60dd6110 100644 --- a/src/object/sp-font-face.cpp +++ b/src/object/sp-font-face.cpp @@ -311,8 +311,7 @@ SPFontFace::SPFontFace() : SPObject() { this->overline_thickness = 0; } -SPFontFace::~SPFontFace() { -} +SPFontFace::~SPFontFace() = default; void SPFontFace::build(SPDocument *document, Inkscape::XML::Node *repr) { SPObject::build(document, repr); diff --git a/src/object/sp-font.cpp b/src/object/sp-font.cpp index 4701e8690..6736da200 100644 --- a/src/object/sp-font.cpp +++ b/src/object/sp-font.cpp @@ -38,8 +38,7 @@ SPFont::SPFont() : SPObject() { this->vert_adv_y = FNT_UNITS_PER_EM; } -SPFont::~SPFont() { -} +SPFont::~SPFont() = default; void SPFont::build(SPDocument *document, Inkscape::XML::Node *repr) { SPObject::build(document, repr); diff --git a/src/object/sp-glyph-kerning.h b/src/object/sp-glyph-kerning.h index 10624f17d..0fca561e2 100644 --- a/src/object/sp-glyph-kerning.h +++ b/src/object/sp-glyph-kerning.h @@ -35,7 +35,7 @@ private: class SPGlyphKerning : public SPObject { public: SPGlyphKerning(); - ~SPGlyphKerning() override {} + ~SPGlyphKerning() override = default; // FIXME encapsulation UnicodeRange* u1; @@ -53,11 +53,11 @@ protected: }; class SPHkern : public SPGlyphKerning { - ~SPHkern() override {} + ~SPHkern() override = default; }; class SPVkern : public SPGlyphKerning { - ~SPVkern() override {} + ~SPVkern() override = default; }; #endif // !SEEN_SP_GLYPH_KERNING_H diff --git a/src/object/sp-glyph.h b/src/object/sp-glyph.h index 49c644b21..17a34a664 100644 --- a/src/object/sp-glyph.h +++ b/src/object/sp-glyph.h @@ -35,7 +35,7 @@ enum glyphOrientation { class SPGlyph : public SPObject { public: SPGlyph(); - ~SPGlyph() override {} + ~SPGlyph() override = default; // FIXME encapsulation Glib::ustring unicode; diff --git a/src/object/sp-gradient.cpp b/src/object/sp-gradient.cpp index 0dfee1385..1fed2a206 100644 --- a/src/object/sp-gradient.cpp +++ b/src/object/sp-gradient.cpp @@ -257,8 +257,7 @@ SPGradient::SPGradient() : SPPaintServer(), units(), this->vector.stops.clear(); } -SPGradient::~SPGradient() { -} +SPGradient::~SPGradient() = default; /** * Virtual build: set gradient attributes from its associated repr. diff --git a/src/object/sp-guide.h b/src/object/sp-guide.h index 3ce3cc3de..0d9b8afc2 100644 --- a/src/object/sp-guide.h +++ b/src/object/sp-guide.h @@ -35,7 +35,7 @@ struct SPGuideLine; class SPGuide : public SPObject { public: SPGuide(); - ~SPGuide() override {} + ~SPGuide() override = default; void set_color(const unsigned r, const unsigned g, const unsigned b, bool const commit); void setColor(guint32 c); diff --git a/src/object/sp-hatch-path.cpp b/src/object/sp-hatch-path.cpp index 649fefe94..25d6face1 100644 --- a/src/object/sp-hatch-path.cpp +++ b/src/object/sp-hatch-path.cpp @@ -39,8 +39,7 @@ SPHatchPath::SPHatchPath() } SPHatchPath::~SPHatchPath() -{ -} += default; void SPHatchPath::setCurve(SPCurve *new_curve, bool owner) { diff --git a/src/object/sp-hatch.cpp b/src/object/sp-hatch.cpp index 0675c66ac..92da7dd69 100644 --- a/src/object/sp-hatch.cpp +++ b/src/object/sp-hatch.cpp @@ -58,8 +58,7 @@ SPHatch::SPHatch() _rotate.unset(); } -SPHatch::~SPHatch() { -} +SPHatch::~SPHatch() = default; void SPHatch::build(SPDocument* doc, Inkscape::XML::Node* repr) { @@ -721,8 +720,7 @@ SPHatch::RenderInfo::RenderInfo() } SPHatch::RenderInfo::~RenderInfo() -{ -} += default; // diff --git a/src/object/sp-image.cpp b/src/object/sp-image.cpp index 18e8b6674..a1efef51d 100644 --- a/src/object/sp-image.cpp +++ b/src/object/sp-image.cpp @@ -127,8 +127,7 @@ SPImage::SPImage() : SPItem(), SPViewBox() { this->pixbuf = nullptr; } -SPImage::~SPImage() { -} +SPImage::~SPImage() = default; void SPImage::build(SPDocument *document, Inkscape::XML::Node *repr) { SPItem::build(document, repr); diff --git a/src/object/sp-item-group.cpp b/src/object/sp-item-group.cpp index 735248248..f0ff9e4fc 100644 --- a/src/object/sp-item-group.cpp +++ b/src/object/sp-item-group.cpp @@ -67,8 +67,7 @@ SPGroup::SPGroup() : SPLPEItem(), { } -SPGroup::~SPGroup() { -} +SPGroup::~SPGroup() = default; void SPGroup::build(SPDocument *document, Inkscape::XML::Node *repr) { this->readAttr( "inkscape:groupmode" ); diff --git a/src/object/sp-item.cpp b/src/object/sp-item.cpp index 4d9b4d7bf..6e4a163dc 100644 --- a/src/object/sp-item.cpp +++ b/src/object/sp-item.cpp @@ -102,8 +102,7 @@ SPItem::SPItem() : SPObject() { avoidRef = new SPAvoidRef(this); } -SPItem::~SPItem() { -} +SPItem::~SPItem() = default; bool SPItem::isVisibleAndUnlocked() const { return (!isHidden() && !isLocked()); diff --git a/src/object/sp-line.cpp b/src/object/sp-line.cpp index 2ba633972..2f06ddeef 100644 --- a/src/object/sp-line.cpp +++ b/src/object/sp-line.cpp @@ -27,8 +27,7 @@ SPLine::SPLine() : SPShape() { this->y2.unset(); } -SPLine::~SPLine() { -} +SPLine::~SPLine() = default; void SPLine::build(SPDocument * document, Inkscape::XML::Node * repr) { SPShape::build(document, repr); diff --git a/src/object/sp-linear-gradient.cpp b/src/object/sp-linear-gradient.cpp index 29579b617..5e0100251 100644 --- a/src/object/sp-linear-gradient.cpp +++ b/src/object/sp-linear-gradient.cpp @@ -15,8 +15,7 @@ SPLinearGradient::SPLinearGradient() : SPGradient() { this->y2.unset(SVGLength::PERCENT, 0.0, 0.0); } -SPLinearGradient::~SPLinearGradient() { -} +SPLinearGradient::~SPLinearGradient() = default; void SPLinearGradient::build(SPDocument *document, Inkscape::XML::Node *repr) { SPGradient::build(document, repr); diff --git a/src/object/sp-lpe-item.cpp b/src/object/sp-lpe-item.cpp index 9f81b0307..785644437 100644 --- a/src/object/sp-lpe-item.cpp +++ b/src/object/sp-lpe-item.cpp @@ -66,8 +66,7 @@ SPLPEItem::SPLPEItem() { } -SPLPEItem::~SPLPEItem() { -} +SPLPEItem::~SPLPEItem() = default; void SPLPEItem::build(SPDocument *document, Inkscape::XML::Node *repr) { this->readAttr( "inkscape:path-effect" ); diff --git a/src/object/sp-marker.cpp b/src/object/sp-marker.cpp index 851a7d54f..3a504db90 100644 --- a/src/object/sp-marker.cpp +++ b/src/object/sp-marker.cpp @@ -34,7 +34,7 @@ class SPMarkerView { public: - SPMarkerView() {}; + SPMarkerView() = default;; ~SPMarkerView() { for (unsigned int i = 0; i < items.size(); ++i) { delete items[i]; @@ -63,8 +63,7 @@ SPMarker::SPMarker() : SPGroup(), SPViewBox(), * not set and initializes the marker's c2p identity matrix. */ -SPMarker::~SPMarker() { -} +SPMarker::~SPMarker() = default; /** * Virtual build callback for SPMarker. diff --git a/src/object/sp-mask.cpp b/src/object/sp-mask.cpp index 5e6ed29f0..0d225d80a 100644 --- a/src/object/sp-mask.cpp +++ b/src/object/sp-mask.cpp @@ -50,8 +50,7 @@ SPMask::SPMask() : SPObjectGroup() { this->display = nullptr; } -SPMask::~SPMask() { -} +SPMask::~SPMask() = default; void SPMask::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObjectGroup::build(doc, repr); diff --git a/src/object/sp-mesh-patch.cpp b/src/object/sp-mesh-patch.cpp index 1110e15ca..15149b689 100644 --- a/src/object/sp-mesh-patch.cpp +++ b/src/object/sp-mesh-patch.cpp @@ -61,8 +61,7 @@ SPMeshpatch::SPMeshpatch() : SPObject() { this->tensor_string = nullptr; } -SPMeshpatch::~SPMeshpatch() { -} +SPMeshpatch::~SPMeshpatch() = default; void SPMeshpatch::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObject::build(doc, repr); diff --git a/src/object/sp-mesh-row.cpp b/src/object/sp-mesh-row.cpp index 03d71c6f5..52e3b326e 100644 --- a/src/object/sp-mesh-row.cpp +++ b/src/object/sp-mesh-row.cpp @@ -58,8 +58,7 @@ SPMeshrow* SPMeshrow::getPrevMeshrow() SPMeshrow::SPMeshrow() : SPObject() { } -SPMeshrow::~SPMeshrow() { -} +SPMeshrow::~SPMeshrow() = default; void SPMeshrow::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObject::build(doc, repr); diff --git a/src/object/sp-metadata.cpp b/src/object/sp-metadata.cpp index 04cddbb8b..39f42d3ff 100644 --- a/src/object/sp-metadata.cpp +++ b/src/object/sp-metadata.cpp @@ -36,8 +36,7 @@ SPMetadata::SPMetadata() : SPObject() { } -SPMetadata::~SPMetadata() { -} +SPMetadata::~SPMetadata() = default; namespace { diff --git a/src/object/sp-missing-glyph.cpp b/src/object/sp-missing-glyph.cpp index 7b10b4e9a..d3da6ccff 100644 --- a/src/object/sp-missing-glyph.cpp +++ b/src/object/sp-missing-glyph.cpp @@ -28,8 +28,7 @@ SPMissingGlyph::SPMissingGlyph() : SPObject() { this->vert_adv_y = 0; } -SPMissingGlyph::~SPMissingGlyph() { -} +SPMissingGlyph::~SPMissingGlyph() = default; void SPMissingGlyph::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObject::build(doc, repr); diff --git a/src/object/sp-namedview.cpp b/src/object/sp-namedview.cpp index a384c23c9..0028939d3 100644 --- a/src/object/sp-namedview.cpp +++ b/src/object/sp-namedview.cpp @@ -96,8 +96,7 @@ SPNamedView::SPNamedView() : SPObjectGroup(), snap_manager(this) { this->connector_spacing = defaultConnSpacing; } -SPNamedView::~SPNamedView() { -} +SPNamedView::~SPNamedView() = default; static void sp_namedview_generate_old_grid(SPNamedView * /*nv*/, SPDocument *document, Inkscape::XML::Node *repr) { bool old_grid_settings_present = false; diff --git a/src/object/sp-object-group.cpp b/src/object/sp-object-group.cpp index 102eafa83..422e20da4 100644 --- a/src/object/sp-object-group.cpp +++ b/src/object/sp-object-group.cpp @@ -19,8 +19,7 @@ SPObjectGroup::SPObjectGroup() : SPObject() { } -SPObjectGroup::~SPObjectGroup() { -} +SPObjectGroup::~SPObjectGroup() = default; void SPObjectGroup::child_added(Inkscape::XML::Node *child, Inkscape::XML::Node *ref) { SPObject::child_added(child, ref); diff --git a/src/object/sp-paint-server.cpp b/src/object/sp-paint-server.cpp index 3e685ad24..79e60d116 100644 --- a/src/object/sp-paint-server.cpp +++ b/src/object/sp-paint-server.cpp @@ -33,8 +33,7 @@ SPPaintServer::SPPaintServer() : SPObject() { this->swatch = 0; } -SPPaintServer::~SPPaintServer() { -} +SPPaintServer::~SPPaintServer() = default; bool SPPaintServer::isSwatch() const { diff --git a/src/object/sp-path.cpp b/src/object/sp-path.cpp index 51fa549e7..44070b6a3 100644 --- a/src/object/sp-path.cpp +++ b/src/object/sp-path.cpp @@ -112,8 +112,7 @@ void SPPath::convert_to_guides() const { SPPath::SPPath() : SPShape(), connEndPair(this) { } -SPPath::~SPPath() { -} +SPPath::~SPPath() = default; void SPPath::build(SPDocument *document, Inkscape::XML::Node *repr) { /* Are these calls actually necessary? */ diff --git a/src/object/sp-pattern.cpp b/src/object/sp-pattern.cpp index 911f0873a..d2167c297 100644 --- a/src/object/sp-pattern.cpp +++ b/src/object/sp-pattern.cpp @@ -60,7 +60,7 @@ SPPattern::SPPattern() this->_height.unset(); } -SPPattern::~SPPattern() {} +SPPattern::~SPPattern() = default; void SPPattern::build(SPDocument *doc, Inkscape::XML::Node *repr) { diff --git a/src/object/sp-polygon.cpp b/src/object/sp-polygon.cpp index 90bc0c731..205120cfa 100644 --- a/src/object/sp-polygon.cpp +++ b/src/object/sp-polygon.cpp @@ -24,8 +24,7 @@ SPPolygon::SPPolygon() : SPShape() { } -SPPolygon::~SPPolygon() { -} +SPPolygon::~SPPolygon() = default; void SPPolygon::build(SPDocument *document, Inkscape::XML::Node *repr) { SPPolygon* object = this; diff --git a/src/object/sp-polyline.cpp b/src/object/sp-polyline.cpp index aa8dab7e2..083cb3066 100644 --- a/src/object/sp-polyline.cpp +++ b/src/object/sp-polyline.cpp @@ -21,8 +21,7 @@ SPPolyLine::SPPolyLine() : SPShape() { } -SPPolyLine::~SPPolyLine() { -} +SPPolyLine::~SPPolyLine() = default; void SPPolyLine::build(SPDocument * document, Inkscape::XML::Node * repr) { SPShape::build(document, repr); diff --git a/src/object/sp-radial-gradient.cpp b/src/object/sp-radial-gradient.cpp index fa6355478..4f776d334 100644 --- a/src/object/sp-radial-gradient.cpp +++ b/src/object/sp-radial-gradient.cpp @@ -19,8 +19,7 @@ SPRadialGradient::SPRadialGradient() : SPGradient() { this->fr.unset(SVGLength::PERCENT, 0.5, 0.5); } -SPRadialGradient::~SPRadialGradient() { -} +SPRadialGradient::~SPRadialGradient() = default; /** * Set radial gradient attributes from associated repr. diff --git a/src/object/sp-rect.cpp b/src/object/sp-rect.cpp index 783ad309a..e3c5bf450 100644 --- a/src/object/sp-rect.cpp +++ b/src/object/sp-rect.cpp @@ -33,8 +33,7 @@ SPRect::SPRect() : SPShape() { } -SPRect::~SPRect() { -} +SPRect::~SPRect() = default; void SPRect::build(SPDocument* doc, Inkscape::XML::Node* repr) { #ifdef OBJECT_TRACE diff --git a/src/object/sp-root.cpp b/src/object/sp-root.cpp index d1c4b4d35..592aae443 100644 --- a/src/object/sp-root.cpp +++ b/src/object/sp-root.cpp @@ -48,8 +48,7 @@ SPRoot::SPRoot() : SPGroup(), SPViewBox() } SPRoot::~SPRoot() -{ -} += default; void SPRoot::unset_x_and_y() { diff --git a/src/object/sp-script.cpp b/src/object/sp-script.cpp index 45cf25bbf..e60789eb0 100644 --- a/src/object/sp-script.cpp +++ b/src/object/sp-script.cpp @@ -18,8 +18,7 @@ SPScript::SPScript() : SPObject() { this->xlinkhref = nullptr; } -SPScript::~SPScript() { -} +SPScript::~SPScript() = default; void SPScript::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObject::build(doc, repr); diff --git a/src/object/sp-solid-color.cpp b/src/object/sp-solid-color.cpp index 89858c18c..f8694d7c6 100644 --- a/src/object/sp-solid-color.cpp +++ b/src/object/sp-solid-color.cpp @@ -22,8 +22,7 @@ SPSolidColor::SPSolidColor() : SPPaintServer() { } -SPSolidColor::~SPSolidColor() { -} +SPSolidColor::~SPSolidColor() = default; void SPSolidColor::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPPaintServer::build(doc, repr); diff --git a/src/object/sp-spiral.cpp b/src/object/sp-spiral.cpp index 37e68d7c2..442580888 100644 --- a/src/object/sp-spiral.cpp +++ b/src/object/sp-spiral.cpp @@ -38,8 +38,7 @@ SPSpiral::SPSpiral() { } -SPSpiral::~SPSpiral() { -} +SPSpiral::~SPSpiral() = default; void SPSpiral::build(SPDocument * document, Inkscape::XML::Node * repr) { SPShape::build(document, repr); diff --git a/src/object/sp-star.cpp b/src/object/sp-star.cpp index fdb85e392..1375bcecb 100644 --- a/src/object/sp-star.cpp +++ b/src/object/sp-star.cpp @@ -43,8 +43,7 @@ SPStar::SPStar() : SPPolygon() , this->arg[0] = this->arg[1] = 0.0; } -SPStar::~SPStar() { -} +SPStar::~SPStar() = default; void SPStar::build(SPDocument * document, Inkscape::XML::Node * repr) { // CPPIFY: see header file diff --git a/src/object/sp-stop.cpp b/src/object/sp-stop.cpp index d016e6366..197bc519f 100644 --- a/src/object/sp-stop.cpp +++ b/src/object/sp-stop.cpp @@ -32,8 +32,7 @@ SPStop::SPStop() : SPObject() { this->opacity = 1.0; } -SPStop::~SPStop() { -} +SPStop::~SPStop() = default; void SPStop::build(SPDocument* doc, Inkscape::XML::Node* repr) { SPObject::build(doc, repr); diff --git a/src/object/sp-string.cpp b/src/object/sp-string.cpp index a01b05e8f..cadc4091c 100644 --- a/src/object/sp-string.cpp +++ b/src/object/sp-string.cpp @@ -36,8 +36,7 @@ SPString::SPString() : SPObject() { // style = nullptr; } -SPString::~SPString() { -} +SPString::~SPString() = default; void SPString::build(SPDocument *doc, Inkscape::XML::Node *repr) { diff --git a/src/object/sp-style-elem.cpp b/src/object/sp-style-elem.cpp index c273c844f..7ccea3ea4 100644 --- a/src/object/sp-style-elem.cpp +++ b/src/object/sp-style-elem.cpp @@ -22,8 +22,7 @@ SPStyleElem::SPStyleElem() : SPObject() { this->is_css = false; } -SPStyleElem::~SPStyleElem() { -} +SPStyleElem::~SPStyleElem() = default; void SPStyleElem::set(unsigned int key, const gchar* value) { switch (key) { diff --git a/src/object/sp-symbol.cpp b/src/object/sp-symbol.cpp index 07e6f660e..d3a06a60b 100644 --- a/src/object/sp-symbol.cpp +++ b/src/object/sp-symbol.cpp @@ -28,8 +28,7 @@ SPSymbol::SPSymbol() : SPGroup(), SPViewBox() { } -SPSymbol::~SPSymbol() { -} +SPSymbol::~SPSymbol() = default; void SPSymbol::build(SPDocument *document, Inkscape::XML::Node *repr) { this->readAttr( "viewBox" ); diff --git a/src/object/sp-tag.h b/src/object/sp-tag.h index cb06ab2cb..1a1c737d8 100644 --- a/src/object/sp-tag.h +++ b/src/object/sp-tag.h @@ -23,8 +23,8 @@ class SPTag; class SPTag : public SPObject { public: - SPTag() {} - ~SPTag() override {} + SPTag() = default; + ~SPTag() override = default; void build(SPDocument * doc, Inkscape::XML::Node *repr) override; //virtual void release(); diff --git a/src/object/sp-text.cpp b/src/object/sp-text.cpp index bd0df6381..245330720 100644 --- a/src/object/sp-text.cpp +++ b/src/object/sp-text.cpp @@ -61,8 +61,7 @@ SPText::SPText() : SPItem() { } -SPText::~SPText() { -} +SPText::~SPText() = default; void SPText::build(SPDocument *doc, Inkscape::XML::Node *repr) { this->readAttr( "x" ); diff --git a/src/object/sp-title.cpp b/src/object/sp-title.cpp index ba5ae754a..b9e966797 100644 --- a/src/object/sp-title.cpp +++ b/src/object/sp-title.cpp @@ -15,8 +15,7 @@ SPTitle::SPTitle() : SPObject() { } -SPTitle::~SPTitle() { -} +SPTitle::~SPTitle() = default; Inkscape::XML::Node* SPTitle::write(Inkscape::XML::Document *xml_doc, Inkscape::XML::Node *repr, guint flags) { SPTitle* object = this; diff --git a/src/object/sp-tspan.cpp b/src/object/sp-tspan.cpp index 4df068c98..25f9e6764 100644 --- a/src/object/sp-tspan.cpp +++ b/src/object/sp-tspan.cpp @@ -55,8 +55,7 @@ SPTSpan::SPTSpan() : SPItem() { this->role = SP_TSPAN_ROLE_UNSPECIFIED; } -SPTSpan::~SPTSpan() { -} +SPTSpan::~SPTSpan() = default; void SPTSpan::build(SPDocument *doc, Inkscape::XML::Node *repr) { this->readAttr( "x" ); |
