C++ (Qt)int Nightcharts::addPiece(QString name,Qt::GlobalColor color,float Percentage){ pieceNC *piece = new pieceNC; ... pieces.append(*piece);}