--- a/src/linetypes/triangle.cpp Mon Sep 27 21:04:45 2021 +0300 +++ b/src/linetypes/triangle.cpp Tue Sep 28 00:10:29 2021 +0300 @@ -32,3 +32,13 @@ { return Type::Triangle; } + +QString ldraw::Triangle::toLDrawCode() const +{ + return utility::format( + "3 %1 %2 %3 %4", + this->colorIndex.index, + utility::vertexToString(this->points[0]), + utility::vertexToString(this->points[1]), + utility::vertexToString(this->points[2])); +}