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();

View File

@ -456,7 +456,7 @@ CmdTechDrawProjGroup::CmdTechDrawProjGroup()
sAppModule = "TechDraw";
sGroup = QT_TR_NOOP("TechDraw");
sMenuText = QT_TR_NOOP("Insert Projection Group");
sToolTipText = QT_TR_NOOP("Insert 2D Projections of a 3D part into the active drawing");
sToolTipText = QT_TR_NOOP("Insert multiple views of a single part into the active drawing");
sWhatsThis = "TechDraw_ProjGroup";
sStatusTip = sToolTipText;
sPixmap = "actions/techdraw-projgroup";

View File

@ -165,8 +165,6 @@ void CmdTechDrawNewCrosshatch::activated(int iMsg)
std::stringstream featLabel;
featLabel << FeatName << "FX" << TechDraw::DrawUtil::getIndexFromName(subNames.at(0));
Base::Console().Message("TRACE - cmd::newCrossHatch - %s - %s\n",featLabel.str().c_str(), FeatName.c_str());
openCommand("Create Crosshatch");
doCommand(Doc,"App.activeDocument().addObject('TechDraw::DrawCrosshatch','%s')",FeatName.c_str());
doCommand(Doc,"App.activeDocument().%s.Label = '%s'",FeatName.c_str(),featLabel.str().c_str());