MCPcopy Create free account
hub / github.com/KDE/labplot / duplicate

Method duplicate

src/backend/core/AbstractAspect.cpp:768–773  ·  view source on GitHub ↗

! * duplicates the aspect in the project hierarchy, the copy of the duplicated aspect is * added below the current aspect at the same level in the hierarchy. */

Source from the content-addressed store, hash-verified

766 * added below the current aspect at the same level in the hierarchy.
767 */
768void AbstractAspect::duplicate() {
769 copy();
770 auto* parent = parentAspect();
771 const int index = parent->indexOfChild<AbstractAspect>(this, ChildIndexFlag::IncludeHidden) + 1;
772 parent->paste(true, index);
773}
774
775/*!
776 * in case the clipboard containts a LabPlot's specific copy&paste content,

Callers 9

testKDEPlotDuplicateMethod · 0.80
testQQPlotDuplicateMethod · 0.80
testBarPlotDuplicateMethod · 0.80
testPBChartDuplicateMethod · 0.80
testRunChartDuplicateMethod · 0.80

Calls 1

pasteMethod · 0.80

Tested by

no test coverage detected