#include "HYDROData_ProfileUZ.h"
-DEFINE_STANDARD_HANDLE(HYDROData_Profile, HYDROData_Object)
-
class gp_XYZ;
class OSD_File;
-class Handle(HYDROData_Document);
+class HYDROData_Document;
/**\class HYDROData_Profile
* \brief Class that stores/retreives information about the profile.
};
public:
- DEFINE_STANDARD_RTTI(HYDROData_Profile);
+ DEFINE_STANDARD_RTTIEXT(HYDROData_Profile, HYDROData_Object);
/**
* Returns the kind of this object. Must be redefined in all objects of known type.
/**
* Dump object to Python script representation.
*/
- HYDRODATA_EXPORT virtual QStringList DumpToPython( MapOfTreatedObjects& theTreatedObjects ) const;
+ HYDRODATA_EXPORT virtual QStringList DumpToPython( const QString& thePyScriptPath,
+ MapOfTreatedObjects& theTreatedObjects ) const;
/**
* Returns the top shape of the object.
/**
* Returns default filling color for new profile.
*/
- HYDRODATA_EXPORT static QColor DefaultFillingColor();
+ HYDRODATA_EXPORT virtual QColor DefaultFillingColor() const;
/**
* Returns default border color for new profile.
*/
- HYDRODATA_EXPORT static QColor DefaultBorderColor();
+ HYDRODATA_EXPORT virtual QColor DefaultBorderColor() const;
public:
* \param thePoint[out] profile first point
* \return true if point has been set
*/
- HYDRODATA_EXPORT bool GetLeftPoint( gp_XY& thePoint, bool IsConvertToGlobal = false ) const;
+ HYDRODATA_EXPORT bool GetLeftPoint( gp_XY& thePoint, bool IsConvertToGlobal = false,
+ bool CanUseDefault = false ) const;
/**
* Set last(right) point for profile.
* \param thePoint[out] profile last point
* \return true if point has been set
*/
- HYDRODATA_EXPORT bool GetRightPoint( gp_XY& thePoint, bool IsConvertToGlobal = false ) const;
-
+ HYDRODATA_EXPORT bool GetRightPoint( gp_XY& thePoint, bool IsConvertToGlobal = false,
+ bool CanUseDefault = false ) const;
/**
* Returns object which store parametric presentation of profile points.
* Empty sequence is returned if first or last point was not set.
* \return profile points list
*/
- HYDRODATA_EXPORT ProfilePoints GetProfilePoints( bool IsConvertToGlobal = false ) const;
+ HYDRODATA_EXPORT ProfilePoints GetProfilePoints( bool IsConvertToGlobal = false,
+ bool CanUseDefaultLeftRight = false ) const;
/**
*/
HYDRODATA_EXPORT ProfilePoint GetBottomPoint() const;
+ /**
+ * Return profile middle point.
+ * \return non-parametric profile point
+ */
+ HYDRODATA_EXPORT ProfilePoint GetMiddlePoint( bool CanUseDefault ) const;
+
public:
// Public methods to work with files.
bool* theIsRead = 0 );
protected:
-
- /**
- * Returns default filling color for new object.
- */
- HYDRODATA_EXPORT virtual QColor getDefaultFillingColor() const;
-
- /**
- * Returns default border color for new object.
- */
- HYDRODATA_EXPORT virtual QColor getDefaultBorderColor() const;
-
/**
* Checks and if necessary create child 3D object.
* Reimplemented to prevent creation of 3D child object.
*/
HYDRODATA_EXPORT virtual void checkAndSetObject3D() {}
+ TopoDS_Shape CreateProfileWire( bool canUseDefaultPoints ) const;
protected: