Salome HOME
Constriction type for all sketch entities
[modules/shaper.git] / src / PartSet / PartSet_WidgetSketchLabel.h
index ac845c279ada0c1e8724e209691759fb05877e0f..1189dd2286ce32c64c8699f6793b89a27fdb7246 100644 (file)
@@ -24,8 +24,14 @@ class QTimer;
 class XGUI_OperationMgr;
 class XGUI_Workshop;
 
+/// the plane edge width
+#define SKETCH_WIDTH        "4"
+
+/// face of the square-face displayed for selection of general plane
+#define PLANE_SIZE          "200"
+
 /**
-* \ingroup Module
+* \ingroup Modules
 * A model widget implementation for a label which provides specific behaviour 
 * for sketcher starting and launching operations
 */
@@ -42,11 +48,6 @@ Q_OBJECT
 
   virtual ~PartSet_WidgetSketchLabel();
 
-  virtual bool storeValue() const
-  {
-    return true;
-  }
-
   virtual bool restoreValue()
   {
     return true;
@@ -56,11 +57,6 @@ Q_OBJECT
   /// \return a control list
   virtual QList<QWidget*> getControls() const;
 
-  QWidget* getControl() const;
-
-  /// The methiod called when widget is activated
-  virtual void activate();
-
   /// The methiod called when widget is deactivated
   virtual void deactivate();
 
@@ -74,10 +70,24 @@ Q_OBJECT
   /// Returns sketcher plane
   std::shared_ptr<GeomAPI_Pln> plane() const;
 
+  /// This control accepts focus
+  virtual bool focusTo() { return true; }
+
 signals:
   /// Signal on plane selection
   void planeSelected(const std::shared_ptr<GeomAPI_Pln>& thePln);
 
+protected:
+  /// Saves the internal parameters to the given feature
+  /// \return True in success
+  virtual bool storeValueCustom() const
+  {
+    return true;
+  }
+
+  /// The methiod called when widget is activated
+  virtual void activateCustom();
+
  private slots:
    /// Slot on plane selection
   void onPlaneSelected();