X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FFeaturesPlugin%2Fdoc%2FtranslationFeature.rst;h=c906f075ec1715ac0158c875308e75e7bb2e1373;hb=d3afed6da21a10db226a968698b63af318e6111e;hp=47099261a7ec899c36e100a510134189cd3f7e88;hpb=9fffc6fbe2d96642d1798a819b07b84bc3d96e07;p=modules%2Fshaper.git diff --git a/src/FeaturesPlugin/doc/translationFeature.rst b/src/FeaturesPlugin/doc/translationFeature.rst index 47099261a..c906f075e 100644 --- a/src/FeaturesPlugin/doc/translationFeature.rst +++ b/src/FeaturesPlugin/doc/translationFeature.rst @@ -1,33 +1,38 @@ +.. _featureTranslation: +.. |translation_vector_32x32.icon| image:: images/translation_vector_32x32.png + :height: 16px Translation =========== -The feature **Translation** makes translation of a selected shape. +**Translation** feature translates a selected shape. -To create Translation in the active part: +To create a Translation in the active part: #. select in the Main Menu *Part - > Translation* item or -#. click **Translation** button in the toolbar +#. click |translation_vector_32x32.icon| **Translation** button in the toolbar -.. image:: images/translation_vector_32x32.png - :align: center +The Vector of translation can be defined in three different ways: -.. centered:: - **Translation** button +.. image:: images/translation_vector_32x32.png + :align: left + :height: 24px -The Vector of translation can be defined in three different ways: +by by axis and distance + +.. image:: images/translation_dxyz_32x32.png + :align: left + :height: 24px + +by vector - .. image:: images/translation_vector_32x32.png - :align: left - by by axis and distance +.. image:: images/translation_2pt_32x32.png + :align: left + :height: 24px - .. image:: images/translation_dxyz_32x32.png - :align: left - by vector +by two points - .. image:: images/translation_2pt_32x32.png - :align: left - by two points +-------------------------------------------------------------------------------- Translation by axis and distance -------------------------------- @@ -40,18 +45,24 @@ Translation by axis and distance Input fields: -- **Main objects** panel contains shapes to be translated. Shapes are selected in 3D OCC viewer or object browser; -- **Axis** defines vector along which the object will be translated. Vector is edge, axis selected in 3D OCC viewer or object browser; +- **Main objects** panel contains shapes to be translated. The shapes are selected in 3D OCC viewer or object browser; +- **Axis** defines a vector along which the object will be translated. The vector is an edge or axis selected in 3D OCC viewer or object browser; - **Distance** defines the distance along the **Vector of translation**. -**TUI Command**: *model.addTranslation(Part_doc, [shape], axis, dist)* +**TUI Command**: + +.. py:function:: model.addTranslation(Part_doc, [shape], axis, dist) -**Arguments**: part + list of shapes in format *model.selection(TYPE, shape)* + axis in format *model.selection(TYPE, shape)*+ real (distance value). + :param part: The current part object. + :param list: A list of shapes in format *model.selection(TYPE, shape)*. + :param object: axis in format *model.selection(TYPE, shape)*. + :param real: Distance value. + :return: Result object. Result """""" -Result of operation is shifted initial shape. +The result of operation is a shifted initial shape. .. image:: images/translation_XYZ.png :align: center @@ -72,17 +83,24 @@ Translation by vector Input fields: -- **Main objects** panel contains shapes to be translated. Shapes are selected in 3D OCC viewer or object browser; +- **Main objects** panel contains shapes to be translated. The shapes are selected in 3D OCC viewer or object browser; - **DX**, **DY**, **DZ** define vector using coordinates along the axis. -**TUI Command**: *model.addTranslation(Part_1_doc, [shape], DX, DY, DZ)* +**TUI Command**: -**Arguments**: part + list of shapes in format *model.selection(TYPE, shape)* + 3 real (coordinate values). +.. py:function:: model.addTranslation(Part_1_doc, [shape], DX, DY, DZ) + + :param part: The current part object. + :param list: A list of shapes in format *model.selection(TYPE, shape)*. + :param real: dX value. + :param real: dY value. + :param real: dZ value. + :return: Result object. Result """""" -Result of operation is shifted initial shape. +The result of operation is a shifted initial shape. .. image:: images/translation_vector.png :align: center @@ -90,7 +108,7 @@ Result of operation is shifted initial shape. .. centered:: Translation by vector -**See Also** a sample TUI Script of a :ref:`tui_translation_DXDYDZ` operation. +**See Also** a sample TUI Script of :ref:`tui_translation_DXDYDZ` operation. Translation by two points @@ -108,14 +126,20 @@ Input fields: - **Start point** defines start vector point as point or vertex selected in 3D OCC viewer or object browser; - **End point** defines end vector point as point or vertex selected in 3D OCC viewer or object browser; -**TUI Command**: *model.addTranslation(Part_doc, [shape], point1, point2)* +**TUI Command**: + +.. py:function:: model.addTranslation(Part_doc, [shape], point1, point2) -**Arguments**: part + list of shapes in format *model.selection(TYPE, shape)* + 2 points in format *model.selection(TYPE, shape)*. + :param part: The current part object. + :param list: A list of shapes in format *model.selection(TYPE, shape)*. + :param object: A point in format *model.selection(TYPE, shape)*. + :param object: A point in format *model.selection(TYPE, shape)*. + :return: Result object. Result """""" -Result of operation is shifted initial shape. +The result of operation is a shifted initial shape. .. image:: images/translation_2points.png :align: center @@ -123,5 +147,5 @@ Result of operation is shifted initial shape. .. centered:: Translation by two points -**See Also** a sample TUI Script of a :ref:`tui_translation_2points` operation. +**See Also** a sample TUI Script of :ref:`tui_translation_2points` operation.