From 6fa7c6d7164a2c9f880d25fd3b9269585dceeb27 Mon Sep 17 00:00:00 2001 From: cg246364 Date: Wed, 4 Aug 2021 09:07:19 +0200 Subject: [PATCH] Corrections sur la documentation et le code --- src/CTestTestfileInstall.cmake | 1 + src/OperaAPI/OperaAPI_Volume.cpp | 41 +++----- src/OperaAPI/OperaAPI_Volume.h | 23 ++--- src/OperaPlugin/OperaPlugin_Plugin.cpp | 2 - src/OperaPlugin/OperaPlugin_Volume.cpp | 12 +-- src/OperaPlugin/OperaPlugin_Volume.h | 7 +- src/OperaPlugin/OperaPlugin_msg_fr.ts | 94 +++++++++--------- src/OperaPlugin/Test/TestVolume.py | 5 +- src/OperaPlugin/doc/OperaPlugin.rst | 2 +- src/OperaPlugin/doc/TUI_volume.rst | 8 +- .../doc/{example => examples}/volume.py | 0 src/OperaPlugin/doc/images/Volume.png | Bin 0 -> 5741 bytes src/OperaPlugin/doc/images/Volume_create.png | Bin 4953 -> 0 bytes src/OperaPlugin/doc/volumeFeature.rst | 20 ++-- src/OperaPlugin/volume_widget.xml | 4 +- src/SHAPERGUI/resources/LightApp.xml.in | 3 + 16 files changed, 105 insertions(+), 117 deletions(-) rename src/OperaPlugin/doc/{example => examples}/volume.py (100%) create mode 100644 src/OperaPlugin/doc/images/Volume.png delete mode 100644 src/OperaPlugin/doc/images/Volume_create.png diff --git a/src/CTestTestfileInstall.cmake b/src/CTestTestfileInstall.cmake index b52f407b3..daabb1b56 100644 --- a/src/CTestTestfileInstall.cmake +++ b/src/CTestTestfileInstall.cmake @@ -47,4 +47,5 @@ SUBDIRS(ConnectorAPI ModelGeomAlgo Locale test_API + OperaPlugin ) diff --git a/src/OperaAPI/OperaAPI_Volume.cpp b/src/OperaAPI/OperaAPI_Volume.cpp index 2612060d1..cf7dd40c9 100644 --- a/src/OperaAPI/OperaAPI_Volume.cpp +++ b/src/OperaAPI/OperaAPI_Volume.cpp @@ -18,15 +18,9 @@ // #include "OperaAPI_Volume.h" - - #include -#include #include -#include // std::wstring_convert -#include // std::codecvt_utf8 - //================================================================================================== OperaAPI_Volume::OperaAPI_Volume(const std::shared_ptr& theFeature) : ModelHighAPI_Interface(theFeature) @@ -37,35 +31,32 @@ OperaAPI_Volume::OperaAPI_Volume(const std::shared_ptr& theFea //================================================================================================== OperaAPI_Volume::OperaAPI_Volume(const std::shared_ptr& theFeature, - const ModelHighAPI_Double& theMedium, - const std::list& theObjectList) + const std::string& theMedium, + const std::list& theObjectsList) : ModelHighAPI_Interface(theFeature) { if(initialize()) { - - std::wstring w_medium = theMedium.string(); - std::wstring_convert,wchar_t> cv; - std::string medium_str = cv.to_bytes(w_medium); - - fillAttribute(medium_str, medium()); - setObjectList(theObjectList); + fillAttribute(theMedium, medium()); + setObjectsList(theObjectsList); } } //================================================================================================== -OperaAPI_Volume::~OperaAPI_Volume() {} +OperaAPI_Volume::~OperaAPI_Volume() +{ +} //================================================================================================== -void OperaAPI_Volume::setMedium(const ModelHighAPI_Double& theMedium) +void OperaAPI_Volume::setMedium(const std::string& theMedium) { - fillAttribute(OperaPlugin_Volume::MEDIUM_ID(), medium()); + fillAttribute(theMedium, medium()); execute(); } //================================================================================================== -void OperaAPI_Volume::setObjectList(const std::list& theObjectList) +void OperaAPI_Volume::setObjectsList(const std::list& theObjectsList) { - fillAttribute(theObjectList, volumeList()); + fillAttribute(theObjectsList, objectsList()); execute(); } @@ -78,16 +69,16 @@ void OperaAPI_Volume::dump(ModelHighAPI_Dumper& theDumper) const AttributeStringPtr anAttrMedium = aBase->string(OperaPlugin_Volume::MEDIUM_ID()); theDumper << aBase << " = model.addVolume(" << aDocName << ", " << anAttrMedium << ", "; - AttributeSelectionListPtr anAttrList = aBase->selectionList(OperaPlugin_Volume::VOLUME_LIST_ID()); + AttributeSelectionListPtr anAttrList = + aBase->selectionList(OperaPlugin_Volume::OBJECTS_LIST_ID()); theDumper << anAttrList << ")" << std::endl; } //================================================================================================== VolumePtr addVolume(const std::shared_ptr& thePart, - const ModelHighAPI_Double& theMedium, - const std::list& theObjectList) + const std::string& theMedium, + const std::list& theObjectsList) { std::shared_ptr aFeature = thePart->addFeature(OperaAPI_Volume::ID()); - //aFeature->selectionList(OperaPlugin_Volume::VOLUME_LIST_ID())->setGeometricalSelection(true); - return VolumePtr(new OperaAPI_Volume(aFeature, theMedium, theObjectList)); + return VolumePtr(new OperaAPI_Volume(aFeature, theMedium, theObjectsList)); } diff --git a/src/OperaAPI/OperaAPI_Volume.h b/src/OperaAPI/OperaAPI_Volume.h index 46842b018..78aca0374 100644 --- a/src/OperaAPI/OperaAPI_Volume.h +++ b/src/OperaAPI/OperaAPI_Volume.h @@ -26,12 +26,11 @@ #include #include -class ModelHighAPI_Double; class ModelHighAPI_Selection; /// \class OperaAPI_Volume /// \ingroup CPPHighAPI -/// \brief Interface for primitive Box feature. +/// \brief Interface for Volume feature. class OperaAPI_Volume: public ModelHighAPI_Interface { public: @@ -42,8 +41,8 @@ public: /// Constructor with values. OPERAAPI_EXPORT explicit OperaAPI_Volume(const std::shared_ptr& theFeature, - const ModelHighAPI_Double& theMedium, - const std::list& theObjectList); + const std::string& theMedium, + const std::list& theObjectList); /// Destructor. OPERAAPI_EXPORT @@ -51,17 +50,17 @@ public: INTERFACE_2(OperaPlugin_Volume::ID(), medium, OperaPlugin_Volume::MEDIUM_ID(), - ModelAPI_AttributeString, /** Volume medium */, - volumeList, OperaPlugin_Volume::VOLUME_LIST_ID(), - ModelAPI_AttributeSelectionList, /** Group list*/) + ModelAPI_AttributeString, /** Medium */, + objectsList, OperaPlugin_Volume::OBJECTS_LIST_ID(), + ModelAPI_AttributeSelectionList, /** Objects list*/) /// Set medium OPERAAPI_EXPORT - void setMedium(const ModelHighAPI_Double& theMedium); + void setMedium(const std::string& theMedium); /// Set main objects list. OPERAAPI_EXPORT - void setObjectList(const std::list& theObjectList); + void setObjectsList(const std::list& theObjectsList); /// Dump wrapped feature OPERAAPI_EXPORT @@ -75,7 +74,7 @@ typedef std::shared_ptr VolumePtr; /// \brief Create Volume feature. OPERAAPI_EXPORT VolumePtr addVolume(const std::shared_ptr& thePart, - const ModelHighAPI_Double& theMedium, - const std::list& theObjectList); + const std::string& theMedium, + const std::list& theObjectsList); -#endif // OperaAPI_Volume_H_ +#endif // OPERAAPI_VOLUME_H_ diff --git a/src/OperaPlugin/OperaPlugin_Plugin.cpp b/src/OperaPlugin/OperaPlugin_Plugin.cpp index e5791e516..894925751 100644 --- a/src/OperaPlugin/OperaPlugin_Plugin.cpp +++ b/src/OperaPlugin/OperaPlugin_Plugin.cpp @@ -23,8 +23,6 @@ #include #include -#include -#include // the only created instance of this plugin static OperaPlugin_Plugin* MY_PRIMITIVES_INSTANCE = new OperaPlugin_Plugin(); diff --git a/src/OperaPlugin/OperaPlugin_Volume.cpp b/src/OperaPlugin/OperaPlugin_Volume.cpp index 4c41960ae..57393a226 100644 --- a/src/OperaPlugin/OperaPlugin_Volume.cpp +++ b/src/OperaPlugin/OperaPlugin_Volume.cpp @@ -18,21 +18,15 @@ // #include -#include #include #include -#include #include #include #include #include -#include -#include - #include #include -#include //================================================================================================= OperaPlugin_Volume::OperaPlugin_Volume() // Nothing to do during instantiation @@ -66,7 +60,7 @@ void OperaPlugin_Volume::initAttributes() data()->addAttribute(MEDIUM_ID(), ModelAPI_AttributeString::typeId()); // Get Objects - data()->addAttribute(VOLUME_LIST_ID(), ModelAPI_AttributeSelectionList::typeId()); + data()->addAttribute(OBJECTS_LIST_ID(), ModelAPI_AttributeSelectionList::typeId()); } //================================================================================================= @@ -81,7 +75,7 @@ void OperaPlugin_Volume::execute() int aResultIndex = 0; - AttributeSelectionListPtr aList = selectionList(VOLUME_LIST_ID()); + AttributeSelectionListPtr aList = selectionList(OBJECTS_LIST_ID()); std::wstring aBaseName; for (int aSelIndex = 0; aSelIndex < aList->size(); aSelIndex++) { AttributeSelectionPtr aSel = aList->value(aSelIndex); @@ -106,9 +100,7 @@ void OperaPlugin_Volume::execute() std::set anExistingNames; std::wstring aBaseName = aSel->context() ? aSel->context()->data()->name() : aSel->contextFeature()->firstResult()->data()->name(); - int anInd = 0; do { - anInd++; std::wostringstream aNameStr; aNameStr << "Volume_" << aBaseName; aName = aNameStr.str(); diff --git a/src/OperaPlugin/OperaPlugin_Volume.h b/src/OperaPlugin/OperaPlugin_Volume.h index e48e2ff5b..be8b73824 100644 --- a/src/OperaPlugin/OperaPlugin_Volume.h +++ b/src/OperaPlugin/OperaPlugin_Volume.h @@ -22,7 +22,6 @@ #include #include -#include class GeomAPI_Shape; class ModelAPI_ResultBody; @@ -49,10 +48,10 @@ class OperaPlugin_Volume : public ModelAPI_Feature return MY_MEDIUM_ID; } /// attribute name of selected entities list - inline static const std::string& VOLUME_LIST_ID() + inline static const std::string& OBJECTS_LIST_ID() { - static const std::string MY_VOLUME_LIST_ID("volume_list"); - return MY_VOLUME_LIST_ID; + static const std::string MY_OBJECTS_LIST_ID("objects_list"); + return MY_OBJECTS_LIST_ID; } // Creates a new part document if needed diff --git a/src/OperaPlugin/OperaPlugin_msg_fr.ts b/src/OperaPlugin/OperaPlugin_msg_fr.ts index 5d22d90ae..aca1a8815 100644 --- a/src/OperaPlugin/OperaPlugin_msg_fr.ts +++ b/src/OperaPlugin/OperaPlugin_msg_fr.ts @@ -2,56 +2,56 @@ - - workshop - - Volume - Volume - - + + workshop + + Volume + Volume + + - - Volume - - Volume - Volume - - - Create a volume - Créer un volume - - + + Volume + + Volume + Volume + + + Create a volume + Créer un volume + + - - Volume:medium - - Medium - Milieu - - - Please input the volumes medium - Veuillez indiquer le milieu des volumes - - + + Volume:medium + + Medium + Milieu + + + Please input the volumes medium + Veuillez indiquer le milieu des volumes + + - - Volume:volume_list - - Select solids - Selectionner les solides - - - Select solid objects - Sélectionnez les solides - - + + Volume:objects_list + + Objects + Objets + + + Select solid objects + Sélectionnez les solides + + - - Volume:volume_list - - Attribute "%1" is not initialized. - Sélectionnez les solides. - - + + Volume:objects_list + + Attribute "%1" is not initialized. + Sélectionnez les solides. + + diff --git a/src/OperaPlugin/Test/TestVolume.py b/src/OperaPlugin/Test/TestVolume.py index f85f3246d..66538baca 100755 --- a/src/OperaPlugin/Test/TestVolume.py +++ b/src/OperaPlugin/Test/TestVolume.py @@ -45,7 +45,8 @@ Sphere_1 = model.addSphere(Part_1_doc, model.selection("VERTEX", "PartSet/Origin Volume_1 = model.addVolume(Part_1_doc, "Air", [model.selection("SOLID", "Box_1_1")]) ### Create a volume from the cylinder and the sphere -Volume_2 = model.addVolume(Part_1_doc, "Eau", [model.selection("SOLID", "Cylinder_1_1"), model.selection("SOLID", "Sphere_1_1")]) +Volume_2 = model.addVolume(Part_1_doc, "Air", [model.selection("SOLID", "Cylinder_1_1"), model.selection("SOLID", "Sphere_1_1")]) +Volume_2.setMedium("Eau") #Checks from GeomAPI import GeomAPI_Shape @@ -69,7 +70,7 @@ assert(Volume_3.feature().error() == "Error: Medium cannot be empty.") ### Create a volume with no shapes Volume_4 = model.addVolume(Part_1_doc, "Error", []) model.testNbResults(Volume_4, 0) -assert(Volume_4.feature().error() == "Attribute \"volume_list\" is not initialized.") +assert(Volume_4.feature().error() == "Attribute \"objects_list\" is not initialized.") ### Create a volume with bad shapes Volume_5 = model.addVolume(Part_1_doc, "Bad Shape", [model.selection("VERTEX", "PartSet/Origin")]) diff --git a/src/OperaPlugin/doc/OperaPlugin.rst b/src/OperaPlugin/doc/OperaPlugin.rst index 41da0e59a..f61f280bd 100644 --- a/src/OperaPlugin/doc/OperaPlugin.rst +++ b/src/OperaPlugin/doc/OperaPlugin.rst @@ -4,7 +4,7 @@ Opera plug-in ================== -The Opera plug-in contains features for creation of Opera items. Result of each feature is a solid. The plug-in includes the following features: +The Opera plug-in provides a set of common operations to ROOT geometry. It implements the following features: .. toctree:: :titlesonly: diff --git a/src/OperaPlugin/doc/TUI_volume.rst b/src/OperaPlugin/doc/TUI_volume.rst index f136686c6..3f3ecbd0f 100644 --- a/src/OperaPlugin/doc/TUI_volume.rst +++ b/src/OperaPlugin/doc/TUI_volume.rst @@ -1,11 +1,11 @@ - .. tui_create_volume: + .. _tui_create_volume: -Create Box by points -==================== +Create Volume +============= .. literalinclude:: examples/volume.py :linenos: :language: python -:download:`Download this script ` +:download:`Download this script ` diff --git a/src/OperaPlugin/doc/example/volume.py b/src/OperaPlugin/doc/examples/volume.py similarity index 100% rename from src/OperaPlugin/doc/example/volume.py rename to src/OperaPlugin/doc/examples/volume.py diff --git a/src/OperaPlugin/doc/images/Volume.png b/src/OperaPlugin/doc/images/Volume.png new file mode 100644 index 0000000000000000000000000000000000000000..281fc7197b8001c47de93c0de6f4e649e61000f7 GIT binary patch literal 5741 zcmb7|2UJtdwtxXq1d%Qsfq)>riBv@;K#&p@1Ob5{9g!A#Z%XI_Ql&`|>Ae#|FVdt1 z=_M5DodBV{*Z;12*IRGa%F3LXIdk@uz4y0w@H2I#nl_B64czF1v zz>nrS0nqaNZJH?XM{Ebtf#czkwf+9#$MTUe0gXhC%4!NkOVXu+nWtoBUXkBklv@79Vk__3zz#OAbzCJlDFb9cLU z<`vjpqzOb=i)ij4$#}1nk~dD{?;%m#*_XaePFmk1DrUPZQNBUi zNw4x$H#PZ;i&B|Wl)x9KTqtK0W)y+vNZUPLZZ4vPCmqTO0ujIo)5{^G*RCvI_f=3= zC!^d=pu|g&=fp!0rZZuc>z-@b_ zcQX~kb!#26O}`IjD#i2bILxbvVbv)wMTSs=Tq$dvz$=z`$UBex6RqfX3Dn z(-CfXzNU?jkIxux))Oc2N?aN=+QMg8urrA$!dg}im^9!fHM(s}9@iGr$X z@78pEI~4BV;OXh<@9$6eI6=}nb!YfTp6P$NXozprmFE8mec}?Ki z#KhEeDO9L2At{M>2G;CN+|)zAx<^A0J0YQ-Mygs7tSlvy+$kT2hjduI}!F1`V$~O^MR;CqEL& zlp;SCDTvxk)iehX`RumSiHnP$oSXos4bB?18nvo49cY`JtgosyFZ(yxd%oL{(rrzx-8Ly^rTpWL!$rAFUK%rKK;eR;nw|mGVvS<=%0mhl`q;nu$r4 zZXp+_Qnzr_DqJ!1XZL8n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R+ zG2u)S8+BbwkG7d@oRonAfppn=?|(K=b-T7tcj~((w~hWan3W865qJ7zRZG+H}qyGzjYeMp%ekDx$5ind*C0c_(%0$cnCE97195FD9}$q z+$2v!L({e704CT8XlZRNl#6{6fmdNHOb^gzliiKqQ9fz)Z}j~0q2<4I5V*Rt|C>Pn zl;U4`g+HYDqxwhxAJzYRZU4+x{C%qb?>789Q2*B*i^BU4LjfQM(j|gX6Aqcbk3}6H xbn@89$S6V0cb*pL`MYR;ZO9*!$UeScC02tYtM>~&0eN9OWd(I`(G!^e{{XV$*D3%2 literal 0 HcmV?d00001 diff --git a/src/OperaPlugin/doc/images/Volume_create.png b/src/OperaPlugin/doc/images/Volume_create.png deleted file mode 100644 index 63c1f2263d650824af9eb202749b6df21ea41e65..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4953 zcmd6rXH-+$w#P#g5h(_hDj-!rO%N#t5QQKKQU$>i5;{nc-U&rOr3H{C9i$0JiS!Pl zAfZT+PAEqN0U?AU37xmkxvz}--ngIM`|#EnYwWSt*lVx3=UnSI|9eL2>1eQ=<2eTc zfmo0T_#+UAh7Raw&e8%S8$nMYz=g>b@rMTp#M=2+r%9G#0=*_G!g-hv(KZM8W*p*g^zRh-dJRExkemSQlA=F zpDLP}OtiOd8mzc-MM*(THJ_6wuo!w;y5yDRU5&xpbbS^< zJK4J?j<(~LEG%B3Zv~$-W;_oEfkZ)X=|M@L=U@=Zt=m-C$HzxWXj5>q#m~dt-91B; zeYn*jj)1>b^uQj4g`byu|mj#x__1xZL zv(I1n(F9X;kV|`tCqg|Dza5!RirvUN$GOLcY*&8&-X!?T%CwxmZFF&lnq22Xtek5# zogW%{J8Xx>V9Jdg8H4*QYd22T=I0cS0x9h$J|o+FnBz-_CVe*zoy_*XWORiaW#07; zSX=%o=3)GBk20j6+(e!1lm^~TIK1uR`j$#Kxv%K`ldQOjfBNOFlNjYV5{wh|>lZ6Q%#;o$i6oiTA%Vz+DC_5$Y}M~@(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*l%rZt*)*fA5sSg2I^4du&jaZZjBPdUKMsOt|tZtBfrSMJYgy-Dnzju(laq2 z8gdz5fjOVU*<4D6K3?`vJOCV?oqcogClIr5-@e&?O}9CvOM#fZfz)`tx}c)cez}xY z2>fDP(bL_%_wNP^J_$gfP}bJg2t0V(uYr@WK0HEP*mhHU9(Dv7tY*y|Ni~NQtpn|-{zyc`_f8FYxxSB=P_0^#3=8{8#DbUzo&C`@eU{ zCa?a?Qe9{$t Volume* item or #. click |Volume_button.icon| **Volume** button in the toolbar: -Volume is created by a Medium value and a list of solids +Volume is created by a value and a list of solids -.. figure:: images/Volume_create.png +.. figure:: images/Volume.png :align: center Input fields: -- **MEDIUM**, **VOLUME_LIST** define medium and shapes of the volume. +- **Medium** defines the name of the medium; +- **Objects** defines the list of solid objects **TUI Command**: -.. py:function:: model.addVolume(Part_doc, MediumString, model.selection["SOLID", "...", ...]) +.. py:function:: + model.addVolume(Part_doc, medium, model.selection[("SOLID", ...), ...]) :param part: The current part object. - :param string: Medium name. - :param list: List of solids. + :param string: A medium name. + :param list: A list of solids. :return: Result object. Result @@ -36,4 +38,6 @@ One solid for each selected solid in the volume list with according medium .. figure:: images/Volume1.png :align: center + Volume created + **See Also** a sample TUI Script of :ref:`tui_create_volume` operation. diff --git a/src/OperaPlugin/volume_widget.xml b/src/OperaPlugin/volume_widget.xml index 8f18a004d..a0cbd22b7 100644 --- a/src/OperaPlugin/volume_widget.xml +++ b/src/OperaPlugin/volume_widget.xml @@ -3,8 +3,8 @@ label="Medium" tooltip="Please input the volumes medium"> - diff --git a/src/SHAPERGUI/resources/LightApp.xml.in b/src/SHAPERGUI/resources/LightApp.xml.in index 33908724f..6d303a073 100644 --- a/src/SHAPERGUI/resources/LightApp.xml.in +++ b/src/SHAPERGUI/resources/LightApp.xml.in @@ -22,6 +22,9 @@ +
+ +
-- 2.39.2