minor fixes: debug message/tooltips/etc

This commit is contained in:
WandererFan
2017-01-21 09:32:06 -05:00
parent f51b5818cc
commit 1d3a8a910f
3 changed files with 5 additions and 7 deletions

View File

@@ -300,8 +300,8 @@ void GeometryObject::addGeomFromCompound(TopoDS_Shape edgeCompound, edgeClass ca
TechDraw::DrawViewDetail* detail = isParentDetail();
if (detail != nullptr) {
double scale = m_parent->Scale.getValue();
if ((circle->center == Base::Vector2d(0.0,0.0)) &&
(DrawUtil::fpCompare(circle->radius, scale * detail->getFudgeRadius()))) {
if ( ((circle->center - Base::Vector2d(0.0,0.0)).Length() < Precision::Confusion()) &&
(DrawUtil::fpCompare(circle->radius, scale * detail->getFudgeRadius())) ) {
skipDetail = true;
} else {
c1 = new TechDrawGeometry::Vertex(circle->center);
@@ -466,9 +466,9 @@ gp_Ax2 TechDrawGeometry::getViewAxis(const Base::Vector3d origin,
}
Base::Vector3d cross = flipDirection;
//special cases
if (flipDirection == stdZ) {
if ((flipDirection - stdZ).Length() < Precision::Confusion()) {
cross = Base::Vector3d(1.0,0.0,0.0);
} else if (flipDirection == (stdZ * -1.0)) {
} else if ((flipDirection - (stdZ * -1.0)).Length() < Precision::Confusion()) {
cross = Base::Vector3d(1.0,0.0,0.0);
} else {
cross.Normalize();