[TD]Add CenterLine edit function

This commit is contained in:
wandererfan
2019-06-23 13:44:29 -04:00
committed by WandererFan
parent 7ea2cca327
commit 5d601c1cdd
20 changed files with 977 additions and 570 deletions

View File

@@ -136,7 +136,6 @@ short DrawViewDetail::mustExecute() const
void DrawViewDetail::onChanged(const App::Property* prop)
{
if (!isRestoring()) {
//Base::Console().Message("TRACE - DVD::onChanged(%s) - %s\n",prop->getName(),Label.getValue());
if (prop == &Reference) {
std::string lblText = "Detail " +
std::string(Reference.getValue());
@@ -158,9 +157,6 @@ App::DocumentObjectExecReturn *DrawViewDetail::execute(void)
return App::DocumentObject::StdReturn;
}
rebuildCosmoVertex();
rebuildCosmoEdge();
App::DocumentObject* baseObj = BaseView.getValue();
if (!baseObj) {
bool isRestoring = getDocument()->testStatus(App::Document::Status::Restoring);
@@ -352,17 +348,14 @@ App::DocumentObjectExecReturn *DrawViewDetail::execute(void)
}
//add back the cosmetic vertices
for (auto& v: vertexCosmetic) {
for (auto& v: CVertexTable) {
int idx = geometryObject->addCosmeticVertex(v->point() * getScale());
v->linkGeom = idx;
}
//add the cosmetic Edges to geometry Edges list
for (auto& e: edgeCosmetic) {
TechDraw::BaseGeom* scaledGeom = e->scaledGeometry(getScale());
int idx = geometryObject->addCosmeticEdge(scaledGeom);
e->m_linkGeom = idx;
}
addCosmeticEdgesToGeom();
//add centerlines to geometry edges list
addCenterLinesToGeom();
requestPaint();
dvp->requestPaint(); //to refresh detail highlight!