std::shared_ptr<GeomAPI_Dir> aSketchDir = aPlanarEdges->norm();\r
if(aDirEdge->isLine()) {\r
std::shared_ptr<GeomAPI_Dir> aDir = aDirEdge->line()->direction();\r
- isParallel = abs(aSketchDir->angle(aDir) - M_PI / 2.0) < 10e-7;\r
+ isParallel = fabs(aSketchDir->angle(aDir) - M_PI / 2.0) < 10e-7;\r
} else {\r
isParallel = false;\r
}\r
aFirstEndPnt = std::dynamic_pointer_cast<GeomDataAPI_Point2D>(aFirstFeature->attribute(anEndAttr))->pnt();
aSecondStartPnt = std::dynamic_pointer_cast<GeomDataAPI_Point2D>(aSecondFeature->attribute(aStartAttr))->pnt();
aSecondEndPnt = std::dynamic_pointer_cast<GeomDataAPI_Point2D>(aSecondFeature->attribute(anEndAttr))->pnt();
- double aCheck1 = abs((aFirstEndPnt->x() - aFirstStartPnt->x()) * (aSecondStartPnt->y() - aFirstStartPnt->y()) -
+ double aCheck1 = fabs((aFirstEndPnt->x() - aFirstStartPnt->x()) * (aSecondStartPnt->y() - aFirstStartPnt->y()) -
(aSecondStartPnt->x() - aFirstStartPnt->x()) * (aFirstEndPnt->y() - aFirstStartPnt->y()));
- double aCheck2 = abs((aFirstEndPnt->x() - aFirstStartPnt->x()) * (aSecondEndPnt->y() - aFirstStartPnt->y()) -
+ double aCheck2 = fabs((aFirstEndPnt->x() - aFirstStartPnt->x()) * (aSecondEndPnt->y() - aFirstStartPnt->y()) -
(aSecondEndPnt->x() - aFirstStartPnt->x()) * (aFirstEndPnt->y() - aFirstStartPnt->y()));
if(aCheck1 < 1.e-7 && aCheck2 < 1.e-7) {
return false;
/*!
\ingroup GUI
+ \brief Commonly used methods in XGUI package and higher.
+ */
+namespace XGUI_Tools {
+
+/**
\brief Return directory part of the file path.
If the file path does not include directory part (the file is in the
current directory), null string is returned.
\param path file path
- \param abs if true (default) \a path parameter is treated as absolute file path
+ \param isAbs if true (default) \a path parameter is treated as absolute file path
\return directory part of the file path
- */
-namespace XGUI_Tools {
-
-/**
-* Returns directory name from name of file
-* \param path a path to a file
-* \param isAbs is absolute or relative path
*/
QString XGUI_EXPORT dir(const QString& path, bool isAbs = true);