From d4ee161c07fb934244454cb411c44a94cfcdf459 Mon Sep 17 00:00:00 2001 From: Simon De Backer Date: Sun, 16 Aug 2020 11:19:36 +0200 Subject: [PATCH] Mod doc set style de same --- SingleApplication/singleapplication.cpp | 16 +- SingleApplication/singleapplication.h | 100 ++-- SingleApplication/singleapplication_p.cpp | 4 +- .../elementcollectionhandler.cpp | 64 +-- .../elementcollectionhandler.h | 34 +- .../elementcollectionitem.cpp | 94 ++-- .../elementcollectionitem.h | 10 +- .../elementscollectionmodel.cpp | 18 +- .../elementscollectionwidget.cpp | 192 ++++---- .../elementscollectionwidget.h | 10 +- .../ElementsCollection/elementslocation.cpp | 2 +- .../ElementsCollection/elementstreeview.cpp | 22 +- sources/ElementsCollection/elementstreeview.h | 10 +- .../fileelementcollectionitem.h | 8 +- .../xmlelementcollection.cpp | 306 ++++++------ .../ElementsCollection/xmlelementcollection.h | 46 +- .../xmlprojectelementcollectionitem.cpp | 112 ++--- .../xmlprojectelementcollectionitem.h | 6 +- sources/NameList/nameslist.cpp | 18 +- sources/NameList/ui/namelistdialog.cpp | 8 +- sources/NameList/ui/namelistdialog.h | 6 +- sources/NameList/ui/namelistwidget.cpp | 42 +- sources/NameList/ui/namelistwidget.h | 6 +- .../PropertiesEditor/propertieseditordialog.h | 20 +- .../propertieseditordockwidget.cpp | 68 +-- .../propertieseditorwidget.cpp | 48 +- .../PropertiesEditor/propertieseditorwidget.h | 8 +- .../qpropertyundocommand.cpp | 78 ++-- .../qpropertyundocommand.h | 12 +- sources/QWidgetAnimation/qwidgetanimation.cpp | 46 +- sources/QWidgetAnimation/qwidgetanimation.h | 22 +- .../qetgraphicshandleritem.cpp | 36 +- .../qetgraphicshandleritem.h | 12 +- .../qetgraphicshandlerutility.cpp | 157 ++++--- .../qetgraphicshandlerutility.h | 10 +- .../searchandreplaceworker.cpp | 137 +++--- .../SearchAndReplace/searchandreplaceworker.h | 7 +- .../ui/replaceadvanceddialog.cpp | 28 +- .../ui/replaceconductordialog.cpp | 22 +- .../ui/replaceconductordialog.h | 6 +- .../ui/replaceelementdialog.cpp | 14 +- .../ui/replacefoliowidget.cpp | 26 +- .../ui/searchandreplacewidget.cpp | 248 +++++----- sources/autoNum/assignvariables.cpp | 125 ++--- sources/autoNum/assignvariables.h | 8 +- sources/autoNum/numerotationcontext.cpp | 98 ++-- sources/autoNum/numerotationcontext.h | 2 +- .../autoNum/numerotationcontextcommands.cpp | 362 +++++++------- sources/autoNum/numerotationcontextcommands.h | 5 +- .../autoNum/ui/autonumberingdockwidget.cpp | 90 ++-- sources/autoNum/ui/folioautonumbering.cpp | 72 +-- sources/autoNum/ui/formulaautonumberingw.cpp | 32 +- sources/autoNum/ui/numparteditorw.cpp | 62 +-- sources/autoNum/ui/numparteditorw.h | 2 +- sources/autoNum/ui/selectautonumw.cpp | 64 +-- sources/bordertitleblock.cpp | 14 +- sources/conductornumexport.cpp | 28 +- sources/conductornumexport.h | 6 +- sources/conductorproperties.cpp | 40 +- sources/configdialog.cpp | 8 +- sources/configpages.cpp | 68 +-- sources/createdxf.cpp | 52 +-- sources/dataBase/projectdatabase.cpp | 106 ++--- sources/dataBase/projectdatabase.h | 10 +- sources/dataBase/ui/elementquerywidget.cpp | 104 ++--- sources/dataBase/ui/elementquerywidget.h | 8 +- sources/dataBase/ui/summaryquerywidget.cpp | 92 ++-- sources/diagram.cpp | 4 +- sources/diagramcontent.cpp | 128 ++--- sources/diagramcontext.cpp | 36 +- sources/diagramcontext.h | 2 +- .../diagramevent/diagrameventaddelement.cpp | 92 ++-- sources/diagramevent/diagrameventaddelement.h | 8 +- sources/diagramevent/diagrameventaddimage.cpp | 58 +-- sources/diagramevent/diagrameventaddimage.h | 6 +- sources/diagramevent/diagrameventaddshape.cpp | 54 +-- sources/diagramevent/diagrameventaddshape.h | 6 +- sources/diagramevent/diagrameventaddtext.cpp | 18 +- sources/diagramevent/diagrameventaddtext.h | 6 +- .../diagramevent/diagrameventinterface.cpp | 8 +- sources/diagramevent/diagrameventinterface.h | 28 +- sources/diagramview.cpp | 152 +++--- sources/dvevent/dveventinterface.cpp | 12 +- sources/dvevent/dveventinterface.h | 24 +- .../editor/UndoCommand/pastepartscommand.cpp | 40 +- .../editor/UndoCommand/pastepartscommand.h | 6 +- sources/editor/arceditor.cpp | 52 +-- sources/editor/arceditor.h | 9 +- sources/editor/editorcommands.cpp | 14 +- sources/editor/editorcommands.h | 6 +- sources/editor/elementprimitivedecorator.cpp | 60 +-- sources/editor/elementscene.cpp | 2 +- sources/editor/elementview.cpp | 50 +- sources/editor/ellipseeditor.h | 8 +- sources/editor/esevent/eseventaddarc.cpp | 48 +- sources/editor/esevent/eseventaddarc.h | 6 +- .../esevent/eseventadddynamictextfield.cpp | 26 +- .../esevent/eseventadddynamictextfield.h | 6 +- sources/editor/esevent/eseventaddellipse.cpp | 34 +- sources/editor/esevent/eseventaddellipse.h | 6 +- sources/editor/esevent/eseventaddline.cpp | 38 +- sources/editor/esevent/eseventaddline.h | 6 +- sources/editor/esevent/eseventaddpolygon.cpp | 42 +- sources/editor/esevent/eseventaddpolygon.h | 6 +- sources/editor/esevent/eseventaddrect.cpp | 34 +- sources/editor/esevent/eseventaddterminal.cpp | 34 +- sources/editor/esevent/eseventaddterminal.h | 6 +- sources/editor/esevent/eseventaddtext.cpp | 26 +- sources/editor/esevent/eseventaddtext.h | 6 +- sources/editor/esevent/eseventinterface.cpp | 22 +- .../graphicspart/abstractpartellipse.cpp | 121 ++--- .../editor/graphicspart/abstractpartellipse.h | 22 +- .../graphicspart/customelementgraphicpart.cpp | 162 +++---- .../graphicspart/customelementgraphicpart.h | 10 +- sources/editor/graphicspart/partarc.cpp | 130 +++--- sources/editor/graphicspart/partarc.h | 14 +- .../graphicspart/partdynamictextfield.cpp | 140 +++--- .../graphicspart/partdynamictextfield.h | 13 +- sources/editor/graphicspart/partellipse.cpp | 126 ++--- sources/editor/graphicspart/partellipse.h | 14 +- sources/editor/graphicspart/partline.cpp | 244 +++++----- sources/editor/graphicspart/partline.h | 6 +- sources/editor/graphicspart/partpolygon.cpp | 236 +++++----- sources/editor/graphicspart/partpolygon.h | 8 +- sources/editor/graphicspart/partrectangle.cpp | 186 ++++---- sources/editor/graphicspart/partrectangle.h | 12 +- sources/editor/graphicspart/partterminal.cpp | 12 +- sources/editor/graphicspart/partterminal.h | 6 +- sources/editor/lineeditor.cpp | 40 +- sources/editor/lineeditor.h | 9 +- sources/editor/qetelementeditor.cpp | 184 ++++---- sources/editor/styleeditor.cpp | 42 +- sources/editor/ui/dynamictextfieldeditor.cpp | 24 +- sources/editor/ui/dynamictextfieldeditor.h | 6 +- .../ui/elementpropertieseditorwidget.cpp | 56 +-- .../editor/ui/elementpropertieseditorwidget.h | 8 +- sources/editor/ui/polygoneditor.cpp | 58 +-- sources/editor/ui/polygoneditor.h | 9 +- sources/editor/ui/rectangleeditor.cpp | 56 +-- sources/editor/ui/rectangleeditor.h | 12 +- sources/editor/ui/texteditor.cpp | 58 +-- sources/elementdialog.cpp | 72 +-- sources/elementprovider.cpp | 70 +-- sources/elementscategoryeditor.cpp | 40 +- sources/elementscategoryeditor.h | 6 +- sources/elementscollectioncache.cpp | 72 +-- sources/elementsmover.cpp | 46 +- sources/elementspanel.cpp | 8 +- sources/elementspanelwidget.cpp | 2 +- sources/elementtextpattern.cpp | 36 +- sources/elementtextsmover.cpp | 30 +- sources/exportproperties.cpp | 12 +- sources/factory/elementfactory.cpp | 12 +- sources/factory/elementfactory.h | 11 +- sources/factory/elementpicturefactory.cpp | 60 +-- sources/factory/elementpicturefactory.h | 20 +- sources/factory/propertieseditorfactory.cpp | 12 +- sources/factory/qetgraphicstablefactory.cpp | 36 +- sources/factory/qetgraphicstablefactory.h | 4 +- sources/factory/ui/addtabledialog.cpp | 76 +-- sources/factory/ui/addtabledialog.h | 14 +- sources/machine_info.cpp | 2 +- sources/newelementwizard.cpp | 54 +-- sources/nomenclature.cpp | 16 +- sources/projectconfigpages.cpp | 136 +++--- sources/projectview.cpp | 90 ++-- sources/properties/reportproperties.cpp | 6 +- sources/properties/xrefproperties.cpp | 54 +-- sources/properties/xrefproperties.h | 6 +- sources/qet.cpp | 66 +-- sources/qetapp.cpp | 14 +- sources/qetdiagrameditor.cpp | 236 +++++----- .../ViewItem/projectdbmodel.cpp | 140 +++--- .../qetgraphicsitem/ViewItem/projectdbmodel.h | 20 +- .../ViewItem/qetgraphicsheaderitem.cpp | 118 ++--- .../ViewItem/qetgraphicsheaderitem.h | 20 +- .../ViewItem/qetgraphicstableitem.cpp | 256 +++++----- .../ViewItem/qetgraphicstableitem.h | 22 +- .../ui/graphicstablepropertieseditor.cpp | 56 +-- .../ui/graphicstablepropertieseditor.h | 6 +- .../ui/projectdbmodelpropertieswidget.cpp | 22 +- .../ui/projectdbmodelpropertieswidget.h | 6 +- sources/qetgraphicsitem/conductor.cpp | 326 ++++++------- sources/qetgraphicsitem/conductor.h | 10 +- sources/qetgraphicsitem/conductortextitem.cpp | 52 +-- sources/qetgraphicsitem/diagramimageitem.cpp | 76 +-- sources/qetgraphicsitem/diagramtextitem.cpp | 104 ++--- .../dynamicelementtextitem.cpp | 280 +++++------ .../qetgraphicsitem/dynamicelementtextitem.h | 10 +- sources/qetgraphicsitem/element.cpp | 394 ++++++++-------- sources/qetgraphicsitem/element.h | 8 +- .../qetgraphicsitem/elementtextitemgroup.cpp | 138 +++--- .../qetgraphicsitem/elementtextitemgroup.h | 8 +- sources/qetgraphicsitem/masterelement.cpp | 80 ++-- sources/qetgraphicsitem/masterelement.h | 10 +- sources/qetgraphicsitem/qetgraphicsitem.cpp | 58 +-- sources/qetgraphicsitem/qetshapeitem.cpp | 246 +++++----- sources/qetgraphicsitem/qetshapeitem.h | 8 +- .../qetgraphicsitem/qgraphicsitemutility.cpp | 24 +- sources/qetgraphicsitem/reportelement.cpp | 28 +- sources/qetgraphicsitem/reportelement.h | 6 +- sources/qetgraphicsitem/simpleelement.cpp | 26 +- sources/qetgraphicsitem/simpleelement.h | 6 +- sources/qetgraphicsitem/slaveelement.cpp | 44 +- sources/qetgraphicsitem/terminal.cpp | 16 +- sources/qetinformation.cpp | 34 +- sources/qetproject.cpp | 440 +++++++++--------- sources/qetxml.h | 2 +- sources/recentfiles.cpp | 12 +- sources/richtext/richtexteditor.cpp | 4 +- sources/titleblock/qettemplateeditor.cpp | 22 +- sources/titleblock/templatescollection.cpp | 14 +- sources/titleblockproperties.cpp | 16 +- sources/titleblocktemplate.h | 4 +- sources/titleblocktemplaterenderer.cpp | 2 +- .../abstractelementpropertieseditorwidget.h | 6 +- sources/ui/alignmenttextdialog.cpp | 6 +- sources/ui/borderpropertieswidget.cpp | 38 +- sources/ui/borderpropertieswidget.h | 6 +- sources/ui/compositetexteditdialog.cpp | 20 +- sources/ui/compositetexteditdialog.h | 12 +- sources/ui/conductorpropertiesdialog.cpp | 40 +- sources/ui/conductorpropertieswidget.cpp | 128 ++--- .../configpage/generalconfigurationpage.cpp | 42 +- sources/ui/configsaveloaderwidget.h | 14 +- sources/ui/diagramcontextwidget.cpp | 48 +- sources/ui/diagrampropertiesdialog.cpp | 32 +- sources/ui/diagrampropertiesdialog.h | 6 +- .../ui/diagrampropertieseditordockwidget.cpp | 36 +- sources/ui/diagramselection.cpp | 16 +- sources/ui/dialogwaiting.cpp | 46 +- sources/ui/dynamicelementtextitemeditor.cpp | 34 +- sources/ui/dynamicelementtextitemeditor.h | 22 +- sources/ui/dynamicelementtextmodel.cpp | 240 +++++----- sources/ui/dynamicelementtextmodel.h | 10 +- sources/ui/elementinfopartwidget.cpp | 78 ++-- sources/ui/elementinfowidget.cpp | 120 ++--- sources/ui/elementinfowidget.h | 6 +- sources/ui/elementpropertieswidget.cpp | 116 ++--- sources/ui/imagepropertieswidget.cpp | 72 +-- sources/ui/imagepropertieswidget.h | 6 +- sources/ui/importelementtextpatterndialog.cpp | 20 +- sources/ui/importelementtextpatterndialog.h | 10 +- sources/ui/inditextpropertieswidget.cpp | 62 +-- sources/ui/inditextpropertieswidget.h | 6 +- sources/ui/linksingleelementwidget.cpp | 142 +++--- sources/ui/linksingleelementwidget.h | 16 +- sources/ui/marginseditdialog.cpp | 12 +- sources/ui/marginseditdialog.h | 6 +- sources/ui/masterpropertieswidget.cpp | 2 +- sources/ui/masterpropertieswidget.h | 6 +- sources/ui/potentialselectordialog.cpp | 60 +-- sources/ui/potentialselectordialog.h | 26 +- sources/ui/projectpropertiesdialog.cpp | 34 +- sources/ui/projectpropertiesdialog.h | 6 +- .../ui/shapegraphicsitempropertieswidget.cpp | 74 +-- .../ui/shapegraphicsitempropertieswidget.h | 6 +- sources/ui/titleblockpropertieswidget.cpp | 134 +++--- sources/ui/xrefpropertieswidget.cpp | 72 +-- sources/ui/xrefpropertieswidget.h | 6 +- .../changeelementinformationcommand.cpp | 20 +- .../changeelementinformationcommand.h | 6 +- .../undocommand/changetitleblockcommand.cpp | 12 +- sources/undocommand/changetitleblockcommand.h | 6 +- .../deleteqgraphicsitemcommand.cpp | 46 +- sources/undocommand/itemmodelcommand.cpp | 64 +-- sources/undocommand/itemmodelcommand.h | 12 +- sources/undocommand/linkelementcommand.cpp | 108 ++--- sources/undocommand/linkelementcommand.h | 10 +- .../undocommand/rotateselectioncommand.cpp | 14 +- sources/undocommand/rotateselectioncommand.h | 6 +- sources/undocommand/rotatetextscommand.cpp | 10 +- sources/undocommand/rotatetextscommand.h | 8 +- sources/utils/conductorcreator.h | 8 +- 274 files changed, 6823 insertions(+), 6756 deletions(-) diff --git a/SingleApplication/singleapplication.cpp b/SingleApplication/singleapplication.cpp index ebf6f38b2..66327b952 100644 --- a/SingleApplication/singleapplication.cpp +++ b/SingleApplication/singleapplication.cpp @@ -34,12 +34,12 @@ #include "singleapplication_p.h" /** - * @brief Constructor. Checks and fires up LocalServer or closes the program - * if another instance already exists - * @param argc - * @param argv - * @param {bool} allowSecondaryInstances - */ + @brief Constructor. Checks and fires up LocalServer or closes the program + if another instance already exists + @param argc + @param argv + @param {bool} allowSecondaryInstances +*/ SingleApplication::SingleApplication( int &argc, char *argv[], bool allowSecondary, Options options, int timeout ) : app_t( argc, argv ), d_ptr( new SingleApplicationPrivate( this ) ) { @@ -142,8 +142,8 @@ SingleApplication::SingleApplication( int &argc, char *argv[], bool allowSeconda } /** - * @brief Destructor - */ + @brief Destructor +*/ SingleApplication::~SingleApplication() { Q_D(SingleApplication); diff --git a/SingleApplication/singleapplication.h b/SingleApplication/singleapplication.h index 2528daed5..5a9ab8318 100644 --- a/SingleApplication/singleapplication.h +++ b/SingleApplication/singleapplication.h @@ -36,10 +36,10 @@ class SingleApplicationPrivate; /** - * @brief The SingleApplication class handles multiple instances of the same - * Application - * @see QCoreApplication - */ + @brief The SingleApplication class handles multiple instances of the same + Application + @see QCoreApplication +*/ class SingleApplication : public QAPPLICATION_CLASS { Q_OBJECT @@ -48,15 +48,15 @@ class SingleApplication : public QAPPLICATION_CLASS public: /** - * @brief Mode of operation of SingleApplication. - * Whether the block should be user-wide or system-wide and whether the - * primary instance should be notified when a secondary instance had been - * started. - * @note Operating system can restrict the shared memory blocks to the same - * user, in which case the User/System modes will have no effect and the - * block will be user wide. - * @enum - */ + @brief Mode of operation of SingleApplication. + Whether the block should be user-wide or system-wide and whether the + primary instance should be notified when a secondary instance had been + started. + @note Operating system can restrict the shared memory blocks to the same + user, in which case the User/System modes will have no effect and the + block will be user wide. + @enum + */ enum Mode { User = 1 << 0, System = 1 << 1, @@ -67,59 +67,59 @@ class SingleApplication : public QAPPLICATION_CLASS Q_DECLARE_FLAGS(Options, Mode) /** - * @brief Intitializes a SingleApplication instance with argc command line - * arguments in argv - * @arg {int &} argc - Number of arguments in argv - * @arg {const char *[]} argv - Supplied command line arguments - * @arg {bool} allowSecondary - Whether to start the instance as secondary - * if there is already a primary instance. - * @arg {Mode} mode - Whether for the SingleApplication block to be applied - * User wide or System wide. - * @arg {int} timeout - Timeout to wait in milliseconds. - * @note argc and argv may be changed as Qt removes arguments that it - * recognizes - * @note Mode::SecondaryNotification only works if set on both the primary - * instance and the secondary instance. - * @note The timeout is just a hint for the maximum time of blocking - * operations. It does not guarantee that the SingleApplication - * initialisation will be completed in given time, though is a good hint. - * Usually 4*timeout would be the worst case (fail) scenario. - * @see See the corresponding QAPPLICATION_CLASS constructor for reference - */ + @brief Intitializes a SingleApplication instance with argc command line + arguments in argv + @arg {int &} argc - Number of arguments in argv + @arg {const char *[]} argv - Supplied command line arguments + @arg {bool} allowSecondary - Whether to start the instance as secondary + if there is already a primary instance. + @arg {Mode} mode - Whether for the SingleApplication block to be applied + User wide or System wide. + @arg {int} timeout - Timeout to wait in milliseconds. + @note argc and argv may be changed as Qt removes arguments that it + recognizes + @note Mode::SecondaryNotification only works if set on both the primary + instance and the secondary instance. + @note The timeout is just a hint for the maximum time of blocking + operations. It does not guarantee that the SingleApplication + initialisation will be completed in given time, though is a good hint. + Usually 4*timeout would be the worst case (fail) scenario. + @see See the corresponding QAPPLICATION_CLASS constructor for reference + */ explicit SingleApplication( int &argc, char *argv[], bool allowSecondary = false, Options options = Mode::User, int timeout = 1000 ); ~SingleApplication(); /** - * @brief Returns if the instance is the primary instance - * @returns {bool} - */ + @brief Returns if the instance is the primary instance + @returns {bool} + */ bool isPrimary(); /** - * @brief Returns if the instance is a secondary instance - * @returns {bool} - */ + @brief Returns if the instance is a secondary instance + @returns {bool} + */ bool isSecondary(); /** - * @brief Returns a unique identifier for the current instance - * @returns {qint32} - */ + @brief Returns a unique identifier for the current instance + @returns {qint32} + */ quint32 instanceId(); /** - * @brief Returns the process ID (PID) of the primary instance - * @returns {qint64} - */ + @brief Returns the process ID (PID) of the primary instance + @returns {qint64} + */ qint64 primaryPid(); /** - * @brief Sends a message to the primary instance. Returns true on success. - * @param {int} timeout - Timeout for connecting - * @returns {bool} - * @note sendMessage() will return false if invoked from the primary - * instance. - */ + @brief Sends a message to the primary instance. Returns true on success. + @param {int} timeout - Timeout for connecting + @returns {bool} + @note sendMessage() will return false if invoked from the primary + instance. + */ bool sendMessage( QByteArray message, int timeout = 100 ); Q_SIGNALS: diff --git a/SingleApplication/singleapplication_p.cpp b/SingleApplication/singleapplication_p.cpp index 539ffeddf..93112bbcf 100644 --- a/SingleApplication/singleapplication_p.cpp +++ b/SingleApplication/singleapplication_p.cpp @@ -258,8 +258,8 @@ qint64 SingleApplicationPrivate::primaryPid() } /** - * @brief Executed when a connection has been made to the LocalServer - */ + @brief Executed when a connection has been made to the LocalServer +*/ void SingleApplicationPrivate::slotConnectionEstablished() { QLocalSocket *nextConnSocket = server->nextPendingConnection(); diff --git a/sources/ElementsCollection/elementcollectionhandler.cpp b/sources/ElementsCollection/elementcollectionhandler.cpp index 4aa390792..4ef945e17 100644 --- a/sources/ElementsCollection/elementcollectionhandler.cpp +++ b/sources/ElementsCollection/elementcollectionhandler.cpp @@ -298,9 +298,9 @@ ElementsLocation ECHSToXml::copy() /******************************************************/ /** - * @brief ElementCollectionHandler::ElementCollectionHandler - * @param widget - */ + @brief ElementCollectionHandler::ElementCollectionHandler + @param widget +*/ ElementCollectionHandler::ElementCollectionHandler() {} ElementCollectionHandler::~ElementCollectionHandler() @@ -309,14 +309,14 @@ ElementCollectionHandler::~ElementCollectionHandler() } /** - * @brief ElementCollectionHandler::copy - * Copy the content of collection represented by source to the collection represented by destination. - * Destination must be a directory, else the copy do nothing and return a null ElementLocation - * if destination have an item with the same name of source, a dialog ask to user what to do. - * @param source - * @param destination - * @return - */ + @brief ElementCollectionHandler::copy + Copy the content of collection represented by source to the collection represented by destination. + Destination must be a directory, else the copy do nothing and return a null ElementLocation + if destination have an item with the same name of source, a dialog ask to user what to do. + @param source + @param destination + @return +*/ ElementsLocation ElementCollectionHandler::copy(ElementsLocation &source, ElementsLocation &destination) { if (!source.exist() || !destination.exist() || destination.isElement()) return ElementsLocation(); @@ -332,14 +332,14 @@ ElementsLocation ElementCollectionHandler::copy(ElementsLocation &source, Elemen } /** - * @brief ElementCollectionHandler::createDir - * Create a directorie with name @name as child of @parent. - * Parent must be a directory - * @param parent : parent of the dir to create - * @param name : name of directorie to create - * @param name_list : translations of the directorie name - * @return : ElementsLocation that represent the new directorie, location can be null if an error was occurred - */ + @brief ElementCollectionHandler::createDir + Create a directorie with name @name as child of @parent. + Parent must be a directory + @param parent : parent of the dir to create + @param name : name of directorie to create + @param name_list : translations of the directorie name + @return : ElementsLocation that represent the new directorie, location can be null if an error was occurred +*/ ElementsLocation ElementCollectionHandler::createDir(ElementsLocation &parent, const QString &name, const NamesList &name_list) { //Parent must be a directorie and writable @@ -393,13 +393,13 @@ ElementsLocation ElementCollectionHandler::createDir(ElementsLocation &parent, c } /** - * @brief ElementCollectionHandler::importFromProject - * Import the element represented by @location to the embedded collection of @project at the same path. - * @location must represente an element owned by a project embedded collection - * @param project : project where copy the element - * @param location : location to copy - * @return true if import with success - */ + @brief ElementCollectionHandler::importFromProject + Import the element represented by @location to the embedded collection of @project at the same path. + @location must represente an element owned by a project embedded collection + @param project : project where copy the element + @param location : location to copy + @return true if import with success +*/ bool ElementCollectionHandler::importFromProject(QETProject *project, ElementsLocation &location) { if (!(location.isElement() && location.exist() && location.isProject())) return false; @@ -436,12 +436,12 @@ bool ElementCollectionHandler::importFromProject(QETProject *project, ElementsLo } /** - * @brief ElementCollectionHandler::setNames - * Set the names stored in @name_list as the names of the item represented by location - * @param location : location to change the names - * @param name_list : NamesList to use - * @return return true if success - */ + @brief ElementCollectionHandler::setNames + Set the names stored in @name_list as the names of the item represented by location + @param location : location to change the names + @param name_list : NamesList to use + @return return true if success +*/ bool ElementCollectionHandler::setNames(ElementsLocation &location, const NamesList &name_list) { if ( !(location.exist() && location.isWritable()) ) { diff --git a/sources/ElementsCollection/elementcollectionhandler.h b/sources/ElementsCollection/elementcollectionhandler.h index cdcc5281d..bbfc0568b 100644 --- a/sources/ElementsCollection/elementcollectionhandler.h +++ b/sources/ElementsCollection/elementcollectionhandler.h @@ -24,9 +24,9 @@ class QWidget; /** - * @brief The ECHStrategy class - * Abstract class for manage copy of directory or element from a collection to another - */ + @brief The ECHStrategy class + Abstract class for manage copy of directory or element from a collection to another +*/ class ECHStrategy { public: @@ -38,9 +38,9 @@ class ECHStrategy }; /** - * @brief The ECHSFileToFile class - * Manage the copy of directory or element from a file system collection to another file system collection - */ + @brief The ECHSFileToFile class + Manage the copy of directory or element from a file system collection to another file system collection +*/ class ECHSFileToFile : public ECHStrategy { public: @@ -53,9 +53,9 @@ class ECHSFileToFile : public ECHStrategy }; /** - * @brief The ECHSXmlToFile class - * Manage the copy of a directory or element from an xml collection to a file. - */ + @brief The ECHSXmlToFile class + Manage the copy of a directory or element from an xml collection to a file. +*/ class ECHSXmlToFile : public ECHStrategy { public: @@ -68,10 +68,10 @@ class ECHSXmlToFile : public ECHStrategy }; /** - * @brief The ECHSToXml class - * Manage the copy of a directory or element from a collection (no matter if the source is a file system collection or an xml collection) - * to an xml collection - */ + @brief The ECHSToXml class + Manage the copy of a directory or element from a collection (no matter if the source is a file system collection or an xml collection) + to an xml collection +*/ class ECHSToXml : public ECHStrategy { public: @@ -80,10 +80,10 @@ class ECHSToXml : public ECHStrategy }; /** - * @brief The ElementCollectionHandler class - * Provide several method to copy element or directory from a collection - * to another collection. - */ + @brief The ElementCollectionHandler class + Provide several method to copy element or directory from a collection + to another collection. +*/ class ElementCollectionHandler { public: diff --git a/sources/ElementsCollection/elementcollectionitem.cpp b/sources/ElementsCollection/elementcollectionitem.cpp index c6da9b3d7..7a9f70c59 100644 --- a/sources/ElementsCollection/elementcollectionitem.cpp +++ b/sources/ElementsCollection/elementcollectionitem.cpp @@ -19,16 +19,16 @@ #include "elementcollectionitem.h" /** - * @brief ElementCollectionItem::ElementCollectionItem - * Constructor - */ + @brief ElementCollectionItem::ElementCollectionItem + Constructor +*/ ElementCollectionItem::ElementCollectionItem() {} /** - * @brief ElementCollectionItem::clearData - * Reset the data - */ + @brief ElementCollectionItem::clearData + Reset the data +*/ void ElementCollectionItem::clearData() { setText(QString()); @@ -38,13 +38,13 @@ void ElementCollectionItem::clearData() } /** - * @brief ElementCollectionItem::lastItemForPath - * Return the last existing item in this ElementCollectionItem hierarchy according to the given path. - * Next_item is the first non existing item in this hierarchy according to the given path. - * @param path : The path to find last item. The path must be in form : path/otherPath/.../.../myElement.elmt. - * @param no_found_path : The first item that not exist in this hierarchy - * @return : The last item that exist in this hierarchy, or nullptr can't find (an error was occurred, or path already exist) - */ + @brief ElementCollectionItem::lastItemForPath + Return the last existing item in this ElementCollectionItem hierarchy according to the given path. + Next_item is the first non existing item in this hierarchy according to the given path. + @param path : The path to find last item. The path must be in form : path/otherPath/.../.../myElement.elmt. + @param no_found_path : The first item that not exist in this hierarchy + @return : The last item that exist in this hierarchy, or nullptr can't find (an error was occurred, or path already exist) +*/ ElementCollectionItem *ElementCollectionItem::lastItemForPath(const QString &path, QString &no_found_path) { QStringList str_list = path.split("/"); @@ -67,11 +67,11 @@ ElementCollectionItem *ElementCollectionItem::lastItemForPath(const QString &pat } /** - * @brief ElementCollectionItem::childWithCollectionName - * Return the child with the collection name @name, else return nullptr - * @param name - * @return - */ + @brief ElementCollectionItem::childWithCollectionName + Return the child with the collection name @name, else return nullptr + @param name + @return +*/ ElementCollectionItem *ElementCollectionItem::childWithCollectionName(const QString& name) const { rowCount(); @@ -85,10 +85,10 @@ ElementCollectionItem *ElementCollectionItem::childWithCollectionName(const QStr } /** - * @brief ElementCollectionItem::directChilds - * Return the direct child of this item - * @return - */ + @brief ElementCollectionItem::directChilds + Return the direct child of this item + @return +*/ QList ElementCollectionItem::directChilds() const { QList item_list; @@ -100,12 +100,12 @@ QList ElementCollectionItem::directChilds() const } /** - * @brief ElementCollectionItem::rowForInsertItem - * Return the row for insert a new child item to this item with name @collection_name. - * If row can't be found (collection_name is null, or already exist) return -1; - * @param collection_name - * @return - */ + @brief ElementCollectionItem::rowForInsertItem + Return the row for insert a new child item to this item with name @collection_name. + If row can't be found (collection_name is null, or already exist) return -1; + @param collection_name + @return +*/ int ElementCollectionItem::rowForInsertItem(const QString &name) { if (name.isEmpty()) @@ -137,10 +137,10 @@ int ElementCollectionItem::rowForInsertItem(const QString &name) } /** - * @brief ElementCollectionItem::itemAtPath - * @param path - * @return the item at path or nullptr if doesn't exist - */ + @brief ElementCollectionItem::itemAtPath + @param path + @return the item at path or nullptr if doesn't exist +*/ ElementCollectionItem *ElementCollectionItem::itemAtPath(const QString &path) { QStringList str_list = path.split("/"); @@ -160,9 +160,9 @@ ElementCollectionItem *ElementCollectionItem::itemAtPath(const QString &path) } /** - * @brief ElementCollectionItem::elementsDirectChild - * @return The direct element child of this item - */ + @brief ElementCollectionItem::elementsDirectChild + @return The direct element child of this item +*/ QList ElementCollectionItem::elementsDirectChild() const { QList element_child; @@ -177,9 +177,9 @@ QList ElementCollectionItem::elementsDirectChild() cons } /** - * @brief ElementCollectionItem::directoriesDirectChild - * @return the direct directory child of this item - */ + @brief ElementCollectionItem::directoriesDirectChild + @return the direct directory child of this item +*/ QList ElementCollectionItem::directoriesDirectChild() const { QList dir_child; @@ -194,9 +194,9 @@ QList ElementCollectionItem::directoriesDirectChild() c } /** - * @brief ElementCollectionItem::elementsChild - * @return Every elements child (direct and indirect) of this item - */ + @brief ElementCollectionItem::elementsChild + @return Every elements child (direct and indirect) of this item +*/ QList ElementCollectionItem::elementsChild() const { QList list = elementsDirectChild(); @@ -208,9 +208,9 @@ QList ElementCollectionItem::elementsChild() const } /** - * @brief ElementCollectionItem::directoriesChild - * @return Every directories child (direct and indirect) of this item - */ + @brief ElementCollectionItem::directoriesChild + @return Every directories child (direct and indirect) of this item +*/ QList ElementCollectionItem::directoriesChild() const { QList list = directoriesDirectChild(); @@ -224,9 +224,9 @@ QList ElementCollectionItem::directoriesChild() const } /** - * @brief ElementCollectionItem::items - * @return every childs of this item (direct and indirect childs) - */ + @brief ElementCollectionItem::items + @return every childs of this item (direct and indirect childs) +*/ QList ElementCollectionItem::items() const { QList list; diff --git a/sources/ElementsCollection/elementcollectionitem.h b/sources/ElementsCollection/elementcollectionitem.h index f84ebd3aa..2e092ed6d 100644 --- a/sources/ElementsCollection/elementcollectionitem.h +++ b/sources/ElementsCollection/elementcollectionitem.h @@ -21,11 +21,11 @@ #include /** - * @brief The ElementCollectionItem class - * This class represent a item (a directory or an element) in a element collection. - * This class must be herited for specialisation. - * This item is used by ElementsCollectionModel for manage the elements collection - */ + @brief The ElementCollectionItem class + This class represent a item (a directory or an element) in a element collection. + This class must be herited for specialisation. + This item is used by ElementsCollectionModel for manage the elements collection +*/ class ElementCollectionItem : public QStandardItem { public: diff --git a/sources/ElementsCollection/elementscollectionmodel.cpp b/sources/ElementsCollection/elementscollectionmodel.cpp index 54193c79a..4dfb2284a 100644 --- a/sources/ElementsCollection/elementscollectionmodel.cpp +++ b/sources/ElementsCollection/elementscollectionmodel.cpp @@ -99,15 +99,15 @@ QStringList ElementsCollectionModel::mimeTypes() const } /** - * @brief ElementsCollectionModel::canDropMimeData - * Reimplemented from QStandardItemModel - * @param data - * @param action - * @param row - * @param column - * @param parent - * @return - */ + @brief ElementsCollectionModel::canDropMimeData + Reimplemented from QStandardItemModel + @param data + @param action + @param row + @param column + @param parent + @return +*/ bool ElementsCollectionModel::canDropMimeData(const QMimeData *data, Qt::DropAction action, int row, diff --git a/sources/ElementsCollection/elementscollectionwidget.cpp b/sources/ElementsCollection/elementscollectionwidget.cpp index d8f512723..df750a57f 100644 --- a/sources/ElementsCollection/elementscollectionwidget.cpp +++ b/sources/ElementsCollection/elementscollectionwidget.cpp @@ -38,10 +38,10 @@ #include /** - * @brief ElementsCollectionWidget::ElementsCollectionWidget - * Default constructor. - * @param parent : parent widget of this widget. - */ + @brief ElementsCollectionWidget::ElementsCollectionWidget + Default constructor. + @param parent : parent widget of this widget. +*/ ElementsCollectionWidget::ElementsCollectionWidget(QWidget *parent): QWidget(parent), m_model(nullptr) @@ -66,9 +66,9 @@ ElementsCollectionWidget::ElementsCollectionWidget(QWidget *parent): } /** - * @brief ElementsCollectionWidget::expandFirstItems - * Expand each first item in the tree view - */ + @brief ElementsCollectionWidget::expandFirstItems + Expand each first item in the tree view +*/ void ElementsCollectionWidget::expandFirstItems() { if (!m_model) @@ -79,10 +79,10 @@ void ElementsCollectionWidget::expandFirstItems() } /** - * @brief ElementsCollectionWidget::addProject - * Add @project to be displayed - * @param project - */ + @brief ElementsCollectionWidget::addProject + Add @project to be displayed + @param project +*/ void ElementsCollectionWidget::addProject(QETProject *project) { if (m_model) @@ -103,10 +103,10 @@ void ElementsCollectionWidget::removeProject(QETProject *project) { } /** - * @brief ElementsCollectionWidget::highlightUnusedElement - * highlight the unused element - * @See ElementsCollectionModel::highlightUnusedElement() - */ + @brief ElementsCollectionWidget::highlightUnusedElement + highlight the unused element + @See ElementsCollectionModel::highlightUnusedElement() +*/ void ElementsCollectionWidget::highlightUnusedElement() { if (m_model) @@ -114,10 +114,10 @@ void ElementsCollectionWidget::highlightUnusedElement() } /** - * @brief ElementsCollectionWidget::setCurrentLocation - * Set the current item to be the item for @location - * @param location - */ + @brief ElementsCollectionWidget::setCurrentLocation + Set the current item to be the item for @location + @param location +*/ void ElementsCollectionWidget::setCurrentLocation(const ElementsLocation &location) { if (!location.exist()) @@ -151,9 +151,9 @@ void ElementsCollectionWidget::setUpAction() } /** - * @brief ElementsCollectionWidget::setUpWidget - * Setup this widget - */ + @brief ElementsCollectionWidget::setUpWidget + Setup this widget +*/ void ElementsCollectionWidget::setUpWidget() { //Setup the main layout @@ -188,9 +188,9 @@ void ElementsCollectionWidget::setUpWidget() } /** - * @brief ElementsCollectionWidget::setUpConnection - * Setup the connection used in this widget - */ + @brief ElementsCollectionWidget::setUpConnection + Setup the connection used in this widget +*/ void ElementsCollectionWidget::setUpConnection() { connect(m_tree_view, &QTreeView::customContextMenuRequested, this, &ElementsCollectionWidget::customContextMenu); @@ -221,10 +221,10 @@ void ElementsCollectionWidget::setUpConnection() } /** - * @brief ElementsCollectionWidget::customContextMenu - * Display the context menu of this widget at @point - * @param point - */ + @brief ElementsCollectionWidget::customContextMenu + Display the context menu of this widget at @point + @param point +*/ void ElementsCollectionWidget::customContextMenu(const QPoint &point) { m_index_at_context_menu = m_tree_view->indexAt(point); @@ -283,9 +283,9 @@ void ElementsCollectionWidget::customContextMenu(const QPoint &point) } /** - * @brief ElementsCollectionWidget::openDir - * Open the directory represented by the current selected item - */ + @brief ElementsCollectionWidget::openDir + Open the directory represented by the current selected item +*/ void ElementsCollectionWidget::openDir() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -309,9 +309,9 @@ void ElementsCollectionWidget::openDir() } /** - * @brief ElementsCollectionWidget::editElement - * Edit the element represented by the current selected item - */ + @brief ElementsCollectionWidget::editElement + Edit the element represented by the current selected item +*/ void ElementsCollectionWidget::editElement() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -328,9 +328,9 @@ void ElementsCollectionWidget::editElement() } /** - * @brief ElementsCollectionWidget::deleteElement - * Delete the element represented by the current selected item. - */ + @brief ElementsCollectionWidget::deleteElement + Delete the element represented by the current selected item. +*/ void ElementsCollectionWidget::deleteElement() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -360,9 +360,9 @@ void ElementsCollectionWidget::deleteElement() } /** - * @brief ElementsCollectionWidget::deleteDirectory - * Delete directory represented by the current selected item - */ + @brief ElementsCollectionWidget::deleteDirectory + Delete directory represented by the current selected item +*/ void ElementsCollectionWidget::deleteDirectory() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -394,9 +394,9 @@ void ElementsCollectionWidget::deleteDirectory() } /** - * @brief ElementsCollectionWidget::editDirectory - * Edit the directory represented by the current selected item - */ + @brief ElementsCollectionWidget::editDirectory + Edit the directory represented by the current selected item +*/ void ElementsCollectionWidget::editDirectory() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -414,9 +414,9 @@ void ElementsCollectionWidget::editDirectory() } /** - * @brief ElementsCollectionWidget::newDirectory - * Create a new directory - */ + @brief ElementsCollectionWidget::newDirectory + Create a new directory +*/ void ElementsCollectionWidget::newDirectory() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -433,9 +433,9 @@ void ElementsCollectionWidget::newDirectory() } /** - * @brief ElementsCollectionWidget::newElement - * Create a new element. - */ + @brief ElementsCollectionWidget::newElement + Create a new element. +*/ void ElementsCollectionWidget::newElement() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -459,9 +459,9 @@ void ElementsCollectionWidget::newElement() } /** - * @brief ElementsCollectionWidget::showThisDir - * Hide all directories except the pointed dir; - */ + @brief ElementsCollectionWidget::showThisDir + Hide all directories except the pointed dir; +*/ void ElementsCollectionWidget::showThisDir() { //Disable the yellow background of the previous index @@ -487,10 +487,10 @@ void ElementsCollectionWidget::showThisDir() } /** - * @brief ElementsCollectionWidget::resetShowThisDir - * reset show this dir, all collection are show. - * If search field isn't empty, apply the search after show all collection - */ + @brief ElementsCollectionWidget::resetShowThisDir + reset show this dir, all collection are show. + If search field isn't empty, apply the search after show all collection +*/ void ElementsCollectionWidget::resetShowThisDir() { if (m_showed_index.isValid()) @@ -505,9 +505,9 @@ void ElementsCollectionWidget::resetShowThisDir() } /** - * @brief ElementsCollectionWidget::dirProperties - * Open an informative dialog about the curent index - */ + @brief ElementsCollectionWidget::dirProperties + Open an informative dialog about the curent index +*/ void ElementsCollectionWidget::dirProperties() { ElementCollectionItem *eci = elementCollectionItemForIndex(m_index_at_context_menu); @@ -527,8 +527,8 @@ void ElementsCollectionWidget::dirProperties() } /** - * @brief ElementsCollectionWidget::reload, the displayed collections. - */ + @brief ElementsCollectionWidget::reload, the displayed collections. +*/ void ElementsCollectionWidget::reload() { m_progress_bar->show(); @@ -554,9 +554,9 @@ void ElementsCollectionWidget::reload() } /** - * @brief ElementsCollectionWidget::loadingFinished - * Process when collection finished to be loaded - */ + @brief ElementsCollectionWidget::loadingFinished + Process when collection finished to be loaded +*/ void ElementsCollectionWidget::loadingFinished() { if (m_new_model) @@ -579,11 +579,11 @@ void ElementsCollectionWidget::loadingFinished() } /** - * @brief ElementsCollectionWidget::locationWasSaved - * This method is connected with the signal savedToLocation of Element editor (see ElementsCollectionWidget::editElement()) - * Update or add the item represented by location to m_model - * @param location - */ + @brief ElementsCollectionWidget::locationWasSaved + This method is connected with the signal savedToLocation of Element editor (see ElementsCollectionWidget::editElement()) + Update or add the item represented by location to m_model + @param location +*/ void ElementsCollectionWidget::locationWasSaved(const ElementsLocation& location) { //Because this method update an item in the model, location must @@ -606,10 +606,10 @@ void ElementsCollectionWidget::locationWasSaved(const ElementsLocation& location } /** - * @brief ElementsCollectionWidget::search - * Search every item (directory or element) that match the text of m_search_field - * and display it, other item who does not match @text is hidden - */ + @brief ElementsCollectionWidget::search + Search every item (directory or element) that match the text of m_search_field + and display it, other item who does not match @text is hidden +*/ void ElementsCollectionWidget::search() { QString text = m_search_field->text(); @@ -655,10 +655,10 @@ void ElementsCollectionWidget::search() } /** - * @brief ElementsCollectionWidget::hideCollection - * Hide all collection displayed in this tree - * @param hide- true = hide , false = visible - */ + @brief ElementsCollectionWidget::hideCollection + Hide all collection displayed in this tree + @param hide- true = hide , false = visible +*/ void ElementsCollectionWidget::hideCollection(bool hide) { for (int i=0 ; i rowCount() ; i++) @@ -666,12 +666,12 @@ void ElementsCollectionWidget::hideCollection(bool hide) } /** - * @brief ElementsCollectionWidget::hideItem - * Hide the item @index. If @recursive is true, hide all subchilds of @index - * @param hide- true = hide , false = visible - * @param index- index to hide - * @param recursive- true = apply to child , false = only for @index - */ + @brief ElementsCollectionWidget::hideItem + Hide the item @index. If @recursive is true, hide all subchilds of @index + @param hide- true = hide , false = visible + @param index- index to hide + @param recursive- true = apply to child , false = only for @index +*/ void ElementsCollectionWidget::hideItem(bool hide, const QModelIndex &index, bool recursive) { m_tree_view->setRowHidden(index.row(), index.parent(), hide); @@ -682,14 +682,14 @@ void ElementsCollectionWidget::hideItem(bool hide, const QModelIndex &index, boo } /** - * @brief ElementsCollectionWidget::showAndExpandItem - * Show the item @index and expand it. - * If parent is true, ensure parents of @index is show and expanded - * If child is true, ensure all childs of @index is show and expended - * @param index- index to show - * @param parent- Apply to parent - * @param child- Apply to all childs - */ + @brief ElementsCollectionWidget::showAndExpandItem + Show the item @index and expand it. + If parent is true, ensure parents of @index is show and expanded + If child is true, ensure all childs of @index is show and expended + @param index- index to show + @param parent- Apply to parent + @param child- Apply to all childs +*/ void ElementsCollectionWidget::showAndExpandItem(const QModelIndex &index, bool parent, bool child) { if (index.isValid()) { @@ -702,10 +702,10 @@ void ElementsCollectionWidget::showAndExpandItem(const QModelIndex &index, bool } /** - * @brief ElementsCollectionWidget::elementCollectionItemForIndex - * @param index - * @return The internal pointer of index casted to ElementCollectionItem; - */ + @brief ElementsCollectionWidget::elementCollectionItemForIndex + @param index + @return The internal pointer of index casted to ElementCollectionItem; +*/ ElementCollectionItem *ElementsCollectionWidget::elementCollectionItemForIndex(const QModelIndex &index) { if (!index.isValid()) return nullptr; diff --git a/sources/ElementsCollection/elementscollectionwidget.h b/sources/ElementsCollection/elementscollectionwidget.h index e3a2ba92e..612981680 100644 --- a/sources/ElementsCollection/elementscollectionwidget.h +++ b/sources/ElementsCollection/elementscollectionwidget.h @@ -34,11 +34,11 @@ class QETProject; class ElementsTreeView; /** - * @brief The ElementsCollectionWidget class - * This widget embedd a tree view that display the element collection (common, custom, embedded) - * and all action needed to use this widget. - * This is the element collection widget used in the diagram editor. - */ + @brief The ElementsCollectionWidget class + This widget embedd a tree view that display the element collection (common, custom, embedded) + and all action needed to use this widget. + This is the element collection widget used in the diagram editor. +*/ class ElementsCollectionWidget : public QWidget { Q_OBJECT diff --git a/sources/ElementsCollection/elementslocation.cpp b/sources/ElementsCollection/elementslocation.cpp index 40d55ce0e..87d1bc477 100644 --- a/sources/ElementsCollection/elementslocation.cpp +++ b/sources/ElementsCollection/elementslocation.cpp @@ -125,7 +125,7 @@ bool ElementsLocation::operator!=(const ElementsLocation &other) const { this method don't return the extension name. For exemple if this location represent an element they return myElement. @see fileName() - */ +*/ QString ElementsLocation::baseName() const { QRegExp regexp("^.*([^/]+)\\.elmt$"); if (regexp.exactMatch(m_collection_path)) { diff --git a/sources/ElementsCollection/elementstreeview.cpp b/sources/ElementsCollection/elementstreeview.cpp index b04f473bf..53d50257e 100644 --- a/sources/ElementsCollection/elementstreeview.cpp +++ b/sources/ElementsCollection/elementstreeview.cpp @@ -29,18 +29,18 @@ static int MAX_DND_PIXMAP_WIDTH = 500; static int MAX_DND_PIXMAP_HEIGHT = 375; /** - * @brief ElementsTreeView::ElementsTreeView - * @param parent - */ + @brief ElementsTreeView::ElementsTreeView + @param parent +*/ ElementsTreeView::ElementsTreeView(QWidget *parent) : QTreeView(parent) {} /** - * @brief ElementsTreeView::startDrag - * Reimplemented from QTreeView - * @param supportedActions - */ + @brief ElementsTreeView::startDrag + Reimplemented from QTreeView + @param supportedActions +*/ void ElementsTreeView::startDrag(Qt::DropActions supportedActions) { QModelIndex index = currentIndex(); @@ -63,10 +63,10 @@ void ElementsTreeView::startDrag(Qt::DropActions supportedActions) } /** - * @brief ElementsTreeView::startElementDrag - * Build a QDrag according to the content of @location - * @param location : location to use for create the content of the QDrag - */ + @brief ElementsTreeView::startElementDrag + Build a QDrag according to the content of @location + @param location : location to use for create the content of the QDrag +*/ void ElementsTreeView::startElementDrag(const ElementsLocation &location) { if (!location.exist()) diff --git a/sources/ElementsCollection/elementstreeview.h b/sources/ElementsCollection/elementstreeview.h index d864f4ab9..333f843ff 100644 --- a/sources/ElementsCollection/elementstreeview.h +++ b/sources/ElementsCollection/elementstreeview.h @@ -23,11 +23,11 @@ class ElementsLocation; /** - * @brief The ElementsTreeView class - * This class just reimplement startDrag from QTreeView, for set a custom pixmap. - * This class must be used when the tree view have an ElementsCollectionModel as model. - * The pixmap used is the pixmap of the dragged element or a directory pixmap. - */ + @brief The ElementsTreeView class + This class just reimplement startDrag from QTreeView, for set a custom pixmap. + This class must be used when the tree view have an ElementsCollectionModel as model. + The pixmap used is the pixmap of the dragged element or a directory pixmap. +*/ class ElementsTreeView : public QTreeView { public: diff --git a/sources/ElementsCollection/fileelementcollectionitem.h b/sources/ElementsCollection/fileelementcollectionitem.h index b5992bbeb..57f5221f4 100644 --- a/sources/ElementsCollection/fileelementcollectionitem.h +++ b/sources/ElementsCollection/fileelementcollectionitem.h @@ -22,10 +22,10 @@ #include "elementslocation.h" /** - * @brief The FileElementCollectionItem class - * This class specialise ElementCollectionItem for manage a collection in - * a file system. They represente a directory or an element. - */ + @brief The FileElementCollectionItem class + This class specialise ElementCollectionItem for manage a collection in + a file system. They represente a directory or an element. +*/ class FileElementCollectionItem : public ElementCollectionItem { public: diff --git a/sources/ElementsCollection/xmlelementcollection.cpp b/sources/ElementsCollection/xmlelementcollection.cpp index 7fab4e958..b9884e2fc 100644 --- a/sources/ElementsCollection/xmlelementcollection.cpp +++ b/sources/ElementsCollection/xmlelementcollection.cpp @@ -22,16 +22,16 @@ #include "qetproject.h" /** - * @brief XmlElementCollection::XmlElementCollection - * Build an empty collection. - * The collection start by : + @brief XmlElementCollection::XmlElementCollection + Build an empty collection. + The collection start by : * * - * @param project : the project of this collection - */ + All elements and category are stored as child of XmlElementCollection::directories(const QDomElement &parent_element) const { QList directory_list; @@ -194,10 +194,10 @@ QList XmlElementCollection::directories(const QDomElement &parent_e } /** - * @brief XmlElementCollection::directoriesNames - * @param parent_element - * @return a list of names for every child directories of @parent_element - */ + @brief XmlElementCollection::directoriesNames + @param parent_element + @return a list of names for every child directories of @parent_element +*/ QStringList XmlElementCollection::directoriesNames(const QDomElement &parent_element) const { QList childs = directories(parent_element); @@ -214,10 +214,10 @@ QStringList XmlElementCollection::directoriesNames(const QDomElement &parent_ele } /** - * @brief XmlElementCollection::elements - * @param parent_element - * @return A list of element stored in @parent_element - */ + @brief XmlElementCollection::elements + @param parent_element + @return A list of element stored in @parent_element +*/ QList XmlElementCollection::elements(const QDomElement &parent_element) const { QList element_list; @@ -235,10 +235,10 @@ QList XmlElementCollection::elements(const QDomElement &parent_elem } /** - * @brief XmlElementCollection::elementsNames - * @param parent_element - * @return A list of names fr every childs element of @parent_element - */ + @brief XmlElementCollection::elementsNames + @param parent_element + @return A list of names fr every childs element of @parent_element +*/ QStringList XmlElementCollection::elementsNames(const QDomElement &parent_element) const { QList childs = elements(parent_element); @@ -255,11 +255,11 @@ QStringList XmlElementCollection::elementsNames(const QDomElement &parent_elemen } /** - * @brief XmlElementCollection::element - * @param path : path of the element in this collection - * @return the QDomElement that represent the element at path @path - * or a null QDomElement if not found or doesn't represent an element - */ + @brief XmlElementCollection::element + @param path : path of the element in this collection + @return the QDomElement that represent the element at path @path + or a null QDomElement if not found or doesn't represent an element +*/ QDomElement XmlElementCollection::element(const QString &path) const { if (!path.endsWith(".elmt")) return QDomElement(); @@ -273,11 +273,11 @@ QDomElement XmlElementCollection::element(const QString &path) const } /** - * @brief XmlElementCollection::directory - * @param path : path of the directory in this collection - * @return the QDomElement that represent the directory at path @path - * or a null QDomElement if not found. - */ + @brief XmlElementCollection::directory + @param path : path of the directory in this collection + @return the QDomElement that represent the directory at path @path + or a null QDomElement if not found. +*/ QDomElement XmlElementCollection::directory(const QString &path) const { QDomElement directory = child(path); @@ -289,15 +289,15 @@ QDomElement XmlElementCollection::directory(const QString &path) const } /** - * @brief XmlElementCollection::addElement - * Add the element at location to this collection. - * The element is copied in this collection in "import" dir with the same path, in other word - * if the path is dir1/dir2/dir3/myElement.elmt, myElement is copied to this collection at the path : import/dir1/dir2/dir3/myElement.elmt - * If the path doesn't exist, he was created. - * If the element already exist, do nothing. - * @param location, location of the element - * @return the collection path of the added item or a null QString if element can't be added. - */ + @brief XmlElementCollection::addElement + Add the element at location to this collection. + The element is copied in this collection in "import" dir with the same path, in other word + if the path is dir1/dir2/dir3/myElement.elmt, myElement is copied to this collection at the path : import/dir1/dir2/dir3/myElement.elmt + If the path doesn't exist, he was created. + If the element already exist, do nothing. + @param location, location of the element + @return the collection path of the added item or a null QString if element can't be added. +*/ QString XmlElementCollection::addElement(ElementsLocation &location) { //location must be an element and exist @@ -423,15 +423,15 @@ QString XmlElementCollection::addElement(ElementsLocation &location) } /** - * @brief XmlElementCollection::addElementDefinition - * Add the élément defintion @xml_definition in the directory at path @dir_path with the name @elmt_name. - * @param dir_path : the path of the directory where we must add the element. - * The path must be an existing directory of this collection. - * @param elmt_name : The name used to store the element (the name must end with .elmt, if not, .elmt will be append to @elmt_name) - * @param xml_definition : The xml definition of the element. - * The tag name of @xml_definition must be "definition". - * @return True if the element is added with success. - */ + @brief XmlElementCollection::addElementDefinition + Add the élément defintion @xml_definition in the directory at path @dir_path with the name @elmt_name. + @param dir_path : the path of the directory where we must add the element. + The path must be an existing directory of this collection. + @param elmt_name : The name used to store the element (the name must end with .elmt, if not, .elmt will be append to @elmt_name) + @param xml_definition : The xml definition of the element. + The tag name of @xml_definition must be "definition". + @return True if the element is added with success. +*/ bool XmlElementCollection::addElementDefinition(const QString &dir_path, const QString &elmt_name, const QDomElement &xml_definition) { QDomElement dom_dir = directory(dir_path); @@ -461,12 +461,12 @@ bool XmlElementCollection::addElementDefinition(const QString &dir_path, const Q } /** - * @brief XmlElementCollection::removeElement - * Remove the element at path @path. - * @param path - * @return True if element is removed and emit the signal elementRemoved. - * else false. - */ + @brief XmlElementCollection::removeElement + Remove the element at path @path. + @param path + @return True if element is removed and emit the signal elementRemoved. + else false. +*/ bool XmlElementCollection::removeElement(const QString& path) { QDomElement elmt = element(path); @@ -481,16 +481,16 @@ bool XmlElementCollection::removeElement(const QString& path) } /** - * @brief XmlElementCollection::copy - * Copy the content represented by source (an element or a directory) to destination. - * Destination must be a directory of this collection. - * If the destination already have an item at the same path of source, he will be replaced by source. - * @param source : content to copy - * @param destination : destination of the copy, must be a directory of this collection - * @param rename : rename the copy with @rename else use the name of source - * @param deep_copy : if true copy all childs of source (only if source is directory) - * @return the ElementLocation that represent the copy, if copy failed return a null ElementLocation - */ + @brief XmlElementCollection::copy + Copy the content represented by source (an element or a directory) to destination. + Destination must be a directory of this collection. + If the destination already have an item at the same path of source, he will be replaced by source. + @param source : content to copy + @param destination : destination of the copy, must be a directory of this collection + @param rename : rename the copy with @rename else use the name of source + @param deep_copy : if true copy all childs of source (only if source is directory) + @return the ElementLocation that represent the copy, if copy failed return a null ElementLocation +*/ ElementsLocation XmlElementCollection::copy(ElementsLocation &source, ElementsLocation &destination, const QString& rename, bool deep_copy) { if (!(source.exist() && destination.isDirectory() && destination.isProject() && destination.projectCollection() == this)) @@ -503,11 +503,11 @@ ElementsLocation XmlElementCollection::copy(ElementsLocation &source, ElementsLo } /** - * @brief XmlElementCollection::exist - * Return true if the path @path exist in this collection - * @param path - * @return - */ + @brief XmlElementCollection::exist + Return true if the path @path exist in this collection + @param path + @return +*/ bool XmlElementCollection::exist(const QString &path) const { if (child(path).isNull()) @@ -517,14 +517,14 @@ bool XmlElementCollection::exist(const QString &path) const } /** - * @brief XmlElementCollection::createDir - * Create a child directorie at path @path with the name @name. - * Emit directorieAdded if success. - * @param path : path of parent diectorie - * @param name : name of the directori to create. - * @param name_list : translation of the directorie name. - * @return true if creation success, if directorie already exist return true. - */ + @brief XmlElementCollection::createDir + Create a child directorie at path @path with the name @name. + Emit directorieAdded if success. + @param path : path of parent diectorie + @param name : name of the directori to create. + @param name_list : translation of the directorie name. + @return true if creation success, if directorie already exist return true. +*/ bool XmlElementCollection::createDir(const QString& path, const QString& name, const NamesList &name_list) { QString new_dir_path = path + "/" + name; @@ -551,12 +551,12 @@ bool XmlElementCollection::createDir(const QString& path, const QString& name, c } /** - * @brief XmlElementCollection::removeDir - * Remove the directory at path @path. - * @param path - * @return true if successfuly removed and emit directoryRemoved(QString), - * else false. - */ + @brief XmlElementCollection::removeDir + Remove the directory at path @path. + @param path + @return true if successfuly removed and emit directoryRemoved(QString), + else false. +*/ bool XmlElementCollection::removeDir(const QString& path) { QDomElement dir = directory(path); @@ -569,14 +569,14 @@ bool XmlElementCollection::removeDir(const QString& path) } /** - * @brief XmlElementCollection::elementsLocation - * Return all locations stored in dom_element (element and directory). - * If dom_element is null, return all location owned by this collection - * dom_element must be a child of this collection. - * @param dom_element : dom_element where we must to search location. - * @param childs = if true return all childs location of dom_element, if false, only return the direct childs location of dom_element. - * @return - */ + @brief XmlElementCollection::elementsLocation + Return all locations stored in dom_element (element and directory). + If dom_element is null, return all location owned by this collection + dom_element must be a child of this collection. + @param dom_element : dom_element where we must to search location. + @param childs = if true return all childs location of dom_element, if false, only return the direct childs location of dom_element. + @return +*/ QList XmlElementCollection::elementsLocation(QDomElement dom_element, bool childs) const { QList location_list; @@ -612,13 +612,13 @@ QList XmlElementCollection::elementsLocation(QDomElement dom_e } /** - * @brief XmlElementCollection::domToLocation - * Return the element location who represent the xml element : dom_element - * dom_element must be owned by this collection - * @param dom_element : the dom_element of this collection that represent an element. - * The tag name of dom_element must be "element" - * @return the element location, location can be null if fail. - */ + @brief XmlElementCollection::domToLocation + Return the element location who represent the xml element : dom_element + dom_element must be owned by this collection + @param dom_element : the dom_element of this collection that represent an element. + The tag name of dom_element must be "element" + @return the element location, location can be null if fail. +*/ ElementsLocation XmlElementCollection::domToLocation(QDomElement dom_element) const { if (dom_element.ownerDocument() == m_dom_document) { @@ -638,9 +638,9 @@ ElementsLocation XmlElementCollection::domToLocation(QDomElement dom_element) co } /** - * @brief XmlElementCollection::cleanUnusedElement - * Remove elements in this collection which is not used in the owner project - */ + @brief XmlElementCollection::cleanUnusedElement + Remove elements in this collection which is not used in the owner project +*/ void XmlElementCollection::cleanUnusedElement() { foreach (ElementsLocation loc, m_project->unusedElements()) @@ -648,9 +648,9 @@ void XmlElementCollection::cleanUnusedElement() } /** - * @brief XmlElementCollection::cleanUnusedDirectory - * Remove the empty directories of this collection - */ + @brief XmlElementCollection::cleanUnusedDirectory + Remove the empty directories of this collection +*/ void XmlElementCollection::cleanUnusedDirectory() { QDomNodeList lst = importCategory().elementsByTagName("category"); @@ -666,15 +666,15 @@ void XmlElementCollection::cleanUnusedDirectory() } /** - * @brief XmlElementCollection::copyDirectory - * Copy the directory represented by source to destination. - * if destination have a directory with the same name as source, then this directory is removed - * @param source : directory to copy - * @param destination : destination of the copy - * @param rename : rename the copy with @rename else use the name of source - * @param deep_copy :if true copy all childs of source - * @return the ElementLocation that represent the copy, if copy failed return a null ElementLocation - */ + @brief XmlElementCollection::copyDirectory + Copy the directory represented by source to destination. + if destination have a directory with the same name as source, then this directory is removed + @param source : directory to copy + @param destination : destination of the copy + @param rename : rename the copy with @rename else use the name of source + @param deep_copy :if true copy all childs of source + @return the ElementLocation that represent the copy, if copy failed return a null ElementLocation +*/ ElementsLocation XmlElementCollection::copyDirectory(ElementsLocation &source, ElementsLocation &destination, const QString& rename, bool deep_copy) { QString new_dir_name = rename.isEmpty() ? source.fileName() : rename; @@ -754,14 +754,14 @@ ElementsLocation XmlElementCollection::copyDirectory(ElementsLocation &source, E } /** - * @brief XmlElementCollection::copyElement - * Copy the element represented by source to destination (must be a directory) - * If element already exist in destination he will be replaced by the new. - * @param source : element to copy - * @param destination : destination of the copy - * @param rename : rename the copy with @rename else use the name of source - * @return The ElementsLocation of the copy - */ + @brief XmlElementCollection::copyElement + Copy the element represented by source to destination (must be a directory) + If element already exist in destination he will be replaced by the new. + @param source : element to copy + @param destination : destination of the copy + @param rename : rename the copy with @rename else use the name of source + @return The ElementsLocation of the copy +*/ ElementsLocation XmlElementCollection::copyElement(ElementsLocation &source, ElementsLocation &destination, const QString& rename) { QString new_elmt_name = rename.isEmpty() ? source.fileName() : rename; diff --git a/sources/ElementsCollection/xmlelementcollection.h b/sources/ElementsCollection/xmlelementcollection.h index 9b5ead121..427eda365 100644 --- a/sources/ElementsCollection/xmlelementcollection.h +++ b/sources/ElementsCollection/xmlelementcollection.h @@ -27,9 +27,9 @@ class QFile; class QETProject; /** - * @brief The XmlElementCollection class - * This class represent a collection of elements stored to xml - */ + @brief The XmlElementCollection class + This class represent a collection of elements stored to xml +*/ class XmlElementCollection : public QObject { Q_OBJECT @@ -68,34 +68,34 @@ class XmlElementCollection : public QObject signals: /** - * @brief elementAdded - * This signal is emited when a element is added to this collection - * @param collection_path, the path of element in this collection - */ + @brief elementAdded + This signal is emited when a element is added to this collection + @param collection_path, the path of element in this collection + */ void elementAdded(QString collection_path); /** - * @brief elementChanged - * This signal is emited when the defintion of the element at path was changed - * @param collection_path, the path of this element in this collection - */ + @brief elementChanged + This signal is emited when the defintion of the element at path was changed + @param collection_path, the path of this element in this collection + */ void elementChanged (QString collection_path); /** - * @brief elementRemoved - * This signal is emited when an element is removed to this collection - * @param collection_path, the path of the removed element in this collection - */ + @brief elementRemoved + This signal is emited when an element is removed to this collection + @param collection_path, the path of the removed element in this collection + */ void elementRemoved(QString collection_path); /** - * @brief directorieAdded - * This signal is emited when a directorie is added to this collection - * @param collection_path, the path of the new directorie - */ + @brief directorieAdded + This signal is emited when a directorie is added to this collection + @param collection_path, the path of the new directorie + */ void directorieAdded(QString collection_path); /** - * @brief directoryRemoved - * This signal is emited when a directory is removed to this collection - * @param collection_path, the path of the removed directory - */ + @brief directoryRemoved + This signal is emited when a directory is removed to this collection + @param collection_path, the path of the removed directory + */ void directoryRemoved(QString collection_path); private: diff --git a/sources/ElementsCollection/xmlprojectelementcollectionitem.cpp b/sources/ElementsCollection/xmlprojectelementcollectionitem.cpp index ed2c53f37..9f1f56b84 100644 --- a/sources/ElementsCollection/xmlprojectelementcollectionitem.cpp +++ b/sources/ElementsCollection/xmlprojectelementcollectionitem.cpp @@ -21,16 +21,16 @@ #include "xmlprojectelementcollectionitem.h" /** - * @brief XmlProjectElementCollectionItem::XmlProjectElementCollectionItem - * Constructor - */ + @brief XmlProjectElementCollectionItem::XmlProjectElementCollectionItem + Constructor +*/ XmlProjectElementCollectionItem::XmlProjectElementCollectionItem() {} /** - * @brief XmlProjectElementCollectionItem::isDir - * @return true if this item represent a directory - */ + @brief XmlProjectElementCollectionItem::isDir + @return true if this item represent a directory +*/ bool XmlProjectElementCollectionItem::isDir() const { if (m_dom_element.tagName() == "category") return true; @@ -38,9 +38,9 @@ bool XmlProjectElementCollectionItem::isDir() const } /** - * @brief XmlProjectElementCollectionItem::isElement - * @return true if this item represent an element - */ + @brief XmlProjectElementCollectionItem::isElement + @return true if this item represent an element +*/ bool XmlProjectElementCollectionItem::isElement() const { if (m_dom_element.tagName() == "element") return true; @@ -48,9 +48,9 @@ bool XmlProjectElementCollectionItem::isElement() const } /** - * @brief XmlProjectElementCollectionItem::localName - * @return the located name of this item - */ + @brief XmlProjectElementCollectionItem::localName + @return the located name of this item +*/ QString XmlProjectElementCollectionItem::localName() { if (!text().isNull()) @@ -71,18 +71,18 @@ QString XmlProjectElementCollectionItem::localName() } /** - * @brief XmlProjectElementCollectionItem::name - * @return The collection name of this item - */ + @brief XmlProjectElementCollectionItem::name + @return The collection name of this item +*/ QString XmlProjectElementCollectionItem::name() const { return m_dom_element.attribute("name"); } /** - * @brief XmlProjectElementCollectionItem::collectionPath - * @return The path of this item relative to the collection. - */ + @brief XmlProjectElementCollectionItem::collectionPath + @return The path of this item relative to the collection. +*/ QString XmlProjectElementCollectionItem::collectionPath() const { ElementsLocation loc (embeddedPath(), m_project); @@ -93,10 +93,10 @@ QString XmlProjectElementCollectionItem::collectionPath() const } /** - * @brief XmlProjectElementCollectionItem::embeddedPath - * @return The embedde path of this item - * The path is in form : embed://dir/subdir/myElement.elmt - */ + @brief XmlProjectElementCollectionItem::embeddedPath + @return The embedde path of this item + The path is in form : embed://dir/subdir/myElement.elmt +*/ QString XmlProjectElementCollectionItem::embeddedPath() const { if (isCollectionRoot()) @@ -114,9 +114,9 @@ QString XmlProjectElementCollectionItem::embeddedPath() const } /** - * @brief XmlProjectElementCollectionItem::isCollectionRoot - * @return true if this item represent the root of collection - */ + @brief XmlProjectElementCollectionItem::isCollectionRoot + @return true if this item represent the root of collection +*/ bool XmlProjectElementCollectionItem::isCollectionRoot() const { if (!parent()) @@ -128,11 +128,11 @@ bool XmlProjectElementCollectionItem::isCollectionRoot() const } /** - * @brief XmlProjectElementCollectionItem::addChildAtPath - * Ask to this item item to add a new child with collection name @collection_name - * (the child must exist in the xml element collection) - * @param collection_name : name of the child item to add. - */ + @brief XmlProjectElementCollectionItem::addChildAtPath + Ask to this item item to add a new child with collection name @collection_name + (the child must exist in the xml element collection) + @param collection_name : name of the child item to add. +*/ void XmlProjectElementCollectionItem::addChildAtPath(const QString &collection_name) { if (collection_name.isEmpty()) @@ -155,21 +155,21 @@ void XmlProjectElementCollectionItem::addChildAtPath(const QString &collection_n } /** - * @brief XmlProjectElementCollectionItem::project - * @return the paretn project of the managed collection - */ + @brief XmlProjectElementCollectionItem::project + @return the paretn project of the managed collection +*/ QETProject *XmlProjectElementCollectionItem::project() const { return m_project; } /** - * @brief XmlProjectElementCollectionItem::setProject - * Set the project for this item. - * Use this method for set this item the root of the collection - * @param project : project to manage the collection - * @param set_data : if true, call setUpData for every child of this item - */ + @brief XmlProjectElementCollectionItem::setProject + Set the project for this item. + Use this method for set this item the root of the collection + @param project : project to manage the collection + @param set_data : if true, call setUpData for every child of this item +*/ void XmlProjectElementCollectionItem::setProject(QETProject *project, bool set_data, bool hide_element) { if (m_project) @@ -181,9 +181,9 @@ void XmlProjectElementCollectionItem::setProject(QETProject *project, bool set_d } /** - * @brief XmlProjectElementCollectionItem::setUpData - * SetUp the data of this item - */ + @brief XmlProjectElementCollectionItem::setUpData + SetUp the data of this item +*/ void XmlProjectElementCollectionItem::setUpData() { //Setup the displayed name @@ -212,10 +212,10 @@ void XmlProjectElementCollectionItem::setUpData() } /** - * @brief XmlProjectElementCollectionItem::setUpIcon - * SetUp the icon of this item. - * Because icon use several memory, we use this method for setup icon instead setUpData. - */ + @brief XmlProjectElementCollectionItem::setUpIcon + SetUp the icon of this item. + Because icon use several memory, we use this method for setup icon instead setUpData. +*/ void XmlProjectElementCollectionItem::setUpIcon() { if (!icon().isNull()) @@ -232,10 +232,10 @@ void XmlProjectElementCollectionItem::setUpIcon() } /** - * @brief XmlProjectElementCollectionItem::populate - * Create the childs of this item - * @param set_data : if true, call setUpData for every child of this item - */ + @brief XmlProjectElementCollectionItem::populate + Create the childs of this item + @param set_data : if true, call setUpData for every child of this item +*/ void XmlProjectElementCollectionItem::populate(bool set_data, bool hide_element) { QList dom_category = m_project->embeddedElementCollection()->directories(m_dom_element); @@ -267,12 +267,12 @@ void XmlProjectElementCollectionItem::populate(bool set_data, bool hide_element) } /** - * @brief XmlProjectElementCollectionItem::setXmlElement - * Set the managed content of this item - * @param element : the dom element (directory or element), to be managed by this item - * @param project : the parent project of managed collection - * @param set_data : if true, call setUpData for every child of this item - */ + @brief XmlProjectElementCollectionItem::setXmlElement + Set the managed content of this item + @param element : the dom element (directory or element), to be managed by this item + @param project : the parent project of managed collection + @param set_data : if true, call setUpData for every child of this item +*/ void XmlProjectElementCollectionItem::setXmlElement(const QDomElement& element, QETProject *project, bool set_data, bool hide_element) { m_dom_element = element; diff --git a/sources/ElementsCollection/xmlprojectelementcollectionitem.h b/sources/ElementsCollection/xmlprojectelementcollectionitem.h index 1a6de5d4e..2a7bbb508 100644 --- a/sources/ElementsCollection/xmlprojectelementcollectionitem.h +++ b/sources/ElementsCollection/xmlprojectelementcollectionitem.h @@ -24,9 +24,9 @@ class QETProject; /** - * @brief The XmlProjectElementCollectionItem class - * This class specialise ElementCollectionItem for manage an xml collection embedded in a project. - */ + @brief The XmlProjectElementCollectionItem class + This class specialise ElementCollectionItem for manage an xml collection embedded in a project. +*/ class XmlProjectElementCollectionItem : public ElementCollectionItem { public: diff --git a/sources/NameList/nameslist.cpp b/sources/NameList/nameslist.cpp index fc518c4d5..067307f06 100644 --- a/sources/NameList/nameslist.cpp +++ b/sources/NameList/nameslist.cpp @@ -126,15 +126,15 @@ void NamesList::fromXml(const QDomElement &xml_element, const QHash name from an xml description. - * @xml_element must be the parent of a child element tagged "names" - * If a couple lang <-> name already exist, they will overwrited, else - * they will be appened. - * @param xml_element : xml element to analyze - * @param xml_options : A set of options related to XML parsing. - * @see getXmlOptions() - */ + @brief NamesList::fromXml + Load the list of lang <-> name from an xml description. + @xml_element must be the parent of a child element tagged "names" + If a couple lang <-> name already exist, they will overwrited, else + they will be appened. + @param xml_element : xml element to analyze + @param xml_options : A set of options related to XML parsing. + @see getXmlOptions() +*/ void NamesList::fromXml(const pugi::xml_node &xml_element, const QHash &xml_options) { QHash xml_opt = getXmlOptions(xml_options); diff --git a/sources/NameList/ui/namelistdialog.cpp b/sources/NameList/ui/namelistdialog.cpp index 3ded9db89..1f90eed88 100644 --- a/sources/NameList/ui/namelistdialog.cpp +++ b/sources/NameList/ui/namelistdialog.cpp @@ -44,10 +44,10 @@ void NameListDialog::setInformationText(const QString &text) { } /** - * @brief NameListDialog::namelistWidget - * @return the name list widget used by this dialog. - * The ownership of the namelistwidget stay to this dialog - */ + @brief NameListDialog::namelistWidget + @return the name list widget used by this dialog. + The ownership of the namelistwidget stay to this dialog +*/ NameListWidget *NameListDialog::namelistWidget() const { return m_namelist_widget; } diff --git a/sources/NameList/ui/namelistdialog.h b/sources/NameList/ui/namelistdialog.h index 118a8f6d4..35299c04f 100644 --- a/sources/NameList/ui/namelistdialog.h +++ b/sources/NameList/ui/namelistdialog.h @@ -27,9 +27,9 @@ namespace Ui { } /** - * @brief The NameListDialog class - * Provide a dialog for let user define localized string; - */ + @brief The NameListDialog class + Provide a dialog for let user define localized string; +*/ class NameListDialog : public QDialog { Q_OBJECT diff --git a/sources/NameList/ui/namelistwidget.cpp b/sources/NameList/ui/namelistwidget.cpp index 5b3784335..612cc6c82 100644 --- a/sources/NameList/ui/namelistwidget.cpp +++ b/sources/NameList/ui/namelistwidget.cpp @@ -36,9 +36,9 @@ NameListWidget::~NameListWidget() } /** - * @brief NameListWidget::addLine - * Add a new line to the name list widget - */ + @brief NameListWidget::addLine + Add a new line to the name list widget +*/ void NameListWidget::addLine() { clean(); @@ -53,10 +53,10 @@ void NameListWidget::addLine() } /** - * @brief NameListWidget::setNames - * Set the current names of this dialog from @name_list - * @param name_list - */ + @brief NameListWidget::setNames + Set the current names of this dialog from @name_list + @param name_list +*/ void NameListWidget::setNames(const NamesList &name_list) { for (QString lang : name_list.langs()) @@ -74,9 +74,9 @@ void NameListWidget::setNames(const NamesList &name_list) } /** - * @brief NameListWidget::names - * @return the current name list edited by this dialog - */ + @brief NameListWidget::names + @return the current name list edited by this dialog +*/ NamesList NameListWidget::names() const { NamesList nl_; @@ -95,10 +95,10 @@ NamesList NameListWidget::names() const } /** - * @brief NameListWidget::setReadOnly - * Set this dialog to read only or not. - * @param ro - */ + @brief NameListWidget::setReadOnly + Set this dialog to read only or not. + @param ro +*/ void NameListWidget::setReadOnly(bool ro) { m_read_only = ro; @@ -116,10 +116,10 @@ void NameListWidget::setReadOnly(bool ro) } /** - * @brief NameListWidget::isEmpty - * @return true if empty. - * An empty dialog, is a dialog without any edited lang. - */ + @brief NameListWidget::isEmpty + @return true if empty. + An empty dialog, is a dialog without any edited lang. +*/ bool NameListWidget::isEmpty() const { return names().isEmpty(); } @@ -142,9 +142,9 @@ void NameListWidget::setClipboardValue(QHash value) } /** - * @brief NameListWidget::clean - * Clean the lists of names by removing the emtpy lines - */ + @brief NameListWidget::clean + Clean the lists of names by removing the emtpy lines +*/ void NameListWidget::clean() { int names_count = ui->m_tree->topLevelItemCount() - 1; diff --git a/sources/NameList/ui/namelistwidget.h b/sources/NameList/ui/namelistwidget.h index 3bb29bcea..2bd30f531 100644 --- a/sources/NameList/ui/namelistwidget.h +++ b/sources/NameList/ui/namelistwidget.h @@ -26,9 +26,9 @@ namespace Ui { } /** - * @brief The NameListWidget class - * Provide a widget for let user define localized string; - */ + @brief The NameListWidget class + Provide a widget for let user define localized string; +*/ class NameListWidget : public QWidget { Q_OBJECT diff --git a/sources/PropertiesEditor/propertieseditordialog.h b/sources/PropertiesEditor/propertieseditordialog.h index 43d0fab9e..570f64bdf 100644 --- a/sources/PropertiesEditor/propertieseditordialog.h +++ b/sources/PropertiesEditor/propertieseditordialog.h @@ -24,16 +24,16 @@ #include /** - * @brief The PropertiesEditorDialog class - * Create a dialog to edit some properties of a thing. - * Only create a instance of this class and call exec, all is done for you in this class. - * The first argument (a template) must be a subclass of QWidget and provide the 3 methods bellow : - * QString::title() - * void::apply() - * void::reset() - * You can subclass the interface PropertiesEditorWidget who provide all this methods. - * This dialog take ownership of the editor, so the editor will be deleted by this dialog - */ + @brief The PropertiesEditorDialog class + Create a dialog to edit some properties of a thing. + Only create a instance of this class and call exec, all is done for you in this class. + The first argument (a template) must be a subclass of QWidget and provide the 3 methods bellow : + QString::title() + void::apply() + void::reset() + You can subclass the interface PropertiesEditorWidget who provide all this methods. + This dialog take ownership of the editor, so the editor will be deleted by this dialog +*/ class PropertiesEditorDialog : public QDialog { Q_OBJECT diff --git a/sources/PropertiesEditor/propertieseditordockwidget.cpp b/sources/PropertiesEditor/propertieseditordockwidget.cpp index d4d80eb03..497eebefb 100644 --- a/sources/PropertiesEditor/propertieseditordockwidget.cpp +++ b/sources/PropertiesEditor/propertieseditordockwidget.cpp @@ -20,10 +20,10 @@ #include "propertieseditorwidget.h" /** - * @brief PropertiesEditorDockWidget::PropertiesEditorDockWidget - * Constructor - * @param parent : parent widget - */ + @brief PropertiesEditorDockWidget::PropertiesEditorDockWidget + Constructor + @param parent : parent widget +*/ PropertiesEditorDockWidget::PropertiesEditorDockWidget(QWidget *parent) : QDockWidget(parent), ui(new Ui::PropertiesEditorDockWidget) @@ -32,9 +32,9 @@ PropertiesEditorDockWidget::PropertiesEditorDockWidget(QWidget *parent) : } /** - * @brief PropertiesEditorDockWidget::~PropertiesEditorDockWidget - * Destructor - */ + @brief PropertiesEditorDockWidget::~PropertiesEditorDockWidget + Destructor +*/ PropertiesEditorDockWidget::~PropertiesEditorDockWidget() { clear(); @@ -42,10 +42,10 @@ PropertiesEditorDockWidget::~PropertiesEditorDockWidget() } /** - * @brief PropertiesEditorDockWidget::clear - * Remove all editor present in this dock and delete it. - * They also disabled the button box at the bottom of this dock - */ + @brief PropertiesEditorDockWidget::clear + Remove all editor present in this dock and delete it. + They also disabled the button box at the bottom of this dock +*/ void PropertiesEditorDockWidget::clear() { foreach (PropertiesEditorWidget *editor, m_editor_list) @@ -59,9 +59,9 @@ void PropertiesEditorDockWidget::clear() } /** - * @brief PropertiesEditorDockWidget::apply - * Call the apply method for each editor present in this dock - */ + @brief PropertiesEditorDockWidget::apply + Call the apply method for each editor present in this dock +*/ void PropertiesEditorDockWidget::apply() { foreach(PropertiesEditorWidget *editor, m_editor_list) @@ -69,9 +69,9 @@ void PropertiesEditorDockWidget::apply() } /** - * @brief PropertiesEditorDockWidget::reset - * Call the reset method for each editor present in this widget - */ + @brief PropertiesEditorDockWidget::reset + Call the reset method for each editor present in this widget +*/ void PropertiesEditorDockWidget::reset() { foreach(PropertiesEditorWidget *editor, m_editor_list) @@ -79,14 +79,14 @@ void PropertiesEditorDockWidget::reset() } /** - * @brief PropertiesEditorDockWidget::addEditor - * Add an @editor in this dock at @index in the main vertical layout (note the button box - * are displayed at bottom of this layout by default) - * When an editor is added, we enable the button box - * @param editor : editor to add; - * @param index : index of editor in the layout - * @return true if was added (or already add) or false if can't be add (editor = nullptr) - */ + @brief PropertiesEditorDockWidget::addEditor + Add an @editor in this dock at @index in the main vertical layout (note the button box + are displayed at bottom of this layout by default) + When an editor is added, we enable the button box + @param editor : editor to add; + @param index : index of editor in the layout + @return true if was added (or already add) or false if can't be add (editor = nullptr) +*/ bool PropertiesEditorDockWidget::addEditor(PropertiesEditorWidget *editor, int index) { if (!editor) return false; @@ -98,20 +98,20 @@ bool PropertiesEditorDockWidget::addEditor(PropertiesEditorWidget *editor, int i } /** - * @brief PropertiesEditorDockWidget::editors - * @return all editor used in this dock - */ + @brief PropertiesEditorDockWidget::editors + @return all editor used in this dock +*/ QList PropertiesEditorDockWidget::editors() const { return m_editor_list; } /** - * @brief PropertiesEditorDockWidget::removeEditor - * Remove @editor from this dock. The editor wasn't delete a the end of this method - * If the editor was the last on this widget, we disabled the button box - * @param editor : editor to remove - * @return true on success, else false - */ + @brief PropertiesEditorDockWidget::removeEditor + Remove @editor from this dock. The editor wasn't delete a the end of this method + If the editor was the last on this widget, we disabled the button box + @param editor : editor to remove + @return true on success, else false +*/ bool PropertiesEditorDockWidget::removeEditor(PropertiesEditorWidget *editor) { bool result = m_editor_list.removeOne(editor); diff --git a/sources/PropertiesEditor/propertieseditorwidget.cpp b/sources/PropertiesEditor/propertieseditorwidget.cpp index da8f1b07b..a579d9474 100644 --- a/sources/PropertiesEditor/propertieseditorwidget.cpp +++ b/sources/PropertiesEditor/propertieseditorwidget.cpp @@ -19,52 +19,52 @@ #include /** - * @brief PropertiesEditorWidget::PropertiesEditorWidget - * Constructor - * @param parent : parent widget - */ + @brief PropertiesEditorWidget::PropertiesEditorWidget + Constructor + @param parent : parent widget +*/ PropertiesEditorWidget::PropertiesEditorWidget(QWidget *parent) : QWidget(parent), m_live_edit(false) {} /** - * @brief PropertiesEditorWidget::associatedUndo - * By default, return a nullptr - * @return nullptr - */ + @brief PropertiesEditorWidget::associatedUndo + By default, return a nullptr + @return nullptr +*/ QUndoCommand *PropertiesEditorWidget::associatedUndo() const{ return nullptr; } /** - * @brief PropertiesEditorWidget::title - * @return the title of this editor - */ + @brief PropertiesEditorWidget::title + @return the title of this editor +*/ QString PropertiesEditorWidget::title() const { return QString(); } /** - * @brief PropertiesEditorWidget::setLiveEdit - * Set the editor in live edit mode. - * When an editor is in live edit mode, every change is applied immediately (no need to call apply). - * If live edit can be enable, return true, else false. - * By default this method do nothing and return false (live edit is disable). - * Herited class of PropertiesEditorWidget must reimplemente this methode to manage the live edit mode. - * @param live_edit true to enable live edit - * @return true if live edit is enable, else false. - */ + @brief PropertiesEditorWidget::setLiveEdit + Set the editor in live edit mode. + When an editor is in live edit mode, every change is applied immediately (no need to call apply). + If live edit can be enable, return true, else false. + By default this method do nothing and return false (live edit is disable). + Herited class of PropertiesEditorWidget must reimplemente this methode to manage the live edit mode. + @param live_edit true to enable live edit + @return true if live edit is enable, else false. +*/ bool PropertiesEditorWidget::setLiveEdit(bool live_edit) { Q_UNUSED(live_edit); return false; } /** - * @brief PropertiesEditorWidget::isLiveEdit - * @return true if this editor is in live edit mode - * else return fasle. - */ + @brief PropertiesEditorWidget::isLiveEdit + @return true if this editor is in live edit mode + else return fasle. +*/ bool PropertiesEditorWidget::isLiveEdit() const { return m_live_edit; } diff --git a/sources/PropertiesEditor/propertieseditorwidget.h b/sources/PropertiesEditor/propertieseditorwidget.h index 96b994edb..f2575a953 100644 --- a/sources/PropertiesEditor/propertieseditorwidget.h +++ b/sources/PropertiesEditor/propertieseditorwidget.h @@ -23,10 +23,10 @@ class QUndoCommand; /** - * @brief The PropertiesEditorWidget class - * This class extend QWidget method for have common way - * to edit propertie. - */ + @brief The PropertiesEditorWidget class + This class extend QWidget method for have common way + to edit propertie. +*/ class PropertiesEditorWidget : public QWidget { Q_OBJECT diff --git a/sources/QPropertyUndoCommand/qpropertyundocommand.cpp b/sources/QPropertyUndoCommand/qpropertyundocommand.cpp index 3ce5ef929..fd7948dc1 100644 --- a/sources/QPropertyUndoCommand/qpropertyundocommand.cpp +++ b/sources/QPropertyUndoCommand/qpropertyundocommand.cpp @@ -19,13 +19,13 @@ #include /** - * @brief QPropertyUndoCommand::QPropertyUndoCommand - * Default constructor with old and new value - * This command don't take ownership of @object - * @param object - * @param old_value - * @param new_value - */ + @brief QPropertyUndoCommand::QPropertyUndoCommand + Default constructor with old and new value + This command don't take ownership of @object + @param object + @param old_value + @param new_value +*/ QPropertyUndoCommand::QPropertyUndoCommand(QObject *object, const char *property_name, const QVariant &old_value, const QVariant &new_value, QUndoCommand *parent) : QUndoCommand(parent), m_object(object), @@ -35,14 +35,14 @@ QPropertyUndoCommand::QPropertyUndoCommand(QObject *object, const char *property {} /** - * @brief QPropertyUndoCommand::QPropertyUndoCommand - * Default constructor with old value. - * Call setNewValue to setup the new value of the edited QObject - * This command don't take ownership of @object - * @param object - * @param old_value - * @param parent - */ + @brief QPropertyUndoCommand::QPropertyUndoCommand + Default constructor with old value. + Call setNewValue to setup the new value of the edited QObject + This command don't take ownership of @object + @param object + @param old_value + @param parent +*/ QPropertyUndoCommand::QPropertyUndoCommand(QObject *object, const char *property_name, const QVariant &old_value, QUndoCommand *parent) : QUndoCommand(parent), m_object(object), @@ -62,29 +62,29 @@ QPropertyUndoCommand::QPropertyUndoCommand(const QPropertyUndoCommand *other) } /** - * @brief QPropertyUndoCommand::setNewValue - * Set the new value of the property (set with redo) to @new_value - * @param new_value - */ + @brief QPropertyUndoCommand::setNewValue + Set the new value of the property (set with redo) to @new_value + @param new_value +*/ void QPropertyUndoCommand::setNewValue(const QVariant &new_value) { m_new_value = new_value; } /** - * @brief QPropertyUndoCommand::enableAnimation - * True to enable animation - * @param animate - */ + @brief QPropertyUndoCommand::enableAnimation + True to enable animation + @param animate +*/ void QPropertyUndoCommand::enableAnimation (bool animate) { m_animate = animate; } /** - * @brief QPropertyUndoCommand::setAnimated - * @param animate = true for animate this undo - * @param first_time = if true, the first animation is done at the first call of redo - * if false, the first animation is done at the second call of redo. - */ + @brief QPropertyUndoCommand::setAnimated + @param animate = true for animate this undo + @param first_time = if true, the first animation is done at the first call of redo + if false, the first animation is done at the second call of redo. +*/ void QPropertyUndoCommand::setAnimated(bool animate, bool first_time) { m_animate = animate; @@ -92,11 +92,11 @@ void QPropertyUndoCommand::setAnimated(bool animate, bool first_time) } /** - * @brief QPropertyUndoCommand::mergeWith - * Try to merge this command with other command - * @param other - * @return true if was merged, else false - */ + @brief QPropertyUndoCommand::mergeWith + Try to merge this command with other command + @param other + @return true if was merged, else false +*/ bool QPropertyUndoCommand::mergeWith(const QUndoCommand *other) { if (id() != other->id() || other->childCount()) return false; @@ -107,9 +107,9 @@ bool QPropertyUndoCommand::mergeWith(const QUndoCommand *other) } /** - * @brief QPropertyUndoCommand::redo - * Redo this command - */ + @brief QPropertyUndoCommand::redo + Redo this command +*/ void QPropertyUndoCommand::redo() { if (m_object->property(m_property_name) != m_new_value) @@ -132,9 +132,9 @@ void QPropertyUndoCommand::redo() } /** - * @brief QPropertyUndoCommand::undo - * Undo this command - */ + @brief QPropertyUndoCommand::undo + Undo this command +*/ void QPropertyUndoCommand::undo() { if (m_object->property(m_property_name) != m_old_value) diff --git a/sources/QPropertyUndoCommand/qpropertyundocommand.h b/sources/QPropertyUndoCommand/qpropertyundocommand.h index db2c71907..77f274777 100644 --- a/sources/QPropertyUndoCommand/qpropertyundocommand.h +++ b/sources/QPropertyUndoCommand/qpropertyundocommand.h @@ -24,12 +24,12 @@ class QObject; /** - * @brief The QPropertyUndoCommand class - * This undo command manage QProperty of a QObject. - * This undo command can use QPropertyAnimation to animate the change when undo/redo is call - * To use animation call setAnimated(true). By default animation is disable. - * Some QVariant date can't be animated and result this command don't work. - */ + @brief The QPropertyUndoCommand class + This undo command manage QProperty of a QObject. + This undo command can use QPropertyAnimation to animate the change when undo/redo is call + To use animation call setAnimated(true). By default animation is disable. + Some QVariant date can't be animated and result this command don't work. +*/ class QPropertyUndoCommand : public QUndoCommand { public: diff --git a/sources/QWidgetAnimation/qwidgetanimation.cpp b/sources/QWidgetAnimation/qwidgetanimation.cpp index df0932a91..246543f9a 100644 --- a/sources/QWidgetAnimation/qwidgetanimation.cpp +++ b/sources/QWidgetAnimation/qwidgetanimation.cpp @@ -19,11 +19,11 @@ #include /** - * @brief QWidgetAnimation::QWidgetAnimation - * @param widget : widget to animate - * @param orientation : animate widget horizontally or vertically - * @param duration : the duration of animation @see void QVariantAnimation::setDuration(int msecs) - */ + @brief QWidgetAnimation::QWidgetAnimation + @param widget : widget to animate + @param orientation : animate widget horizontally or vertically + @param duration : the duration of animation @see void QVariantAnimation::setDuration(int msecs) +*/ QWidgetAnimation::QWidgetAnimation(QWidget *widget, Qt::Orientation orientation, QWidgetAnimation::Behavior behavior, int duration) : QPropertyAnimation(widget), m_orientation(orientation), @@ -51,10 +51,10 @@ QWidgetAnimation::QWidgetAnimation(QWidget *widget, Qt::Orientation orientation, } /** - * @brief QWidgetAnimation::widgetToSubtract - * Widget to subtract the size when the behavior is availableSpace - * @param widgets - */ + @brief QWidgetAnimation::widgetToSubtract + Widget to subtract the size when the behavior is availableSpace + @param widgets +*/ void QWidgetAnimation::widgetToSubtract(QVector widgets) { m_widget_to_substract.clear(); @@ -62,9 +62,9 @@ void QWidgetAnimation::widgetToSubtract(QVector widgets) } /** - * @brief QWidgetAnimation::show - * show the widget - */ + @brief QWidgetAnimation::show + show the widget +*/ void QWidgetAnimation::show() { if (m_state == QWidgetAnimation::Showing) @@ -113,9 +113,9 @@ void QWidgetAnimation::show() } /** - * @brief QWidgetAnimation::hide - * Hide the widget - */ + @brief QWidgetAnimation::hide + Hide the widget +*/ void QWidgetAnimation::hide() { if (m_state == QWidgetAnimation::Hidding) @@ -135,10 +135,10 @@ void QWidgetAnimation::hide() } /** - * @brief QWidgetAnimation::setHidden - * true hide, false show - * @param hidden - */ + @brief QWidgetAnimation::setHidden + true hide, false show + @param hidden +*/ void QWidgetAnimation::setHidden(bool hidden) { if (hidden) @@ -148,10 +148,10 @@ void QWidgetAnimation::setHidden(bool hidden) } /** - * @brief QWidgetAnimation::setLastShowSize - * Force the last show size value to @size - * @param size - */ + @brief QWidgetAnimation::setLastShowSize + Force the last show size value to @size + @param size +*/ void QWidgetAnimation::setLastShowSize(int size) { if (m_orientation == Qt::Vertical) { diff --git a/sources/QWidgetAnimation/qwidgetanimation.h b/sources/QWidgetAnimation/qwidgetanimation.h index 92e6b18b2..48748d7a9 100644 --- a/sources/QWidgetAnimation/qwidgetanimation.h +++ b/sources/QWidgetAnimation/qwidgetanimation.h @@ -23,18 +23,18 @@ #include /** - * @brief The QWidgetAnimation class - * This class animate the show and hide function of a QWidget. + @brief The QWidgetAnimation class + This class animate the show and hide function of a QWidget. * - * The role of @behavior is to calcul as best the animation process when widget is show. - * Because this class don't change the current and final size of the widget but her maximum size during the animation process, - * we must to know in advance the final size of the widget. - * Behavior minimumSizeHint : the final size of the widget will be his minimum size hint. - * Behavior availableSpace : the final size of widget will be the available size of her parent. - * Since parent can have other widgets you can add a QVector of widget to subtract of the final size. - * Because we suppose the animated widget will take the maximum available space, we subtract the minimum size hint of widgets in QVector. - * Behavior lastSize : The widget will have the same size as the last time he was showed. - */ + The role of @behavior is to calcul as best the animation process when widget is show. + Because this class don't change the current and final size of the widget but her maximum size during the animation process, + we must to know in advance the final size of the widget. + Behavior minimumSizeHint : the final size of the widget will be his minimum size hint. + Behavior availableSpace : the final size of widget will be the available size of her parent. + Since parent can have other widgets you can add a QVector of widget to subtract of the final size. + Because we suppose the animated widget will take the maximum available space, we subtract the minimum size hint of widgets in QVector. + Behavior lastSize : The widget will have the same size as the last time he was showed. +*/ class QWidgetAnimation : public QPropertyAnimation { Q_OBJECT diff --git a/sources/QetGraphicsItemModeler/qetgraphicshandleritem.cpp b/sources/QetGraphicsItemModeler/qetgraphicshandleritem.cpp index 2a67a985a..8f1bfe79a 100644 --- a/sources/QetGraphicsItemModeler/qetgraphicshandleritem.cpp +++ b/sources/QetGraphicsItemModeler/qetgraphicshandleritem.cpp @@ -21,9 +21,9 @@ #include /** - * @brief QetGraphicsHandlerItem::QetGraphicsHandlerItem - * @param size, the size of the handler - */ + @brief QetGraphicsHandlerItem::QetGraphicsHandlerItem + @param size, the size of the handler +*/ QetGraphicsHandlerItem::QetGraphicsHandlerItem(qreal size) : m_size(size) { @@ -34,17 +34,17 @@ QetGraphicsHandlerItem::QetGraphicsHandlerItem(qreal size) : } /** - * @brief QetGraphicsHandlerItem::boundingRect - * @return - */ + @brief QetGraphicsHandlerItem::boundingRect + @return +*/ QRectF QetGraphicsHandlerItem::boundingRect() const { return m_br; } /** - * @brief QetGraphicsHandlerItem::setColor - * @param color, set the color of the handler - */ + @brief QetGraphicsHandlerItem::setColor + @param color, set the color of the handler +*/ void QetGraphicsHandlerItem::setColor(QColor color) { m_color = std::move(color); @@ -52,11 +52,11 @@ void QetGraphicsHandlerItem::setColor(QColor color) } /** - * @brief QetGraphicsHandlerItem::paint - * @param painter - * @param option - * @param widget - */ + @brief QetGraphicsHandlerItem::paint + @param painter + @param option + @param widget +*/ void QetGraphicsHandlerItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { Q_UNUSED(option) @@ -73,10 +73,10 @@ void QetGraphicsHandlerItem::paint(QPainter *painter, const QStyleOptionGraphics } /** - * @brief QetGraphicsHandlerItem::handlerForPoint - * @param points - * @return A list of handler with pos at point - */ + @brief QetGraphicsHandlerItem::handlerForPoint + @param points + @return A list of handler with pos at point +*/ QVector QetGraphicsHandlerItem::handlerForPoint(const QVector &points, int size) { QVector list_; diff --git a/sources/QetGraphicsItemModeler/qetgraphicshandleritem.h b/sources/QetGraphicsItemModeler/qetgraphicshandleritem.h index 185c33356..c1a6c2760 100644 --- a/sources/QetGraphicsItemModeler/qetgraphicshandleritem.h +++ b/sources/QetGraphicsItemModeler/qetgraphicshandleritem.h @@ -22,12 +22,12 @@ #include /** - * @brief The QetGraphicsHandlerItem class - * This graphics item represents a point, destined to be used as an handler, - * for modifie the geometrie of a another graphics item (like shapes). - * The graphics item to be modified, must call "installSceneEventFilter" of this item with itself for argument,. - * The ghraphics item to be modified, need to reimplement "sceneEventFilter" for create the modification behavior. - */ + @brief The QetGraphicsHandlerItem class + This graphics item represents a point, destined to be used as an handler, + for modifie the geometrie of a another graphics item (like shapes). + The graphics item to be modified, must call "installSceneEventFilter" of this item with itself for argument,. + The ghraphics item to be modified, need to reimplement "sceneEventFilter" for create the modification behavior. +*/ class QetGraphicsHandlerItem : public QGraphicsItem { public: diff --git a/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.cpp b/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.cpp index 24557ca7f..827f2d99c 100644 --- a/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.cpp +++ b/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.cpp @@ -20,19 +20,19 @@ /** - * @brief QetGraphicsHandlerUtility::pointsForRect - * Return the keys points of the rectangle, stored in a vector. - * The points in the vector are stored like this : - * ********** - * 0---1---2 - * | | - * 3 4 - * | | - * 5---6---7 - * ************ - * @param rect - * @return - */ + @brief QetGraphicsHandlerUtility::pointsForRect + Return the keys points of the rectangle, stored in a vector. + The points in the vector are stored like this : + ********** + 0---1---2 + | | + 3 4 + | | + 5---6---7 + ************ + @param rect + @return +*/ QVector QetGraphicsHandlerUtility::pointsForRect(const QRectF &rect) { QVector vector; @@ -56,25 +56,26 @@ QVector QetGraphicsHandlerUtility::pointsForRect(const QRectF &rect) } /** - * @brief QetGraphicsHandlerUtility::pointsForLine - * The point that define a line in a QVector. - * there is two points. - * @param line - * @return - */ + @brief QetGraphicsHandlerUtility::pointsForLine + The point that define a line in a QVector. + there is two points. + @param line + @return +*/ QVector QetGraphicsHandlerUtility::pointsForLine(const QLineF &line) { return (QVector {line.p1(), line.p2()}); } /** - * @brief QetGraphicsHandlerUtility::pointsForArc - * Return the points for the given arc. - * The first value in the vector is the start point, the second the end point. - * @param rect - * @param start_angle : start angle in degree - * @param span_angle : span angle in degree; - * @return - */ + @brief QetGraphicsHandlerUtility::pointsForArc + Return the points for the given arc. + The first value in the vector is the start point, + the second the end point. + @param rect + @param start_angle : start angle in degree + @param span_angle : span angle in degree; + @return +*/ QVector QetGraphicsHandlerUtility::pointsForArc(const QRectF &rect, qreal start_angle, qreal span_angle) { QVector vector; @@ -88,14 +89,18 @@ QVector QetGraphicsHandlerUtility::pointsForArc(const QRectF &rect, qre } /** - * @brief QetGraphicsHandlerUtility::rectForPosAtIndex - * Return a rectangle after modification of the point '@pos' at index '@index' of original rectangle '@old_rect'. - * @param old_rect - the rectangle befor modification - * @param pos - the new position of a key point - * @param index - the index of the key point to modifie see QetGraphicsHandlerUtility::pointsForRect to know - * the index of each keys points of a rectangle) - * @return : the rectangle with modification. If index is lower than 0 or higher than 7, this method return old_rect. - */ + @brief QetGraphicsHandlerUtility::rectForPosAtIndex + Return a rectangle after modification + of the point '@pos' at index '@index' of original rectangle '@old_rect'. + @param old_rect - the rectangle befor modification + @param pos - the new position of a key point + @param index - the index of the key point to modifie + @see QetGraphicsHandlerUtility::pointsForRect to know + the index of each keys points of a rectangle) + @return : the rectangle with modification. + If index is lower than 0 or higher than 7, + this method return old_rect. +*/ QRectF QetGraphicsHandlerUtility::rectForPosAtIndex(const QRectF &old_rect, const QPointF &pos, int index) { if (index < 0 || index > 7) return old_rect; @@ -114,15 +119,19 @@ QRectF QetGraphicsHandlerUtility::rectForPosAtIndex(const QRectF &old_rect, cons } /** - * @brief QetGraphicsHandlerUtility::mirrorRectForPosAtIndex - * Return a rectangle after modification of the point '@pos' at index '@index' of original rectangle '@old_rect'. - * the opposite edge is modified inversely (like a mirror) - * @param old_rect : the rectangle befor modification - * @param pos : the new position of a key point - * @param index : the index of the key point to modifie see QetGraphicsHandlerUtility::pointsForRect to know - * the index of each keys points of a rectangle) - * @return : the rectangle with modification. If index is lower than 0 or higher than 7, this method return old_rect. - */ + @brief QetGraphicsHandlerUtility::mirrorRectForPosAtIndex + Return a rectangle after modification of the point '@pos' + at index '@index' of original rectangle '@old_rect'. + the opposite edge is modified inversely (like a mirror) + @param old_rect : the rectangle befor modification + @param pos : the new position of a key point + @param index : the index of the key point to modifie + @see QetGraphicsHandlerUtility::pointsForRect to know + the index of each keys points of a rectangle) + @return : the rectangle with modification. + If index is lower than 0 or higher than 7, + this method return old_rect. +*/ QRectF QetGraphicsHandlerUtility::mirrorRectForPosAtIndex(const QRectF &old_rect, const QPointF &pos, int index) { if (index < 0 || index > 7) return old_rect; @@ -172,13 +181,13 @@ QRectF QetGraphicsHandlerUtility::mirrorRectForPosAtIndex(const QRectF &old_rect } /** - * @brief QetGraphicsHandlerUtility::lineForPosAtIndex - * Return a line after modification of @pos at index @index of @old_line. - * @param old_line - * @param pos - * @param index - * @return - */ + @brief QetGraphicsHandlerUtility::lineForPosAtIndex + Return a line after modification of @pos at index @index of @old_line. + @param old_line + @param pos + @param index + @return +*/ QLineF QetGraphicsHandlerUtility::lineForPosAtIndex(const QLineF &old_line, const QPointF &pos, int index) { QLineF line = old_line; index == 0 ? line.setP1(pos) : line.setP2(pos); @@ -186,12 +195,12 @@ QLineF QetGraphicsHandlerUtility::lineForPosAtIndex(const QLineF &old_line, cons } /** - * @brief QetGraphicsHandlerUtility::polygonForInsertPoint - * @param old_polygon : the polygon which we insert a new point. - * @param closed : polygon is closed or not - * @param pos : the pos where the new point must be added - * @return the new polygon - */ + @brief QetGraphicsHandlerUtility::polygonForInsertPoint + @param old_polygon : the polygon which we insert a new point. + @param closed : polygon is closed or not + @param pos : the pos where the new point must be added + @return the new polygon +*/ QPolygonF QetGraphicsHandlerUtility::polygonForInsertPoint(const QPolygonF &old_polygon, bool closed, const QPointF &pos) { qreal max_angle = 0; @@ -241,15 +250,17 @@ QPolygonF QetGraphicsHandlerUtility::polygonForInsertPoint(const QPolygonF &old_ } /** - * @brief QetGraphicsHandlerUtility::pointForRadiusRect - * @param rect the rectangle. - * @param xRadius : x radius - * @param yRadius : y radius - * @param mode : absolute or relative size: NOTE this argument is not used, this function always compute with relative size. - * @return the points of x and y radius of a rounded rect. - * The points are always based on the top right corner of the rect. - * the first point of vector is X the second Y - */ + @brief QetGraphicsHandlerUtility::pointForRadiusRect + @param rect the rectangle. + @param xRadius : x radius + @param yRadius : y radius + @param mode : + absolute or relative size: NOTE this argument is not used, + this function always compute with relative size. + @return the points of x and y radius of a rounded rect. + The points are always based on the top right corner of the rect. + the first point of vector is X the second Y +*/ QVector QetGraphicsHandlerUtility::pointForRadiusRect(const QRectF &rect, qreal xRadius, qreal yRadius, Qt::SizeMode mode) { QVector v; @@ -283,13 +294,13 @@ QVector QetGraphicsHandlerUtility::pointForRadiusRect(const QRectF &rec } /** - * @brief QetGraphicsHandlerUtility::radiusForPosAtIndex - * @param rect the rectangle - * @param pos : the pos of the new radius - * @param index : index of radius 0=X 1=Y - * @param mode - * @return - */ + @brief QetGraphicsHandlerUtility::radiusForPosAtIndex + @param rect the rectangle + @param pos : the pos of the new radius + @param index : index of radius 0=X 1=Y + @param mode + @return +*/ qreal QetGraphicsHandlerUtility::radiusForPosAtIndex(const QRectF &rect, const QPointF &pos, int index, Qt::SizeMode mode) { if (mode == Qt::AbsoluteSize) diff --git a/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.h b/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.h index dee501ec7..950f27fa4 100644 --- a/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.h +++ b/sources/QetGraphicsItemModeler/qetgraphicshandlerutility.h @@ -26,11 +26,11 @@ class QPainter; /** - * @brief The QetGraphicsHandlerUtility class - * This class provide some methods to create and use handler for - * modify graphics shape like line rectangle etc... - * They also provide some conveniance static method. - */ + @brief The QetGraphicsHandlerUtility class + This class provide some methods to create and use handler for + modify graphics shape like line rectangle etc... + They also provide some conveniance static method. +*/ class QetGraphicsHandlerUtility { public: diff --git a/sources/SearchAndReplace/searchandreplaceworker.cpp b/sources/SearchAndReplace/searchandreplaceworker.cpp index 654f3b95c..2995939ad 100644 --- a/sources/SearchAndReplace/searchandreplaceworker.cpp +++ b/sources/SearchAndReplace/searchandreplaceworker.cpp @@ -32,11 +32,12 @@ SearchAndReplaceWorker::SearchAndReplaceWorker() } /** - * @brief SearchAndReplaceWorker::replaceDiagram - * Replace all properties of each diagram in @diagram_list, - * by the current titleblock propertie of this worker - * @param diagram_list, list of diagram to be changed, all diagrams must belong to the same project; - */ + @brief SearchAndReplaceWorker::replaceDiagram + Replace all properties of each diagram in @diagram_list, + by the current titleblock propertie of this worker + @param diagram_list, list of diagram to be changed, + all diagrams must belong to the same project; +*/ void SearchAndReplaceWorker::replaceDiagram(QList diagram_list) { if (diagram_list.isEmpty()) { @@ -91,12 +92,14 @@ void SearchAndReplaceWorker::replaceDiagram(Diagram *diagram) } /** - * @brief SearchAndReplaceWorker::replaceElement - * Replace all properties of each elements in @list - * All element must belong to the same project, if not this function do nothing. - * All change are made through a undo command append to undo list of the project. - * @param list - */ + @brief SearchAndReplaceWorker::replaceElement + Replace all properties of each elements in @list + All element must belong to the same project, + if not this function do nothing. + All change are made through a undo command append + to undo list of the project. + @param list +*/ void SearchAndReplaceWorker::replaceElement(QList list) { if (list.isEmpty() || !list.first()->diagram()) { @@ -147,11 +150,11 @@ void SearchAndReplaceWorker::replaceElement(Element *element) } /** - * @brief SearchAndReplaceWorker::replaceIndiText - * Replace all displayed text of independent text of @list - * Each must belong to the same project, if not this function do nothing - * @param list - */ + @brief SearchAndReplaceWorker::replaceIndiText + Replace all displayed text of independent text of @list + Each must belong to the same project, if not this function do nothing + @param list +*/ void SearchAndReplaceWorker::replaceIndiText(QList list) { if (list.isEmpty() || !list.first()->diagram()) { @@ -183,12 +186,14 @@ void SearchAndReplaceWorker::replaceIndiText(IndependentTextItem *text) } /** - * @brief SearchAndReplaceWorker::replaceConductor - * Replace all properties of each conductor in @list - * All conductor must belong to the same project, if not this function do nothing. - * All change are made through a undo command append to undo list of the project. - * @param list - */ + @brief SearchAndReplaceWorker::replaceConductor + Replace all properties of each conductor in @list + All conductor must belong to the same project, + if not this function do nothing. + All change are made through a undo command append + to undo list of the project. + @param list +*/ void SearchAndReplaceWorker::replaceConductor(QList list) { if (list.isEmpty() || !list.first()->diagram()) { @@ -232,15 +237,15 @@ void SearchAndReplaceWorker::replaceConductor(Conductor *conductor) } /** - * @brief SearchAndReplaceWorker::replaceAdvanced - * Apply the change of text according to the current advancedStruct - * All items in the 4 list must belong to the same QETProject, - * if not this function do nothing - * @param d - * @param e - * @param t - * @param c - */ + @brief SearchAndReplaceWorker::replaceAdvanced + Apply the change of text according to the current advancedStruct + All items in the 4 list must belong to the same QETProject, + if not this function do nothing + @param d + @param e + @param t + @param c +*/ void SearchAndReplaceWorker::replaceAdvanced(QList diagrams, QList elements, QList texts, QList conductors) { QETProject *project_ = nullptr; @@ -348,15 +353,17 @@ void SearchAndReplaceWorker::replaceAdvanced(QList diagrams, QListsetText(str); @@ -385,11 +392,11 @@ ConductorProperties SearchAndReplaceWorker::invalidConductorProperties() } /** - * @brief SearchAndReplaceWorker::applyChange - * @param original : the original properties - * @param change : the change properties, to be merged with @original - * @return a new conductor properties with the change applyed. - */ + @brief SearchAndReplaceWorker::applyChange + @param original : the original properties + @param change : the change properties, to be merged with @original + @return a new conductor properties with the change applyed. +*/ ConductorProperties SearchAndReplaceWorker::applyChange(const ConductorProperties &original, const ConductorProperties &change) { ConductorProperties new_properties = original; @@ -420,11 +427,11 @@ ConductorProperties SearchAndReplaceWorker::applyChange(const ConductorPropertie } /** - * @brief SearchAndReplaceWorker::applyChange - * @param original : the original string - * @param change : the changed string: - * @return the string to be use in the properties - */ + @brief SearchAndReplaceWorker::applyChange + @param original : the original string + @param change : the changed string: + @return the string to be use in the properties +*/ QString SearchAndReplaceWorker::applyChange(const QString &original, const QString &change) { if (change.isEmpty()) {return original;} @@ -433,11 +440,11 @@ QString SearchAndReplaceWorker::applyChange(const QString &original, const QStri } /** - * @brief SearchAndReplaceWorker::replaceAdvanced - * @param diagram - * @return the titleblock properties with the change applied, - * according to the state of @m_advanced_struct - */ + @brief SearchAndReplaceWorker::replaceAdvanced + @param diagram + @return the titleblock properties with the change applied, + according to the state of @m_advanced_struct +*/ TitleBlockProperties SearchAndReplaceWorker::replaceAdvanced(Diagram *diagram) { TitleBlockProperties p = diagram->border_and_titleblock.exportTitleBlock(); @@ -459,11 +466,11 @@ TitleBlockProperties SearchAndReplaceWorker::replaceAdvanced(Diagram *diagram) } /** - * @brief SearchAndReplaceWorker::replaceAdvanced - * @param element - * @return The diagram context with the change applied, - * according to the state of @m_advanced_struct - */ + @brief SearchAndReplaceWorker::replaceAdvanced + @param element + @return The diagram context with the change applied, + according to the state of @m_advanced_struct +*/ DiagramContext SearchAndReplaceWorker::replaceAdvanced(Element *element) { DiagramContext context = element->elementInformations(); @@ -484,11 +491,11 @@ DiagramContext SearchAndReplaceWorker::replaceAdvanced(Element *element) } /** - * @brief SearchAndReplaceWorker::replaceAdvanced - * @param conductor - * @return the conductor properties with the change applied, - * according to the state of @m_advanced_struct - */ + @brief SearchAndReplaceWorker::replaceAdvanced + @param conductor + @return the conductor properties with the change applied, + according to the state of @m_advanced_struct +*/ ConductorProperties SearchAndReplaceWorker::replaceAdvanced(Conductor *conductor) { ConductorProperties properties = conductor->properties(); diff --git a/sources/SearchAndReplace/searchandreplaceworker.h b/sources/SearchAndReplace/searchandreplaceworker.h index 5740c4b9c..0f6e7f7bb 100644 --- a/sources/SearchAndReplace/searchandreplaceworker.h +++ b/sources/SearchAndReplace/searchandreplaceworker.h @@ -44,9 +44,10 @@ struct advancedReplaceStruct }; /** - * @brief The SearchAndReplaceWorker class - * This class is the worker use to change properties when use the search and replace function of QET - */ + @brief The SearchAndReplaceWorker class + This class is the worker use to change properties + when use the search and replace function of QET +*/ class SearchAndReplaceWorker { public: diff --git a/sources/SearchAndReplace/ui/replaceadvanceddialog.cpp b/sources/SearchAndReplace/ui/replaceadvanceddialog.cpp index dc9acebf0..ae3aea8f1 100644 --- a/sources/SearchAndReplace/ui/replaceadvanceddialog.cpp +++ b/sources/SearchAndReplace/ui/replaceadvanceddialog.cpp @@ -22,10 +22,10 @@ #include /** - * @brief replaceAdvancedDialog::replaceAdvancedDialog - * @param advanced - * @param parent - */ + @brief replaceAdvancedDialog::replaceAdvancedDialog + @param advanced + @param parent +*/ replaceAdvancedDialog::replaceAdvancedDialog(advancedReplaceStruct advanced, QWidget *parent) : QDialog(parent), ui(new Ui::replaceAdvancedDialog) @@ -47,10 +47,10 @@ replaceAdvancedDialog::~replaceAdvancedDialog() } /** - * @brief replaceAdvancedDialog::setAdvancedStruct - * Set the edited advanced struct - * @param advanced - */ + @brief replaceAdvancedDialog::setAdvancedStruct + Set the edited advanced struct + @param advanced +*/ void replaceAdvancedDialog::setAdvancedStruct(advancedReplaceStruct advanced) { int index = advanced.who; @@ -73,9 +73,9 @@ void replaceAdvancedDialog::setAdvancedStruct(advancedReplaceStruct advanced) } /** - * @brief replaceAdvancedDialog::advancedStruct - * @return the edited advanced struct - */ + @brief replaceAdvancedDialog::advancedStruct + @return the edited advanced struct +*/ advancedReplaceStruct replaceAdvancedDialog::advancedStruct() const { advancedReplaceStruct a; @@ -110,9 +110,9 @@ void replaceAdvancedDialog::fillWhatComboBox(int index) } /** - * @brief replaceAdvancedDialog::on_m_who_cb_currentIndexChanged - * @param index - */ + @brief replaceAdvancedDialog::on_m_who_cb_currentIndexChanged + @param index +*/ void replaceAdvancedDialog::on_m_who_cb_currentIndexChanged(int index) { fillWhatComboBox(index); } diff --git a/sources/SearchAndReplace/ui/replaceconductordialog.cpp b/sources/SearchAndReplace/ui/replaceconductordialog.cpp index d95423c46..f0e1e6e7a 100644 --- a/sources/SearchAndReplace/ui/replaceconductordialog.cpp +++ b/sources/SearchAndReplace/ui/replaceconductordialog.cpp @@ -25,9 +25,9 @@ typedef SearchAndReplaceWorker sarw; /** - * @brief ReplaceConductorDialog::ReplaceConductorDialog - * @param parent - */ + @brief ReplaceConductorDialog::ReplaceConductorDialog + @param parent +*/ ReplaceConductorDialog::ReplaceConductorDialog(const ConductorProperties &properties, QWidget *parent) : QDialog(parent), ui(new Ui::ReplaceConductorDialog) @@ -43,11 +43,11 @@ ReplaceConductorDialog::~ReplaceConductorDialog() } /** - * @brief ReplaceConductorDialog::updatePreview - * Update the preview for single line - * @param b true: update from the value displayed by this widget - * false: update from the properties given at the constructor of this widget - */ + @brief ReplaceConductorDialog::updatePreview + Update the preview for single line + @param b true: update from the value displayed by this widget + false: update from the properties given at the constructor of this widget +*/ void ReplaceConductorDialog::updatePreview(bool b) { const QRect pixmap_rect(0, 0, 96, 96); @@ -124,9 +124,9 @@ void ReplaceConductorDialog::setProperties(const ConductorProperties &properties } /** - * @brief ReplaceConductorDialog::properties - * @return the properties edited by this widget - */ + @brief ReplaceConductorDialog::properties + @return the properties edited by this widget +*/ ConductorProperties ReplaceConductorDialog::properties() const { ConductorProperties properties_; diff --git a/sources/SearchAndReplace/ui/replaceconductordialog.h b/sources/SearchAndReplace/ui/replaceconductordialog.h index 8b99900fb..a28ed243d 100644 --- a/sources/SearchAndReplace/ui/replaceconductordialog.h +++ b/sources/SearchAndReplace/ui/replaceconductordialog.h @@ -27,9 +27,9 @@ namespace Ui { } /** - * @brief The ReplaceConductorDialog class - * A Qdialog to edit a conductor properties, use for the search and replace feature of QElectrotech. - */ + @brief The ReplaceConductorDialog class + A Qdialog to edit a conductor properties, use for the search and replace feature of QElectrotech. +*/ class ReplaceConductorDialog : public QDialog { Q_OBJECT diff --git a/sources/SearchAndReplace/ui/replaceelementdialog.cpp b/sources/SearchAndReplace/ui/replaceelementdialog.cpp index 837a1152f..c0fb6d57d 100644 --- a/sources/SearchAndReplace/ui/replaceelementdialog.cpp +++ b/sources/SearchAndReplace/ui/replaceelementdialog.cpp @@ -39,10 +39,10 @@ ReplaceElementDialog::~ReplaceElementDialog() } /** - * @brief ReplaceElementDialog::setContext - * Set the current diagram context to be edited - * @param context - */ + @brief ReplaceElementDialog::setContext + Set the current diagram context to be edited + @param context +*/ void ReplaceElementDialog::setContext(DiagramContext context) { m_context = context; @@ -53,9 +53,9 @@ void ReplaceElementDialog::setContext(DiagramContext context) } /** - * @brief ReplaceElementDialog::context - * @return The edited diagram context - */ + @brief ReplaceElementDialog::context + @return The edited diagram context +*/ DiagramContext ReplaceElementDialog::context() const { DiagramContext context; diff --git a/sources/SearchAndReplace/ui/replacefoliowidget.cpp b/sources/SearchAndReplace/ui/replacefoliowidget.cpp index f953c2341..ba36810f6 100644 --- a/sources/SearchAndReplace/ui/replacefoliowidget.cpp +++ b/sources/SearchAndReplace/ui/replacefoliowidget.cpp @@ -39,9 +39,9 @@ ReplaceFolioWidget::~ReplaceFolioWidget() } /** - * @brief ReplaceFolioWidget::titleBlockProperties - * @return the title block properties edited by this widget - */ + @brief ReplaceFolioWidget::titleBlockProperties + @return the title block properties edited by this widget +*/ TitleBlockProperties ReplaceFolioWidget::titleBlockProperties() const { TitleBlockProperties prop; @@ -71,10 +71,10 @@ TitleBlockProperties ReplaceFolioWidget::titleBlockProperties() const } /** - * @brief ReplaceFolioWidget::setTitleBlockProperties - * Set the title block properties edited by this widget - * @param properties - */ + @brief ReplaceFolioWidget::setTitleBlockProperties + Set the title block properties edited by this widget + @param properties +*/ void ReplaceFolioWidget::setTitleBlockProperties(const TitleBlockProperties &properties) { sarw::setupLineEdit(ui->m_title_le, ui->m_title_cb, properties.title); @@ -130,17 +130,17 @@ ReplaceFolioDialog::~ReplaceFolioDialog() {} /** - * @brief ReplaceFolioDialog::titleBlockProperties - * @return The title block properties edited by this dialog - */ + @brief ReplaceFolioDialog::titleBlockProperties + @return The title block properties edited by this dialog +*/ TitleBlockProperties ReplaceFolioDialog::titleBlockProperties() const { return m_widget->titleBlockProperties(); } /** - * @brief ReplaceFolioDialog::setTitleBlockProperties - * @param properties : set the title block properties edited by this dialog - */ + @brief ReplaceFolioDialog::setTitleBlockProperties + @param properties : set the title block properties edited by this dialog +*/ void ReplaceFolioDialog::setTitleBlockProperties(const TitleBlockProperties &properties) { m_widget->setTitleBlockProperties(properties); } diff --git a/sources/SearchAndReplace/ui/searchandreplacewidget.cpp b/sources/SearchAndReplace/ui/searchandreplacewidget.cpp index 3e4351a33..c4405f5ba 100644 --- a/sources/SearchAndReplace/ui/searchandreplacewidget.cpp +++ b/sources/SearchAndReplace/ui/searchandreplacewidget.cpp @@ -36,10 +36,10 @@ #include /** - * @brief SearchAndReplaceWidget::SearchAndReplaceWidget - * Constructor - * @param parent - */ + @brief SearchAndReplaceWidget::SearchAndReplaceWidget + Constructor + @param parent +*/ SearchAndReplaceWidget::SearchAndReplaceWidget(QWidget *parent) : QWidget(parent), ui(new Ui::SearchAndReplaceWidget) @@ -59,20 +59,20 @@ SearchAndReplaceWidget::SearchAndReplaceWidget(QWidget *parent) : } /** - * @brief SearchAndReplaceWidget::~SearchAndReplaceWidget - * Destructor - */ + @brief SearchAndReplaceWidget::~SearchAndReplaceWidget + Destructor +*/ SearchAndReplaceWidget::~SearchAndReplaceWidget() { delete ui; } /** - * @brief SearchAndReplaceWidget::event - * Reimplemented to clear the the lines edit and hide - * the advanced widgets, when this widget become hidden - * @param event - * @return - */ + @brief SearchAndReplaceWidget::event + Reimplemented to clear the the lines edit and hide + the advanced widgets, when this widget become hidden + @param event + @return +*/ bool SearchAndReplaceWidget::event(QEvent *event) { if (event->type() == QEvent::Hide) @@ -95,10 +95,10 @@ bool SearchAndReplaceWidget::event(QEvent *event) } /** - * @brief SearchAndReplaceWidget::clear - * Clear the content of the search and replace line edit - * Clear all tree items in the tree widget (except the category items). - */ + @brief SearchAndReplaceWidget::clear + Clear the content of the search and replace line edit + Clear all tree items in the tree widget (except the category items). +*/ void SearchAndReplaceWidget::clear() { disconnect(ui->m_tree_widget, &QTreeWidget::itemChanged, this, &SearchAndReplaceWidget::itemChanged); @@ -128,18 +128,18 @@ void SearchAndReplaceWidget::clear() } /** - * @brief SearchAndReplaceWidget::setEditor - * Set the diagram editor of this widget - * @param editor - */ + @brief SearchAndReplaceWidget::setEditor + Set the diagram editor of this widget + @param editor +*/ void SearchAndReplaceWidget::setEditor(QETDiagramEditor *editor) { m_editor = editor; } /** - * @brief SearchAndReplaceWidget::setUpTreeItems - * Set up the main tree widget items - */ + @brief SearchAndReplaceWidget::setUpTreeItems + Set up the main tree widget items +*/ void SearchAndReplaceWidget::setUpTreeItems() { m_root_qtwi = new QTreeWidgetItem(ui->m_tree_widget); @@ -207,10 +207,10 @@ void SearchAndReplaceWidget::setUpTreeItems() } /** - * @brief SearchAndReplaceWidget::setHideAdvanced - * Hide advanced widgets - * @param hide - */ + @brief SearchAndReplaceWidget::setHideAdvanced + Hide advanced widgets + @param hide +*/ void SearchAndReplaceWidget::setHideAdvanced(bool hide) { m_vertical_animation->setHidden(hide); @@ -218,9 +218,9 @@ void SearchAndReplaceWidget::setHideAdvanced(bool hide) } /** - * @brief SearchAndReplaceWidget::fillItemsList - * Fill the tree - */ + @brief SearchAndReplaceWidget::fillItemsList + Fill the tree +*/ void SearchAndReplaceWidget::fillItemsList() { disconnect(ui->m_tree_widget, &QTreeWidget::itemChanged, this, &SearchAndReplaceWidget::itemChanged); @@ -296,10 +296,10 @@ void SearchAndReplaceWidget::fillItemsList() } /** - * @brief SearchAndReplaceWidget::addElement - * Add a tree widget item for @element - * @param element - */ + @brief SearchAndReplaceWidget::addElement + Add a tree widget item for @element + @param element +*/ void SearchAndReplaceWidget::addElement(Element *element) { QTreeWidgetItem *parent = m_elements_qtwi; @@ -341,9 +341,9 @@ void SearchAndReplaceWidget::addElement(Element *element) } /** - * @brief SearchAndReplaceWidget::search - * Start the search - */ + @brief SearchAndReplaceWidget::search + Start the search +*/ void SearchAndReplaceWidget::search() { QString str = ui->m_search_le->text(); @@ -413,11 +413,11 @@ void SearchAndReplaceWidget::search() } /** - * @brief SearchAndReplaceWidget::setVisibleAllParents - * Set visible all parents of @item until the invisible root item - * @param item - * @param expend_parent - */ + @brief SearchAndReplaceWidget::setVisibleAllParents + Set visible all parents of @item until the invisible root item + @param item + @param expend_parent +*/ void SearchAndReplaceWidget::setVisibleAllParents(QTreeWidgetItem *item, bool expend_parent) { if (item->parent()) @@ -430,11 +430,13 @@ void SearchAndReplaceWidget::setVisibleAllParents(QTreeWidgetItem *item, bool ex } /** - * @brief SearchAndReplaceWidget::nextItem - * @param item : find the next item from @item, if @item is nullptr, start the search for the root of the tree - * @param flags - * @return the next item according to flag or nullptr if there is not a next item - */ + @brief SearchAndReplaceWidget::nextItem + @param item : find the next item from @item, + if @item is nullptr, start the search for the root of the tree + @param flags + @return the next item according to flag + or nullptr if there is not a next item +*/ QTreeWidgetItem *SearchAndReplaceWidget::nextItem(QTreeWidgetItem *item, QTreeWidgetItemIterator::IteratorFlag flags) const { QTreeWidgetItem *qtwi = item; @@ -459,11 +461,13 @@ QTreeWidgetItem *SearchAndReplaceWidget::nextItem(QTreeWidgetItem *item, QTreeWi } /** - * @brief SearchAndReplaceWidget::previousItem - * @param item : find the previous item from @item, if @item is nullptr, start the search for the root of the tree - * @param flags - * @return the previous item according to flag or nullptr if there is not a previous item - */ + @brief SearchAndReplaceWidget::previousItem + @param item : find the previous item from @item, + if @item is nullptr, start the search for the root of the tree + @param flags + @return the previous item according to flag + or nullptr if there is not a previous item +*/ QTreeWidgetItem *SearchAndReplaceWidget::previousItem(QTreeWidgetItem *item, QTreeWidgetItemIterator::IteratorFlag flags) const { QTreeWidgetItem *qtwi = item; @@ -488,10 +492,10 @@ QTreeWidgetItem *SearchAndReplaceWidget::previousItem(QTreeWidgetItem *item, QTr } /** - * @brief SearchAndReplaceWidget::updateNextPreviousButtons - * According to the current item, if there is a next or a previous item, - * we enable/disable the buttons next/previous item. - */ + @brief SearchAndReplaceWidget::updateNextPreviousButtons + According to the current item, if there is a next or a previous item, + we enable/disable the buttons next/previous item. +*/ void SearchAndReplaceWidget::updateNextPreviousButtons() { QTreeWidgetItem *item_ = ui->m_tree_widget->currentItem(); @@ -536,12 +540,12 @@ void SearchAndReplaceWidget::updateNextPreviousButtons() } /** - * @brief SearchAndReplaceWidget::itemChanged - * Reimplemented from QTreeWidget. - * Use to update the check state of items. - * @param item - * @param column - */ + @brief SearchAndReplaceWidget::itemChanged + Reimplemented from QTreeWidget. + Use to update the check state of items. + @param item + @param column +*/ void SearchAndReplaceWidget::itemChanged(QTreeWidgetItem *item, int column) { Q_UNUSED(column); @@ -554,11 +558,11 @@ void SearchAndReplaceWidget::itemChanged(QTreeWidgetItem *item, int column) } /** - * @brief SearchAndReplaceWidget::setChildCheckState - * @param item : Parent of the items to be evaluated - * @param check : check state - * @param deep : if true, we evaluate every subchilds. - */ + @brief SearchAndReplaceWidget::setChildCheckState + @param item : Parent of the items to be evaluated + @param check : check state + @param deep : if true, we evaluate every subchilds. +*/ void SearchAndReplaceWidget::setChildCheckState(QTreeWidgetItem *item, Qt::CheckState check, bool deep) { for (int i=0 ; ichildCount() ; ++i) @@ -571,10 +575,11 @@ void SearchAndReplaceWidget::setChildCheckState(QTreeWidgetItem *item, Qt::Check } /** - * @brief SearchAndReplaceWidget::updateParentCheckState - * @param item : a child item of the parent to be evaluated. - * @param all_parents : if true, we evaluate every parents, until the root item. - */ + @brief SearchAndReplaceWidget::updateParentCheckState + @param item : a child item of the parent to be evaluated. + @param all_parents : if true, we evaluate every parents, + until the root item. +*/ void SearchAndReplaceWidget::updateParentCheckState(QTreeWidgetItem *item, bool all_parents) { QTreeWidgetItem *parent = item->parent(); @@ -616,9 +621,9 @@ void SearchAndReplaceWidget::updateParentCheckState(QTreeWidgetItem *item, bool } /** - * @brief SearchAndReplaceWidget::activateNextChecked - * Activate the next checked (and visible) item - */ + @brief SearchAndReplaceWidget::activateNextChecked + Activate the next checked (and visible) item +*/ void SearchAndReplaceWidget::activateNextChecked() { //Next button is disabled, so there is not a next item. @@ -632,9 +637,9 @@ void SearchAndReplaceWidget::activateNextChecked() } /** - * @brief SearchAndReplaceWidget::selectedDiagram - * @return The list of visible and selected diagram in the tree widget - */ + @brief SearchAndReplaceWidget::selectedDiagram + @return The list of visible and selected diagram in the tree widget +*/ QList SearchAndReplaceWidget::selectedDiagram() const { QList diagram_list; @@ -654,9 +659,9 @@ QList SearchAndReplaceWidget::selectedDiagram() const } /** - * @brief SearchAndReplaceWidget::selectedElement - * @return The list of visible and selected element in the tree widget - */ + @brief SearchAndReplaceWidget::selectedElement + @return The list of visible and selected element in the tree widget +*/ QList SearchAndReplaceWidget::selectedElement() const { QList element_list; @@ -676,9 +681,9 @@ QList SearchAndReplaceWidget::selectedElement() const } /** - * @brief SearchAndReplaceWidget::selectedConductor - * @return The list of visible and selected conductor in the tree widget - */ + @brief SearchAndReplaceWidget::selectedConductor + @return The list of visible and selected conductor in the tree widget +*/ QList SearchAndReplaceWidget::selectedConductor() const { QList conductor_list; @@ -698,9 +703,10 @@ QList SearchAndReplaceWidget::selectedConductor() const } /** - * @brief SearchAndReplaceWidget::selectedText - * @return The list of visible and selected independant text in the tree widget - */ + @brief SearchAndReplaceWidget::selectedText + @return The list of visible and selected independant text + in the tree widget +*/ QList SearchAndReplaceWidget::selectedText() const { QList text_list; @@ -720,10 +726,10 @@ QList SearchAndReplaceWidget::selectedText() const } /** - * @brief SearchAndReplaceWidget::searchTerms - * @param diagram - * @return All QStrings use as terms for search. - */ + @brief SearchAndReplaceWidget::searchTerms + @param diagram + @return All QStrings use as terms for search. +*/ QStringList SearchAndReplaceWidget::searchTerms(Diagram *diagram) { QStringList list; @@ -744,10 +750,10 @@ QStringList SearchAndReplaceWidget::searchTerms(Diagram *diagram) } /** - * @brief SearchAndReplaceWidget::searchTerms - * @param element - * @return All QString use as terms for search - */ + @brief SearchAndReplaceWidget::searchTerms + @param element + @return All QString use as terms for search +*/ QStringList SearchAndReplaceWidget::searchTerms(Element *element) { QStringList list; @@ -781,10 +787,10 @@ QStringList SearchAndReplaceWidget::searchTerms(Element *element) } /** - * @brief SearchAndReplaceWidget::searchTerms - * @param conductor - * @return all QString use as terms for search. - */ + @brief SearchAndReplaceWidget::searchTerms + @param conductor + @return all QString use as terms for search. +*/ QStringList SearchAndReplaceWidget::searchTerms(Conductor *conductor) { QStringList list; @@ -800,8 +806,8 @@ QStringList SearchAndReplaceWidget::searchTerms(Conductor *conductor) } /** - * @brief SearchAndReplaceWidget::on_m_quit_button_clicked - */ + @brief SearchAndReplaceWidget::on_m_quit_button_clicked +*/ void SearchAndReplaceWidget::on_m_quit_button_clicked() { if (auto animator = this->findChild("search and replace animator")) { @@ -990,9 +996,9 @@ void SearchAndReplaceWidget::on_m_folio_pb_clicked() } /** - * @brief SearchAndReplaceWidget::on_m_replace_pb_clicked - * Replace the current selection - */ + @brief SearchAndReplaceWidget::on_m_replace_pb_clicked + Replace the current selection +*/ void SearchAndReplaceWidget::on_m_replace_pb_clicked() { QTreeWidgetItem *qtwi = ui->m_tree_widget->currentItem(); @@ -1082,9 +1088,9 @@ void SearchAndReplaceWidget::on_m_replace_pb_clicked() } /** - * @brief SearchAndReplaceWidget::on_m_replace_all_pb_clicked - * Replace all checked item - */ + @brief SearchAndReplaceWidget::on_m_replace_all_pb_clicked + Replace all checked item +*/ void SearchAndReplaceWidget::on_m_replace_all_pb_clicked() { if (ui->m_folio_pb->text().endsWith(tr(" [édité]"))) { @@ -1140,10 +1146,10 @@ void SearchAndReplaceWidget::on_m_element_pb_clicked() } /** - * @brief SearchAndReplaceWidget::on_m_mode_cb_currentIndexChanged - * Update the search when user change mode. - * @param index - */ + @brief SearchAndReplaceWidget::on_m_mode_cb_currentIndexChanged + Update the search when user change mode. + @param index +*/ void SearchAndReplaceWidget::on_m_mode_cb_currentIndexChanged(int index) { Q_UNUSED(index); @@ -1151,10 +1157,10 @@ void SearchAndReplaceWidget::on_m_mode_cb_currentIndexChanged(int index) } /** - * @brief SearchAndReplaceWidget::on_m_case_sensitive_cb_stateChanged - * Update the search when change the case sensitive - * @param arg1 - */ + @brief SearchAndReplaceWidget::on_m_case_sensitive_cb_stateChanged + Update the search when change the case sensitive + @param arg1 +*/ void SearchAndReplaceWidget::on_m_case_sensitive_cb_stateChanged(int arg1) { Q_UNUSED(arg1); @@ -1162,9 +1168,9 @@ void SearchAndReplaceWidget::on_m_case_sensitive_cb_stateChanged(int arg1) } /** - * @brief SearchAndReplaceWidget::on_m_conductor_pb_clicked - * Open a dialog to edit the condutor properties - */ + @brief SearchAndReplaceWidget::on_m_conductor_pb_clicked + Open a dialog to edit the condutor properties +*/ void SearchAndReplaceWidget::on_m_conductor_pb_clicked() { ReplaceConductorDialog *dialog = new ReplaceConductorDialog(m_worker.m_conductor_properties, this); @@ -1191,9 +1197,9 @@ void SearchAndReplaceWidget::on_m_conductor_pb_clicked() } /** - * @brief SearchAndReplaceWidget::on_m_advanced_replace_pb_clicked - * Open the advanced editor. - */ + @brief SearchAndReplaceWidget::on_m_advanced_replace_pb_clicked + Open the advanced editor. +*/ void SearchAndReplaceWidget::on_m_advanced_replace_pb_clicked() { replaceAdvancedDialog *dialog = new replaceAdvancedDialog(m_worker.m_advanced_struct, this); diff --git a/sources/autoNum/assignvariables.cpp b/sources/autoNum/assignvariables.cpp index b2962a489..09ea034a9 100644 --- a/sources/autoNum/assignvariables.cpp +++ b/sources/autoNum/assignvariables.cpp @@ -29,8 +29,8 @@ namespace autonum { /** - * @brief sequentialNumbers::sequentialNumbers - */ + @brief sequentialNumbers::sequentialNumbers + */ sequentialNumbers::sequentialNumbers() {} @@ -83,12 +83,13 @@ namespace autonum } /** - * @brief sequentialNumbers::toXml - * export this sequential numbers into a QDomElement. - * @param document : QDomDocument used to create the QDomElement - * @param tag_name : the tag name used for the QDomElement. - * @return A QDomElement, if this sequential have no value, the returned QDomELement is empty - */ + @brief sequentialNumbers::toXml + export this sequential numbers into a QDomElement. + @param document : QDomDocument used to create the QDomElement + @param tag_name : the tag name used for the QDomElement. + @return A QDomElement, if this sequential have no value, + the returned QDomELement is empty + */ QDomElement sequentialNumbers::toXml(QDomDocument &document, const QString& tag_name) const { QDomElement element = document.createElement(tag_name); @@ -110,10 +111,10 @@ namespace autonum } /** - * @brief sequentialNumbers::fromXml - * Import sequential values from a QDomElement - * @param element - */ + @brief sequentialNumbers::fromXml + Import sequential values from a QDomElement + @param element + */ void sequentialNumbers::fromXml(const QDomElement &element) { if (!element.hasChildNodes()) @@ -152,14 +153,17 @@ namespace autonum } /** - * @brief AssignVariables::formulaToLabel - * Return the @formula with variable assigned (ready to be displayed) - * @param formula - the formula to work - * @param seqStruct - struct where is stocked int values (struct is passed as a reference and modified by this static method) - * @param diagram - the diagram where occure the formula. - * @param elmt - parent element (if any) of the formula - * @return the string with variable assigned. - */ + @brief AssignVariables::formulaToLabel + Return the @formula with variable assigned + (ready to be displayed) + @param formula - the formula to work + @param seqStruct - struct where is stocked int values + (struct is passed as a reference + and modified by this static method) + @param diagram - the diagram where occure the formula. + @param elmt - parent element (if any) of the formula + @return the string with variable assigned. + */ QString AssignVariables::formulaToLabel(QString formula, sequentialNumbers &seqStruct, Diagram *diagram, const Element *elmt) { AssignVariables av(std::move(formula), seqStruct, diagram, elmt); @@ -168,12 +172,13 @@ namespace autonum } /** - * @brief AssignVariables::replaceVariable - * Replace the variables in @formula in form %{my-var} to the corresponding value stored in @dc - * @param formula - * @param dc - * @return - */ + @brief AssignVariables::replaceVariable + Replace the variables in @formula in form %{my-var} + to the corresponding value stored in @dc + @param formula + @param dc + @return + */ QString AssignVariables::replaceVariable(const QString &formula, const DiagramContext &dc) { QString str = formula; @@ -297,12 +302,13 @@ namespace autonum } /** - * @brief setSequentialToList - * Append all sequential of type @type owned by @context in list - * @param list : list to have value inserted - * @param context : numerotation context to retrieve value - * @param type : type of sequential (unit, unitfolio, ten, tenfolio, hundred, hundredfolio) - */ + @brief setSequentialToList + Append all sequential of type @type owned by @context in list + @param list : list to have value inserted + @param context : numerotation context to retrieve value + @param type : type of sequential + (unit, unitfolio, ten, tenfolio, hundred, hundredfolio) + */ void setSequentialToList(QStringList &list, NumerotationContext &context, const QString& type) { for (int i = 0; i < context.size(); i++) @@ -321,12 +327,12 @@ namespace autonum } /** - * @brief setFolioSequentialToHash - * Insert all value of @list in @hash with key @autoNumName - * @param list : list to get values from - * @param hash : hash to have values inserted - * @param autoNumName : name to use as key of hash - */ + @brief setFolioSequentialToHash + Insert all value of @list in @hash with key @autoNumName + @param list : list to get values from + @param hash : hash to have values inserted + @param autoNumName : name to use as key of hash + */ void setFolioSequentialToHash(QStringList &list, QHash &hash, const QString& autoNumName) { if (hash.isEmpty() || !hash.contains(autoNumName)) @@ -355,15 +361,20 @@ namespace autonum } /** - * @brief setSequential - * Fill seqStruct - * @param label : label of sequential to fill (%sequ_, %sequf_, %seqt_, ect....) - * @param seqStruct : struct to fill - * @param context : numerotation context use to know the current sequential num. - * @param diagram : diagram where the sequential occur, notably use when label is folio type (%sequf_, %seqtf_, %seqhf_), - * to keep up to date the current sequential of folio. - * @param hashKey : the hash key used to store the sequential for folio type. - */ + @brief setSequential + Fill seqStruct + @param label : label of sequential to fill + (%sequ_, %sequf_, %seqt_, ect....) + @param seqStruct : struct to fill + @param context : numerotation context use + to know the current sequential num. + @param diagram : diagram where the sequential occur, + notably use when label is folio type + (%sequf_, %seqtf_, %seqhf_), + to keep up to date the current sequential of folio. + @param hashKey : + the hash key used to store the sequential for folio type. + */ void setSequential(const QString& label, sequentialNumbers &seqStruct, NumerotationContext &context, Diagram *diagram, const QString& hashKey) { if (!context.isEmpty()) @@ -399,10 +410,10 @@ namespace autonum } /** - * @brief numerotationContextToFormula - * @param nc - * @return the numerotation context, converted to formula - */ + @brief numerotationContextToFormula + @param nc + @return the numerotation context, converted to formula + */ QString numerotationContextToFormula(const NumerotationContext &nc) { QString type; @@ -476,11 +487,13 @@ namespace autonum } /** - * @brief elementPrefixForLocation - * @param location - * @return the prefix for an element represented by location, prefix can be null. - * Search for a prefix only if @location represent an element embedded in a project - */ + @brief elementPrefixForLocation + @param location + @return the prefix for an element represented by location, + prefix can be null. + Search for a prefix only if @location represent + an element embedded in a project + */ QString elementPrefixForLocation(const ElementsLocation &location) { if (!location.isProject()) diff --git a/sources/autoNum/assignvariables.h b/sources/autoNum/assignvariables.h index c695148d1..ee99c4dae 100644 --- a/sources/autoNum/assignvariables.h +++ b/sources/autoNum/assignvariables.h @@ -55,10 +55,10 @@ namespace autonum }; /** - * @brief The AssignVariables class - * This class assign variable of a formula string. - * Return the final string used to be displayed from a formula string. - */ + @brief The AssignVariables class + This class assign variable of a formula string. + Return the final string used to be displayed from a formula string. + */ class AssignVariables { public: diff --git a/sources/autoNum/numerotationcontext.cpp b/sources/autoNum/numerotationcontext.cpp index 99c302b9a..638e81792 100644 --- a/sources/autoNum/numerotationcontext.cpp +++ b/sources/autoNum/numerotationcontext.cpp @@ -21,32 +21,32 @@ #include "qet.h" /** - * Constructor - */ + Constructor +*/ NumerotationContext::NumerotationContext(){ } /** - * Constructor from xml - */ + Constructor from xml +*/ NumerotationContext::NumerotationContext(QDomElement &e) { fromXml(e); } /** - * @brief NumerotationContext::clear, clear the content - */ + @brief NumerotationContext::clear, clear the content +*/ void NumerotationContext::clear () { content_.clear(); } /** - * @brief NumerotationContext::addValue, add a new value on the contexte - * @param type the type of value - * @param value the value itself - * @param increase the increase number of value - * @return true if value is append - */ + @brief NumerotationContext::addValue, add a new value on the contexte + @param type the type of value + @param value the value itself + @param increase the increase number of value + @return true if value is append +*/ bool NumerotationContext::addValue(const QString &type, const QVariant &value, const int increase, const int initialvalue) { if (!keyIsAcceptable(type) && !value.canConvert(QVariant::String)) return false; if (keyIsNumber(type) && !value.canConvert(QVariant::Int)) return false; @@ -58,80 +58,80 @@ bool NumerotationContext::addValue(const QString &type, const QVariant &value, c } /** - * @brief NumerotationContext::operator [] - * @return the string at position @i - */ + @brief NumerotationContext::operator [] + @return the string at position @i +*/ QString NumerotationContext::operator [] (const int &i) const { return (content_.at(i)); } /** - * @brief NumerotationContext::operator << , append other - */ + @brief NumerotationContext::operator << , append other +*/ void NumerotationContext::operator << (const NumerotationContext &other) { for (int i=0; i 0) return false; return true; } /** - * @brief NumerotationContext::itemAt - * @return the content at position @i 1:type 2:value 3:increase - */ + @brief NumerotationContext::itemAt + @return the content at position @i 1:type 2:value 3:increase +*/ QStringList NumerotationContext::itemAt(const int i) const { return (content_.at(i).split("|")); } /** - * @brief validRegExpNum - * @return all type use to numerotation - */ + @brief validRegExpNum + @return all type use to numerotation +*/ QString NumerotationContext::validRegExpNum () const { return ("unit|unitfolio|ten|tenfolio|hundred|hundredfolio|string|idfolio|folio|plant|locmach|elementline|elementcolumn|elementprefix"); } /** - * @brief NumerotationContext::validRegExpNumber - * @return all type represents a number - */ + @brief NumerotationContext::validRegExpNumber + @return all type represents a number +*/ QString NumerotationContext::validRegExpNumber() const { return ("unit|unitfolio|ten|tenfolio|hundred|hundredfolio"); } /** - * @brief NumerotationContext::keyIsAcceptable - * @return true if @type is acceptable - */ + @brief NumerotationContext::keyIsAcceptable + @return true if @type is acceptable +*/ bool NumerotationContext::keyIsAcceptable(const QString &type) const { return (type.contains(QRegExp(validRegExpNum()))); } /** - * @brief NumerotationContext::keyIsNumber - * @return true if @type represent a number - */ + @brief NumerotationContext::keyIsNumber + @return true if @type represent a number +*/ bool NumerotationContext::keyIsNumber(const QString &type) const { return (type.contains(QRegExp(validRegExpNumber()))); } /** - * @brief NumerotationContext::toXml - * Save the numerotation context in a QDomElement under the element name @str - */ + @brief NumerotationContext::toXml + Save the numerotation context in a QDomElement under the element name @str +*/ QDomElement NumerotationContext::toXml(QDomDocument &d, const QString& str) { QDomElement num_auto = d.createElement(str); for (int i=0; idisconnect(); @@ -48,9 +48,9 @@ AutoNumberingDockWidget::~AutoNumberingDockWidget() } /** - * @brief AutoNumberingDockWidget::clear - * Remove all combo box values - */ + @brief AutoNumberingDockWidget::clear + Remove all combo box values +*/ void AutoNumberingDockWidget::clear() { ui->m_conductor_cb->clear(); @@ -67,11 +67,11 @@ void AutoNumberingDockWidget::projectClosed() } /** - * @brief AutoNumberingDockWidget::setProject - * @param project: project to be setted - * @param projectview: projectview to be setted - * assign Project and ProjectView, connect all signals and setContext - */ + @brief AutoNumberingDockWidget::setProject + @param project: project to be setted + @param projectview: projectview to be setted + assign Project and ProjectView, connect all signals and setContext +*/ void AutoNumberingDockWidget::setProject(QETProject *project, ProjectView *projectview) { //Disconnect previous project @@ -133,9 +133,9 @@ void AutoNumberingDockWidget::setProject(QETProject *project, ProjectView *proje } /** - * @brief AutoNumberingDockWidget::setContext - * Add all itens to comboboxes - */ + @brief AutoNumberingDockWidget::setContext + Add all itens to comboboxes +*/ void AutoNumberingDockWidget::setContext() { this->clear(); @@ -165,9 +165,9 @@ void AutoNumberingDockWidget::setContext() { } /** - * @brief AutoNumberingDockWidget::setConductorActive - * @param dv: activated diagramview - */ + @brief AutoNumberingDockWidget::setConductorActive + @param dv: activated diagramview +*/ void AutoNumberingDockWidget::setConductorActive(DiagramView* dv) { if (dv!=nullptr) { QString conductor_autonum = dv->diagram()->conductorsAutonumName(); @@ -177,9 +177,9 @@ void AutoNumberingDockWidget::setConductorActive(DiagramView* dv) { } /** - * @brief AutoNumberingDockWidget::setActive - * Set current used autonumberings - */ + @brief AutoNumberingDockWidget::setActive + Set current used autonumberings +*/ void AutoNumberingDockWidget::setActive() { if (m_project_view!=nullptr) { @@ -206,9 +206,9 @@ void AutoNumberingDockWidget::setActive() { } /** - * @brief AutoNumberingDockWidget::conductorAutoNumChanged - * Add new or remove conductor auto num from combobox - */ + @brief AutoNumberingDockWidget::conductorAutoNumChanged + Add new or remove conductor auto num from combobox +*/ void AutoNumberingDockWidget::conductorAutoNumChanged() { ui->m_conductor_cb->clear(); @@ -222,10 +222,10 @@ void AutoNumberingDockWidget::conductorAutoNumChanged() { } /** - * @brief AutoNumberingDockWidget::on_m_conductor_cb_activated - * @param unused - * Set new conductor AutoNum - */ + @brief AutoNumberingDockWidget::on_m_conductor_cb_activated + @param unused + Set new conductor AutoNum +*/ void AutoNumberingDockWidget::on_m_conductor_cb_activated(int) { QString current_autonum = ui->m_conductor_cb->currentText(); @@ -236,9 +236,9 @@ void AutoNumberingDockWidget::on_m_conductor_cb_activated(int) } /** - * @brief AutoNumberingDockWidget::elementAutoNumChanged - * Add new or remove element auto num from combobox - */ + @brief AutoNumberingDockWidget::elementAutoNumChanged + Add new or remove element auto num from combobox +*/ void AutoNumberingDockWidget::elementAutoNumChanged() { ui->m_element_cb->clear(); @@ -253,10 +253,10 @@ void AutoNumberingDockWidget::elementAutoNumChanged() { } /** - * @brief AutoNumberingDockWidget::on_m_element_cb_activated - * @param unused - * Set new element AutoNum - */ + @brief AutoNumberingDockWidget::on_m_element_cb_activated + @param unused + Set new element AutoNum +*/ void AutoNumberingDockWidget::on_m_element_cb_activated(int) { m_project->setCurrrentElementAutonum(ui->m_element_cb->currentText()); @@ -264,9 +264,9 @@ void AutoNumberingDockWidget::on_m_element_cb_activated(int) } /** - * @brief AutoNumberingDockWidget::folioAutoNumChanged - * Add new or remove folio auto num from combobox - */ + @brief AutoNumberingDockWidget::folioAutoNumChanged + Add new or remove folio auto num from combobox +*/ void AutoNumberingDockWidget::folioAutoNumChanged() { ui->m_folio_cb->clear(); @@ -281,10 +281,10 @@ void AutoNumberingDockWidget::folioAutoNumChanged() { } /** - * @brief AutoNumberingDockWidget::on_m_folio_cb_activated - * @param unused - * Set new folio AutoNum - */ + @brief AutoNumberingDockWidget::on_m_folio_cb_activated + @param unused + Set new folio AutoNum +*/ void AutoNumberingDockWidget::on_m_folio_cb_activated(int) { QString current_autonum = ui->m_folio_cb->currentText(); TitleBlockProperties ip = m_project -> defaultTitleBlockProperties(); diff --git a/sources/autoNum/ui/folioautonumbering.cpp b/sources/autoNum/ui/folioautonumbering.cpp index 71a6373c2..0b5c16448 100644 --- a/sources/autoNum/ui/folioautonumbering.cpp +++ b/sources/autoNum/ui/folioautonumbering.cpp @@ -23,8 +23,8 @@ #include "qetproject.h" #include "diagram.h" /** - * Constructor - */ + Constructor +*/ FolioAutonumberingW::FolioAutonumberingW(QETProject *project, QWidget *parent) : QWidget(parent), project_(project), @@ -39,56 +39,56 @@ FolioAutonumberingW::FolioAutonumberingW(QETProject *project, QWidget *parent) : } /** - * Destructor - */ + Destructor +*/ FolioAutonumberingW::~FolioAutonumberingW() { delete ui; } /** - * @brief FolioAutonumberingW::setContext - * construct autonums in the comboBox selected in the @autonum_chooser QcomboBox - */ + @brief FolioAutonumberingW::setContext + construct autonums in the comboBox selected in the @autonum_chooser QcomboBox +*/ void FolioAutonumberingW::setContext(QList autonums) { foreach (QString str, autonums) { ui->m_autonums_cb->addItem(str);} } /** - * @brief FolioAutonumberingW::autoNumSelected - * returns the current autonum selected - */ + @brief FolioAutonumberingW::autoNumSelected + returns the current autonum selected +*/ QString FolioAutonumberingW::autoNumSelected(){ return ui->m_autonums_cb->currentText(); } /** - * @brief FolioAutonumberingW::fromFolio - * returns the current "From Folio" index - */ + @brief FolioAutonumberingW::fromFolio + returns the current "From Folio" index +*/ int FolioAutonumberingW::fromFolio(){ return ui->m_from_cb->currentIndex()-1; } /** - * @brief FolioAutonumberingW::toFolio - * returns the current "To Folio" index - */ + @brief FolioAutonumberingW::toFolio + returns the current "To Folio" index +*/ int FolioAutonumberingW::toFolio(){ return ui->m_to_cb->currentIndex()+this->fromFolio()+1; } /** - * @brief FolioAutonumberingW::newFoliosNumber - * returns the number of folios to create - */ + @brief FolioAutonumberingW::newFoliosNumber + returns the number of folios to create +*/ int FolioAutonumberingW::newFoliosNumber(){ return ui->m_new_tabs_sb->value(); } /** - * @brief FolioAutonumberingW::updateFolioList - * update Folio List in From and To ComboBox - */ + @brief FolioAutonumberingW::updateFolioList + update Folio List in From and To ComboBox +*/ void FolioAutonumberingW::updateFolioList(){ ui -> m_from_cb->clear(); ui -> m_to_cb->clear(); @@ -100,9 +100,9 @@ void FolioAutonumberingW::updateFolioList(){ } /** - * @brief FolioAutonumberingW::on_m_create_new_tabs_rb_clicked + @brief FolioAutonumberingW::on_m_create_new_tabs_rb_clicked * Enable New Tabs SpinBox - */ +*/ void FolioAutonumberingW::on_m_create_new_tabs_rb_clicked() { ui->m_from_cb->setEnabled(false); ui->m_to_cb->setEnabled(false); @@ -112,9 +112,9 @@ void FolioAutonumberingW::on_m_create_new_tabs_rb_clicked() { } /** - * @brief FolioAutonumberingW::on_m_autonumber_tabs_rb_clicked + @brief FolioAutonumberingW::on_m_autonumber_tabs_rb_clicked * Enable From ComboBox, fill From ComboBox - */ +*/ void FolioAutonumberingW::on_m_autonumber_tabs_rb_clicked() { ui->m_new_tabs_sb->setEnabled(false); ui->m_from_cb->setEnabled(true); @@ -131,18 +131,18 @@ void FolioAutonumberingW::on_m_autonumber_tabs_rb_clicked() { } /** - * @brief FolioAutonumberingW::on_m_new_tabs_sb_valueChanged + @brief FolioAutonumberingW::on_m_new_tabs_sb_valueChanged * Enable Apply if any new folio is to be created - */ +*/ void FolioAutonumberingW::on_m_new_tabs_sb_valueChanged(int){ if (ui->m_new_tabs_sb->value()>0) applyEnable(true); else applyEnable(false); } /** - * @brief FolioAutonumberingW::on_m_from_cb_currentIndexChanged + @brief FolioAutonumberingW::on_m_from_cb_currentIndexChanged * Enable To ComboBox - */ +*/ void FolioAutonumberingW::on_m_from_cb_currentIndexChanged(int){ int index = ui->m_from_cb->currentIndex(); ui->m_to_cb->clear(); @@ -159,9 +159,9 @@ void FolioAutonumberingW::on_m_from_cb_currentIndexChanged(int){ } /** - * @brief SelectAutonumW::on_buttonBox_clicked - * Action on @buttonBox clicked - */ + @brief SelectAutonumW::on_buttonBox_clicked + Action on @buttonBox clicked +*/ void FolioAutonumberingW::on_buttonBox_clicked(QAbstractButton *button) { //transform button to int int answer = ui -> buttonBox -> buttonRole(button); @@ -194,9 +194,9 @@ void FolioAutonumberingW::on_buttonBox_clicked(QAbstractButton *button) { } /** - * @brief SelectAutonumW::applyEnable - * enable/disable the apply button - */ + @brief SelectAutonumW::applyEnable + enable/disable the apply button +*/ void FolioAutonumberingW::applyEnable(bool b) { if (b){ bool valid = true; diff --git a/sources/autoNum/ui/formulaautonumberingw.cpp b/sources/autoNum/ui/formulaautonumberingw.cpp index af9264214..5a2ee35b9 100644 --- a/sources/autoNum/ui/formulaautonumberingw.cpp +++ b/sources/autoNum/ui/formulaautonumberingw.cpp @@ -23,8 +23,8 @@ #include /** - * Constructor - */ + Constructor +*/ FormulaAutonumberingW::FormulaAutonumberingW(QWidget *parent) : QWidget(parent), ui(new Ui::FormulaAutonumberingW) @@ -35,41 +35,41 @@ FormulaAutonumberingW::FormulaAutonumberingW(QWidget *parent) : } /** - * Destructor - */ + Destructor +*/ FormulaAutonumberingW::~FormulaAutonumberingW() { delete ui; } /** - * @brief FormulaAutonumberingW::setContext - * @param formula to be inserted into context - */ + @brief FormulaAutonumberingW::setContext + @param formula to be inserted into context +*/ void FormulaAutonumberingW::setContext(const QString& formula) { ui->m_formula_le->insert(formula); } /** - * @brief FormulaAutonumberingW::clearContext - * @param clear formula line edit text - */ + @brief FormulaAutonumberingW::clearContext + @param clear formula line edit text +*/ void FormulaAutonumberingW::clearContext() { ui->m_formula_le->clear(); } /** - * @brief FormulaAutonumberingW::formula - * @return formula to be stored into project - */ + @brief FormulaAutonumberingW::formula + @return formula to be stored into project +*/ QString FormulaAutonumberingW::formula() { return ui->m_formula_le->text(); } /** - * @brief FormulaAutonumberingW::on_m_formula_le_textChanged - * Update Apply Button - */ + @brief FormulaAutonumberingW::on_m_formula_le_textChanged + Update Apply Button +*/ void FormulaAutonumberingW::on_m_formula_le_textChanged(QString text) { emit (textChanged(std::move(text))); } diff --git a/sources/autoNum/ui/numparteditorw.cpp b/sources/autoNum/ui/numparteditorw.cpp index f632196bc..bc9aa8f24 100644 --- a/sources/autoNum/ui/numparteditorw.cpp +++ b/sources/autoNum/ui/numparteditorw.cpp @@ -20,8 +20,8 @@ #include "ui_numparteditorw.h" /** - * Constructor - */ + Constructor +*/ NumPartEditorW::NumPartEditorW(int type, QWidget *parent) : QWidget(parent), ui(new Ui::NumPartEditorW), @@ -34,9 +34,9 @@ NumPartEditorW::NumPartEditorW(int type, QWidget *parent) : } /** - * Constructor - * Build with value of @context at position i - */ + Constructor + Build with value of @context at position i +*/ NumPartEditorW::NumPartEditorW (NumerotationContext &context, int i, int type, QWidget *parent): QWidget(parent), ui(new Ui::NumPartEditorW), @@ -69,8 +69,8 @@ NumPartEditorW::NumPartEditorW (NumerotationContext &context, int i, int type, Q } /** - * Destructor - */ + Destructor +*/ NumPartEditorW::~NumPartEditorW() { delete intValidator; @@ -102,9 +102,9 @@ void NumPartEditorW::setVisibleItems() } /** - * @brief NumPartEditorW::toNumContext - * @return the display to NumerotationContext - */ + @brief NumPartEditorW::toNumContext + @return the display to NumerotationContext +*/ NumerotationContext NumPartEditorW::toNumContext() { NumerotationContext nc; QString type_str; @@ -160,9 +160,9 @@ NumerotationContext NumPartEditorW::toNumContext() { } /** - * @brief NumPartEditorW::isValid - * @return true if value field isn't empty or if type is folio - */ + @brief NumPartEditorW::isValid + @return true if value field isn't empty or if type is folio +*/ bool NumPartEditorW::isValid() { if (type_ == folio || type_ == idfolio || type_ == elementline || type_ == plant || type_ == locmach || type_ == elementcolumn || type_ == elementprefix) {return true;} @@ -171,9 +171,9 @@ bool NumPartEditorW::isValid() { } /** - * @brief NumPartEditorW::on_type_cb_activated - * Action when user change the type comboBox - */ + @brief NumPartEditorW::on_type_cb_activated + Action when user change the type comboBox +*/ void NumPartEditorW::on_type_cb_activated(int) { if (ui->type_cb->currentText() == tr("Chiffre 1")) setType(unit); @@ -207,27 +207,27 @@ void NumPartEditorW::on_type_cb_activated(int) { } /** - * @brief NumPartEditorW::on_value_field_textChanged - * emit changed when @value_field text changed - */ + @brief NumPartEditorW::on_value_field_textChanged + emit changed when @value_field text changed +*/ void NumPartEditorW::on_value_field_textEdited() { emit changed(); } /** - * @brief NumPartEditorW::on_increase_spinBox_valueChanged - * emit changed when @increase_spinBox value changed - */ + @brief NumPartEditorW::on_increase_spinBox_valueChanged + emit changed when @increase_spinBox value changed +*/ void NumPartEditorW::on_increase_spinBox_valueChanged(int) { if (!ui -> value_field -> text().isEmpty()) emit changed(); } /** - * @brief NumPartEditorW::setType - * Set good behavior by type @t - * @param t, type used - * @param fnum, force the behavior of numeric type - */ + @brief NumPartEditorW::setType + Set good behavior by type @t + @param t, type used + @param fnum, force the behavior of numeric type +*/ void NumPartEditorW::setType(NumPartEditorW::type t, bool fnum) { setCurrentIndex(t); @@ -285,10 +285,10 @@ void NumPartEditorW::setType(NumPartEditorW::type t, bool fnum) { } /** - * @brief NumPartEditorW::setCurrentIndex - * Set Current Index of type_cb - * @param t, type used - */ + @brief NumPartEditorW::setCurrentIndex + Set Current Index of type_cb + @param t, type used +*/ void NumPartEditorW::setCurrentIndex(NumPartEditorW::type t) { int i=-1; if (t == unit) diff --git a/sources/autoNum/ui/numparteditorw.h b/sources/autoNum/ui/numparteditorw.h index c3fcdbb37..a191e25cd 100644 --- a/sources/autoNum/ui/numparteditorw.h +++ b/sources/autoNum/ui/numparteditorw.h @@ -26,7 +26,7 @@ *This class represent a single part num widget. By this widget, we can define and edit *how the num auto must work . *This widget is called by selectautonumw. - */ +*/ namespace Ui { class NumPartEditorW; } diff --git a/sources/autoNum/ui/selectautonumw.cpp b/sources/autoNum/ui/selectautonumw.cpp index 54d099436..5f42abb50 100644 --- a/sources/autoNum/ui/selectautonumw.cpp +++ b/sources/autoNum/ui/selectautonumw.cpp @@ -25,8 +25,8 @@ #include "assignvariables.h" /** - * Constructor - */ + Constructor +*/ SelectAutonumW::SelectAutonumW(int type, QWidget *parent) : QWidget(parent), ui(new Ui::SelectAutonumW), @@ -72,17 +72,17 @@ SelectAutonumW::SelectAutonumW(const NumerotationContext &context, int type, QWi } /** - * Destructor - */ + Destructor +*/ SelectAutonumW::~SelectAutonumW() { delete ui; } /** - * @brief SelectAutonumW::setCurrentContext - * build the context of current diagram selected in the @diagram_chooser QcomboBox - */ + @brief SelectAutonumW::setCurrentContext + build the context of current diagram selected in the @diagram_chooser QcomboBox +*/ void SelectAutonumW::setContext(const NumerotationContext &context) { m_context = context; @@ -109,9 +109,9 @@ void SelectAutonumW::setContext(const NumerotationContext &context) { } /** - * @brief SelectAutonumW::toNumContext - * @return the content to @num_part_list to NumerotationContext - */ + @brief SelectAutonumW::toNumContext + @return the content to @num_part_list to NumerotationContext +*/ NumerotationContext SelectAutonumW::toNumContext() const { NumerotationContext nc; foreach (NumPartEditorW *npew, num_part_list_) nc << npew -> toNumContext(); @@ -119,9 +119,9 @@ NumerotationContext SelectAutonumW::toNumContext() const { } /** - * @brief SelectAutonumW::on_add_button_clicked + @brief SelectAutonumW::on_add_button_clicked * Action on add_button, add a @NumPartEditor - */ +*/ void SelectAutonumW::on_add_button_clicked() { applyEnable(false); @@ -133,9 +133,9 @@ void SelectAutonumW::on_add_button_clicked() } /** - * @brief SelectAutonumW::on_remove_button_clicked + @brief SelectAutonumW::on_remove_button_clicked * Action on remove button, remove the last @NumPartEditor - */ +*/ void SelectAutonumW::on_remove_button_clicked() { //remove if @num_part_list contains more than one item if (num_part_list_.size() > 1) { @@ -150,9 +150,9 @@ void SelectAutonumW::on_remove_button_clicked() { } /** - * @brief SelectAutonumW::formula - * @return autonumbering widget formula - */ + @brief SelectAutonumW::formula + @return autonumbering widget formula +*/ QString SelectAutonumW::formula() { if (m_edited_type == 0) @@ -169,9 +169,9 @@ QComboBox *SelectAutonumW::contextComboBox() const } /** - * @brief SelectAutonumW::on_buttonBox_clicked - * Action on @buttonBox clicked - */ + @brief SelectAutonumW::on_buttonBox_clicked + Action on @buttonBox clicked +*/ void SelectAutonumW::on_buttonBox_clicked(QAbstractButton *button) { //transform button to int int answer = ui -> buttonBox -> buttonRole(button); @@ -233,9 +233,9 @@ void SelectAutonumW::on_buttonBox_clicked(QAbstractButton *button) { } /** - * @brief SelectAutonumW::applyEnable - * enable/disable the apply button - */ + @brief SelectAutonumW::applyEnable + enable/disable the apply button +*/ void SelectAutonumW::applyEnable(bool b) { if (b){ bool valid= true; @@ -252,9 +252,9 @@ void SelectAutonumW::applyEnable(bool b) { } /** - * @brief SelectAutonumW::contextToFormula - * Apply formula to ElementAutonumbering Widget - */ + @brief SelectAutonumW::contextToFormula + Apply formula to ElementAutonumbering Widget +*/ void SelectAutonumW::contextToFormula() { FormulaAutonumberingW* m_faw = nullptr; @@ -271,9 +271,9 @@ void SelectAutonumW::contextToFormula() } /** - * @brief SelectAutonumW::on_m_next_pb_clicked - * Increase NumerotationContext - */ + @brief SelectAutonumW::on_m_next_pb_clicked + Increase NumerotationContext +*/ void SelectAutonumW::on_m_next_pb_clicked() { NumerotationContextCommands ncc (toNumContext()); @@ -282,9 +282,9 @@ void SelectAutonumW::on_m_next_pb_clicked() } /** - * @brief SelectAutonumW::on_m_previous_pb_clicked - * Decrease NumerotationContext - */ + @brief SelectAutonumW::on_m_previous_pb_clicked + Decrease NumerotationContext +*/ void SelectAutonumW::on_m_previous_pb_clicked() { NumerotationContextCommands ncc (toNumContext()); diff --git a/sources/bordertitleblock.cpp b/sources/bordertitleblock.cpp index a416140bd..1a9f9b207 100644 --- a/sources/bordertitleblock.cpp +++ b/sources/bordertitleblock.cpp @@ -605,13 +605,13 @@ void BorderTitleBlock::draw(QPainter *painter) } /** - * @brief BorderTitleBlock::drawDxf - * @param width - * @param height - * @param keep_aspect_ratio - * @param file_path - * @param color - */ + @brief BorderTitleBlock::drawDxf + @param width + @param height + @param keep_aspect_ratio + @param file_path + @param color +*/ void BorderTitleBlock::drawDxf( int width, int height, diff --git a/sources/conductornumexport.cpp b/sources/conductornumexport.cpp index b694a9cc3..86c65f5b7 100644 --- a/sources/conductornumexport.cpp +++ b/sources/conductornumexport.cpp @@ -26,10 +26,10 @@ #include /** - * @brief ConductorNumExport::ConductorNumExport - * @param project : the project to export the conductors num - * @param parent : parent widget - */ + @brief ConductorNumExport::ConductorNumExport + @param project : the project to export the conductors num + @param parent : parent widget +*/ ConductorNumExport::ConductorNumExport(QETProject *project, QWidget *parent) : m_project(project), m_parent_widget(parent) @@ -38,10 +38,10 @@ ConductorNumExport::ConductorNumExport(QETProject *project, QWidget *parent) : } /** - * @brief ConductorNumExport::toCsv - * Export the num of conductors into a csv file. - * @return true if suceesfully exported. - */ + @brief ConductorNumExport::toCsv + Export the num of conductors into a csv file. + @return true if suceesfully exported. +*/ bool ConductorNumExport::toCsv() { QString name = QObject::tr("numero_de_fileries_") + m_project->title() + ".csv"; @@ -86,9 +86,9 @@ bool ConductorNumExport::toCsv() } /** - * @brief ConductorNumExport::wiresNum - * @return the wire num formated in csv - */ + @brief ConductorNumExport::wiresNum + @return the wire num formated in csv +*/ QString ConductorNumExport::wiresNum() const { QString csv; @@ -106,9 +106,9 @@ QString ConductorNumExport::wiresNum() const } /** - * @brief ConductorNumExport::fillHash - * @value m_hash - */ + @brief ConductorNumExport::fillHash + @value m_hash +*/ void ConductorNumExport::fillHash() { //We used this rx to avoid insert num composed only withe white space. diff --git a/sources/conductornumexport.h b/sources/conductornumexport.h index 0368482ee..973da3f7b 100644 --- a/sources/conductornumexport.h +++ b/sources/conductornumexport.h @@ -24,9 +24,9 @@ class QETProject; class QWidget; /** - * @brief The ConductorNumExport class - * A class to export the num of conductors into a csv file. - */ + @brief The ConductorNumExport class + A class to export the num of conductors into a csv file. +*/ class ConductorNumExport { public: diff --git a/sources/conductorproperties.cpp b/sources/conductorproperties.cpp index 40bcf4499..2ae95ea70 100644 --- a/sources/conductorproperties.cpp +++ b/sources/conductorproperties.cpp @@ -241,10 +241,10 @@ ConductorProperties::~ConductorProperties() { /** - * @brief ConductorProperties::toXml - * Export conductor propertie, in the XML element 'e' - * @param e the xml element - */ + @brief ConductorProperties::toXml + Export conductor propertie, in the XML element 'e' + @param e the xml element +*/ void ConductorProperties::toXml(QDomElement &e) const { e.setAttribute("type", typeToString(type)); @@ -284,10 +284,10 @@ void ConductorProperties::toXml(QDomElement &e) const /** - * @brief ConductorProperties::fromXml - * Import conductor propertie, from the attribute of the xml element 'e' - * @param e the xml document - */ + @brief ConductorProperties::fromXml + Import conductor propertie, from the attribute of the xml element 'e' + @param e the xml document +*/ void ConductorProperties::fromXml(QDomElement &e) { // get conductor color @@ -440,11 +440,11 @@ QString ConductorProperties::typeToString(ConductorType t) } /** - * @brief ConductorProperties::applyForEqualAttributes - * Test each attribute of properties in the list separatly. - * For each attributes, if is equal, the attribute is apply to this. - * @param list - */ + @brief ConductorProperties::applyForEqualAttributes + Test each attribute of properties in the list separatly. + For each attributes, if is equal, the attribute is apply to this. + @param list +*/ void ConductorProperties::applyForEqualAttributes(QList list) { const QList clist = std::move(list); @@ -698,9 +698,9 @@ void ConductorProperties::applyForEqualAttributes(QList lis } /** - * @brief ConductorProperties::defaultProperties - * @return the default properties stored in the setting file - */ + @brief ConductorProperties::defaultProperties + @return the default properties stored in the setting file +*/ ConductorProperties ConductorProperties::defaultProperties() { QSettings settings; @@ -712,10 +712,10 @@ ConductorProperties ConductorProperties::defaultProperties() } /** - * @brief ConductorProperties::operator == - * @param other - * @return true if other == this - */ + @brief ConductorProperties::operator == + @param other + @return true if other == this +*/ bool ConductorProperties::operator==(const ConductorProperties &other) const { return( diff --git a/sources/configdialog.cpp b/sources/configdialog.cpp index 1d5889ccf..3981734b7 100644 --- a/sources/configdialog.cpp +++ b/sources/configdialog.cpp @@ -137,10 +137,10 @@ void ConfigDialog::addPage(ConfigPage *page) { } /** - * @brief ConfigDialog::setCurrentPage - * Set the current index to @index - * @param index - */ + @brief ConfigDialog::setCurrentPage + Set the current index to @index + @param index +*/ void ConfigDialog::setCurrentPage(const int index) { pages_list->setCurrentRow(index); } diff --git a/sources/configpages.cpp b/sources/configpages.cpp index 80626c650..b0b228965 100644 --- a/sources/configpages.cpp +++ b/sources/configpages.cpp @@ -33,12 +33,12 @@ #include /** - * @brief NewDiagramPage::NewDiagramPage - * Default constructor - * @param project, If project, edit the propertie of Project - * else edit the properties by default of QElectroTech - * @param parent, parent widget - */ + @brief NewDiagramPage::NewDiagramPage + Default constructor + @param project, If project, edit the propertie of Project + else edit the properties by default of QElectroTech + @param parent, parent widget +*/ NewDiagramPage::NewDiagramPage(QETProject *project, QWidget *parent, ProjectPropertiesDialog *ppd) : ConfigPage (parent), ppd_ (ppd), @@ -93,18 +93,18 @@ NewDiagramPage::NewDiagramPage(QETProject *project, QWidget *parent, ProjectProp } /** - * @brief NewDiagramPage::~NewDiagramPage - */ + @brief NewDiagramPage::~NewDiagramPage +*/ NewDiagramPage::~NewDiagramPage() { disconnect(ipw,SIGNAL(openAutoNumFolioEditor(QString)),this,SLOT(changeToAutoFolioTab())); } /** - * @brief NewDiagramPage::applyConf - * Apply conf for this page. - * If there is a project, save in the project, - * else save to the default conf of QElectroTech - */ + @brief NewDiagramPage::applyConf + Apply conf for this page. + If there is a project, save in the project, + else save to the default conf of QElectroTech +*/ void NewDiagramPage::applyConf() { if (m_project) { //If project we save to the project if (m_project -> isReadOnly()) return; @@ -171,27 +171,27 @@ void NewDiagramPage::applyConf() { } /** - * @brief NewDiagramPage::icon - * @return icon of this page - */ + @brief NewDiagramPage::icon + @return icon of this page +*/ QIcon NewDiagramPage::icon() const { if (m_project) return(QET::Icons::NewDiagram); return(QET::Icons::Projects); } /** - * @brief NewDiagramPage::title - * @return title of this page - */ + @brief NewDiagramPage::title + @return title of this page +*/ QString NewDiagramPage::title() const { if (m_project) return(tr("Nouveau folio", "configuration page title")); return(tr("Nouveau projet", "configuration page title")); } /** - * @brief NewDiagramPage::changeToAutoFolioTab - * Set the current tab to Autonum - */ + @brief NewDiagramPage::changeToAutoFolioTab + Set the current tab to Autonum +*/ void NewDiagramPage::changeToAutoFolioTab(){ if (m_project){ ppd_->setCurrentPage(ProjectPropertiesDialog::Autonum); @@ -201,9 +201,9 @@ void NewDiagramPage::changeToAutoFolioTab(){ } /** - * @brief NewDiagramPage::setFolioAutonum - * Set temporary TBP to use in auto folio num - */ + @brief NewDiagramPage::setFolioAutonum + Set temporary TBP to use in auto folio num +*/ void NewDiagramPage::setFolioAutonum(QString autoNum){ TitleBlockProperties tbptemp = ipw->propertiesAutoNum(std::move(autoNum)); ipw->setProperties(tbptemp); @@ -211,17 +211,17 @@ void NewDiagramPage::setFolioAutonum(QString autoNum){ } /** - * @brief NewDiagramPage::saveCurrentTbp - * Save current TBP to retrieve after auto folio num - */ + @brief NewDiagramPage::saveCurrentTbp + Save current TBP to retrieve after auto folio num +*/ void NewDiagramPage::saveCurrentTbp(){ savedTbp = ipw->properties(); } /** - * @brief NewDiagramPage::loadSavedTbp - * Retrieve saved auto folio num - */ + @brief NewDiagramPage::loadSavedTbp + Retrieve saved auto folio num +*/ void NewDiagramPage::loadSavedTbp(){ ipw->setProperties(savedTbp); applyConf(); @@ -304,9 +304,9 @@ PrintConfigPage::~PrintConfigPage() { } /** - * @brief PrintConfigPage::applyConf - * Apply the config of this page - */ + @brief PrintConfigPage::applyConf + Apply the config of this page +*/ void PrintConfigPage::applyConf() { QString prefix = "print/default"; diff --git a/sources/createdxf.cpp b/sources/createdxf.cpp index 5e04ed579..861cf77c1 100644 --- a/sources/createdxf.cpp +++ b/sources/createdxf.cpp @@ -378,14 +378,14 @@ long Createdxf::RGBcodeTable[255]{ }; /** - * @brief Createdxf::getcolorCode - * This function returns the ACI color which is the "nearest" color to - * the color defined by the red, green and blue (RGB) values passed - * in argument. - * @param red - * @param green - * @param blue - */ + @brief Createdxf::getcolorCode + This function returns the ACI color which is the "nearest" color to + the color defined by the red, green and blue (RGB) values passed + in argument. + @param red + @param green + @param blue +*/ int Createdxf::getcolorCode (const long red, const long green, const long blue) { long acirgb, r,g,b; @@ -409,12 +409,12 @@ int Createdxf::getcolorCode (const long red, const long green, const long blue) } /** - * @brief Createdxf::drawLine - * Conveniance function to draw line - * @param filepath - * @param line - * @param colorcode - */ + @brief Createdxf::drawLine + Conveniance function to draw line + @param filepath + @param line + @param colorcode +*/ void Createdxf::drawLine(const QString &filepath, const QLineF &line, const int &colorcode) { drawLine(filepath, line.p1().x() * xScale, sheetHeight - (line.p1().y() * yScale), @@ -547,12 +547,12 @@ void Createdxf::drawArcEllipse(const QString &file_path, qreal x, qreal y, qreal } /** - * @brief Createdxf::drawEllipse - * Conveniance function for draw ellipse - * @param filepath - * @param rect - * @param colorcode - */ + @brief Createdxf::drawEllipse + Conveniance function for draw ellipse + @param filepath + @param rect + @param colorcode +*/ void Createdxf::drawEllipse(const QString &filepath, const QRectF &rect, const int &colorcode) { drawArcEllipse(filepath, rect.topLeft().x() * xScale, sheetHeight - (rect.topLeft().y() * yScale), @@ -653,12 +653,12 @@ void Createdxf::drawRectangle (const QString &fileName, double x1, double y1, do } /** - * @brief Createdxf::drawRectangle - * Conveniance function for draw rectangle - * @param filepath - * @param rect - * @param color - */ + @brief Createdxf::drawRectangle + Conveniance function for draw rectangle + @param filepath + @param rect + @param color +*/ void Createdxf::drawRectangle(const QString &filepath, const QRectF &rect, const int &colorcode) { drawRectangle(filepath, rect.bottomLeft().x() * xScale, sheetHeight - (rect.bottomLeft().y() * yScale), diff --git a/sources/dataBase/projectdatabase.cpp b/sources/dataBase/projectdatabase.cpp index 93e3cea9c..9313a6e43 100644 --- a/sources/dataBase/projectdatabase.cpp +++ b/sources/dataBase/projectdatabase.cpp @@ -26,11 +26,11 @@ #include /** - * @brief projectDataBase::projectDataBase - * Default constructor - * @param project : project from the database work - * @param parent : parent QObject - */ + @brief projectDataBase::projectDataBase + Default constructor + @param project : project from the database work + @param parent : parent QObject +*/ projectDataBase::projectDataBase(QETProject *project, QObject *parent) : QObject(parent), m_project(project) @@ -46,18 +46,18 @@ projectDataBase::projectDataBase(QETProject *project, const QString &connection_ } /** - * @brief projectDataBase::~projectDataBase - * Destructor - */ + @brief projectDataBase::~projectDataBase + Destructor +*/ projectDataBase::~projectDataBase() { m_data_base.close(); } /** - * @brief projectDataBase::updateDB - * Up to date the content of the data base. - * Emit the signal dataBaseUpdated - */ + @brief projectDataBase::updateDB + Up to date the content of the data base. + Emit the signal dataBaseUpdated +*/ void projectDataBase::updateDB() { populateDiagramTable(); @@ -68,25 +68,25 @@ void projectDataBase::updateDB() } /** - * @brief projectDataBase::project - * @return the project of this database - */ + @brief projectDataBase::project + @return the project of this database +*/ QETProject *projectDataBase::project() const { return m_project; } /** - * @brief projectDataBase::newQuery - * @return a QSqlquery with @query as query and the internal database of this class as database to use. - */ + @brief projectDataBase::newQuery + @return a QSqlquery with @query as query and the internal database of this class as database to use. +*/ QSqlQuery projectDataBase::newQuery(const QString &query) { return QSqlQuery(query, m_data_base); } /** - * @brief projectDataBase::addElement - * @param element - */ + @brief projectDataBase::addElement + @param element +*/ void projectDataBase::addElement(Element *element) { m_insert_elements_query.bindValue(":uuid", element->uuid().toString()); @@ -115,9 +115,9 @@ void projectDataBase::addElement(Element *element) } /** - * @brief projectDataBase::removeElement - * @param element - */ + @brief projectDataBase::removeElement + @param element +*/ void projectDataBase::removeElement(Element *element) { m_remove_element_query.bindValue(":uuid", element->uuid().toString()); @@ -129,9 +129,9 @@ void projectDataBase::removeElement(Element *element) } /** - * @brief projectDataBase::elementInfoChanged - * @param element - */ + @brief projectDataBase::elementInfoChanged + @param element +*/ void projectDataBase::elementInfoChanged(Element *element) { auto hash = elementInfoToString(element); @@ -186,10 +186,10 @@ void projectDataBase::removeDiagram(Diagram *diagram) } /** - * @brief projectDataBase::createDataBase - * Create the data base - * @return : true if the data base was successfully created. - */ + @brief projectDataBase::createDataBase + Create the data base + @return : true if the data base was successfully created. +*/ bool projectDataBase::createDataBase(const QString &connection_name, const QString &name) { @@ -285,8 +285,8 @@ bool projectDataBase::createDataBase(const QString &connection_name, const QStri } /** - * @brief projectDataBase::createElementNomenclatureView - */ + @brief projectDataBase::createElementNomenclatureView +*/ void projectDataBase::createElementNomenclatureView() { QString create_view ("CREATE VIEW element_nomenclature_view AS SELECT " @@ -322,8 +322,8 @@ void projectDataBase::createElementNomenclatureView() } /** - * @brief projectDataBase::createSummaryView - */ + @brief projectDataBase::createSummaryView +*/ void projectDataBase::createSummaryView() { QString create_view ("CREATE VIEW project_summary_view AS SELECT " @@ -360,9 +360,9 @@ void projectDataBase::populateDiagramTable() } /** - * @brief projectDataBase::populateElementTable - * Populate the element table - */ + @brief projectDataBase::populateElementTable + Populate the element table +*/ void projectDataBase::populateElementTable() { QSqlQuery query_(m_data_base); @@ -388,9 +388,9 @@ void projectDataBase::populateElementTable() } /** - * @brief projectDataBase::populateElementsTable - * Populate the elements table - */ + @brief projectDataBase::populateElementsTable + Populate the elements table +*/ void projectDataBase::populateElementInfoTable() { QSqlQuery query(m_data_base); @@ -506,10 +506,10 @@ void projectDataBase::prepareQuery() } /** - * @brief projectDataBase::elementInfoToString - * @param elmt - * @return the element information in hash as key for the info name and value as the information value. - */ + @brief projectDataBase::elementInfoToString + @param elmt + @return the element information in hash as key for the info name and value as the information value. +*/ QHash projectDataBase::elementInfoToString(Element *elmt) { QHash hash; //Store the value for each columns @@ -527,14 +527,14 @@ QHash projectDataBase::elementInfoToString(Element *elmt) } /** - * @brief projectDataBase::exportDb - * @param parent - * @param caption - * @param dir - * @param filter - * @param selectedFilter - * @param options - */ + @brief projectDataBase::exportDb + @param parent + @param caption + @param dir + @param filter + @param selectedFilter + @param options +*/ void projectDataBase::exportDb(projectDataBase *db, QWidget *parent, const QString &caption, const QString &dir) { auto caption_ = caption; diff --git a/sources/dataBase/projectdatabase.h b/sources/dataBase/projectdatabase.h index bcfca5659..d98d44eff 100644 --- a/sources/dataBase/projectdatabase.h +++ b/sources/dataBase/projectdatabase.h @@ -29,12 +29,12 @@ class QETProject; class Diagram; /** - * @brief The projectDataBase class - * This class wrap a sqlite data base where you can find several thing about - * the content of a project. + @brief The projectDataBase class + This class wrap a sqlite data base where you can find several thing about + the content of a project. * - * NOTE this class is still in developement. - */ + @note this class is still in developement. +*/ class projectDataBase : public QObject { Q_OBJECT diff --git a/sources/dataBase/ui/elementquerywidget.cpp b/sources/dataBase/ui/elementquerywidget.cpp index 9df711c3f..d23bf8695 100644 --- a/sources/dataBase/ui/elementquerywidget.cpp +++ b/sources/dataBase/ui/elementquerywidget.cpp @@ -22,9 +22,9 @@ #include /** - * @brief ElementQueryWidget::ElementQueryWidget - * @param parent - */ + @brief ElementQueryWidget::ElementQueryWidget + @param parent +*/ ElementQueryWidget::ElementQueryWidget(QWidget *parent) : QWidget(parent), ui(new Ui::ElementQueryWidget) @@ -96,18 +96,18 @@ ElementQueryWidget::ElementQueryWidget(QWidget *parent) : } /** - * @brief ElementQueryWidget::~ElementQueryWidget - */ + @brief ElementQueryWidget::~ElementQueryWidget +*/ ElementQueryWidget::~ElementQueryWidget() { delete ui; } /** - * @brief ElementQueryWidget::setQuery - * @param query - * Set the current query to @query. - * If it's possible, rebuild the state of the widget from the query - */ + @brief ElementQueryWidget::setQuery + @param query + Set the current query to @query. + If it's possible, rebuild the state of the widget from the query +*/ void ElementQueryWidget::setQuery(const QString &query) { if (query.startsWith("SELECT")) @@ -271,9 +271,9 @@ void ElementQueryWidget::setQuery(const QString &query) } /** - * @brief ElementQueryWidget::queryStr - * @return The current query - */ + @brief ElementQueryWidget::queryStr + @return The current query +*/ QString ElementQueryWidget::queryStr() const { //User define is own query @@ -370,16 +370,16 @@ QString ElementQueryWidget::queryStr() const } /** - * @brief ElementQueryWidget::updateQueryLine - */ + @brief ElementQueryWidget::updateQueryLine +*/ void ElementQueryWidget::updateQueryLine() { ui->m_sql_query->setText(queryStr()); } /** - * @brief ElementQueryWidget::selectedKeys - * @return the current keys of selected infos to be exported - */ + @brief ElementQueryWidget::selectedKeys + @return the current keys of selected infos to be exported +*/ QStringList ElementQueryWidget::selectedKeys() const { //Made a string list with the colomns (keys) choosen by the user @@ -395,8 +395,8 @@ QStringList ElementQueryWidget::selectedKeys() const } /** - * @brief ElementQueryWidget::setUpItems - */ + @brief ElementQueryWidget::setUpItems +*/ void ElementQueryWidget::setUpItems() { for(QString key : QETApp::elementInfoKeys()) @@ -419,18 +419,18 @@ void ElementQueryWidget::setUpItems() } /** - * @brief ElementQueryWidget::FilterFor - * @param key - * @return the filter associated to key - */ + @brief ElementQueryWidget::FilterFor + @param key + @return the filter associated to key +*/ QPair ElementQueryWidget::FilterFor(const QString &key) const { return m_filter.value(key, qMakePair(0, QString())); } /** - * @brief ElementQueryWidget::fillSavedQuery - * Fill the combobox of saved queries - */ + @brief ElementQueryWidget::fillSavedQuery + Fill the combobox of saved queries +*/ void ElementQueryWidget::fillSavedQuery() { QFile file(QETApp::configDir() + "/nomenclature.json"); @@ -446,8 +446,8 @@ void ElementQueryWidget::fillSavedQuery() } /** - * @brief ElementQueryWidget::on_m_up_pb_clicked - */ + @brief ElementQueryWidget::on_m_up_pb_clicked +*/ void ElementQueryWidget::on_m_up_pb_clicked() { auto row = ui->m_choosen_list->currentRow(); @@ -463,8 +463,8 @@ void ElementQueryWidget::on_m_up_pb_clicked() } /** - * @brief ElementQueryWidget::on_m_add_pb_clicked - */ + @brief ElementQueryWidget::on_m_add_pb_clicked +*/ void ElementQueryWidget::on_m_add_pb_clicked() { if (auto *item = ui->m_var_list->takeItem(ui->m_var_list->currentRow())) { @@ -475,8 +475,8 @@ void ElementQueryWidget::on_m_add_pb_clicked() } /** - * @brief ElementQueryWidget::on_m_remove_pb_clicked - */ + @brief ElementQueryWidget::on_m_remove_pb_clicked +*/ void ElementQueryWidget::on_m_remove_pb_clicked() { if (auto *item = ui->m_choosen_list->takeItem(ui->m_choosen_list->currentRow())) { @@ -487,8 +487,8 @@ void ElementQueryWidget::on_m_remove_pb_clicked() } /** - * @brief ElementQueryWidget::on_m_down_pb_clicked - */ + @brief ElementQueryWidget::on_m_down_pb_clicked +*/ void ElementQueryWidget::on_m_down_pb_clicked() { auto row = ui->m_choosen_list->currentRow(); @@ -504,8 +504,8 @@ void ElementQueryWidget::on_m_down_pb_clicked() } /** - * @brief ElementQueryWidget::on_m_edit_sql_query_cb_clicked - */ + @brief ElementQueryWidget::on_m_edit_sql_query_cb_clicked +*/ void ElementQueryWidget::on_m_edit_sql_query_cb_clicked() { ui->m_sql_query->setEnabled(ui->m_edit_sql_query_cb->isChecked()); @@ -524,9 +524,9 @@ void ElementQueryWidget::on_m_edit_sql_query_cb_clicked() } /** - * @brief ElementQueryWidget::on_m_filter_le_textEdited - * @param arg1 - */ + @brief ElementQueryWidget::on_m_filter_le_textEdited + @param arg1 +*/ void ElementQueryWidget::on_m_filter_le_textEdited(const QString &arg1) { if (auto item = ui->m_choosen_list->currentItem()) @@ -541,9 +541,9 @@ void ElementQueryWidget::on_m_filter_le_textEdited(const QString &arg1) } /** - * @brief ElementQueryWidget::on_m_filter_type_cb_activated - * @param index - */ + @brief ElementQueryWidget::on_m_filter_type_cb_activated + @param index +*/ void ElementQueryWidget::on_m_filter_type_cb_activated(int index) { if (auto item = ui->m_choosen_list->currentItem()) @@ -559,9 +559,9 @@ void ElementQueryWidget::on_m_filter_type_cb_activated(int index) } /** - * @brief ElementQueryWidget::on_m_load_pb_clicked - * Load a query from nomenclature.json file - */ + @brief ElementQueryWidget::on_m_load_pb_clicked + Load a query from nomenclature.json file +*/ void ElementQueryWidget::on_m_load_pb_clicked() { auto name = ui->m_conf_cb->currentText(); @@ -589,9 +589,9 @@ void ElementQueryWidget::on_m_load_pb_clicked() } /** - * @brief ElementQueryWidget::on_m_save_current_conf_pb_clicked - * Save the actual query to nomenclature.json file - */ + @brief ElementQueryWidget::on_m_save_current_conf_pb_clicked + Save the actual query to nomenclature.json file +*/ void ElementQueryWidget::on_m_save_current_conf_pb_clicked() { QFile file_(QETApp::configDir() + "/nomenclature.json"); @@ -648,9 +648,9 @@ void ElementQueryWidget::on_m_choosen_list_itemDoubleClicked(QListWidgetItem *it } /** - * @brief ElementQueryWidget::reset - * Clear this widget aka set to initial state - */ + @brief ElementQueryWidget::reset + Clear this widget aka set to initial state +*/ void ElementQueryWidget::reset() { //Ugly hack to force to remove all selected infos diff --git a/sources/dataBase/ui/elementquerywidget.h b/sources/dataBase/ui/elementquerywidget.h index 977a8d74e..5b7effab5 100644 --- a/sources/dataBase/ui/elementquerywidget.h +++ b/sources/dataBase/ui/elementquerywidget.h @@ -28,10 +28,10 @@ class ElementQueryWidget; } /** - * @brief The ElementQueryWidget class - * A widget use to edit a sql query for get element information - * This widget only work to get information from ProjectDataBase - */ + @brief The ElementQueryWidget class + A widget use to edit a sql query for get element information + This widget only work to get information from ProjectDataBase +*/ class ElementQueryWidget : public QWidget { Q_OBJECT diff --git a/sources/dataBase/ui/summaryquerywidget.cpp b/sources/dataBase/ui/summaryquerywidget.cpp index 7f84fa804..5e6a8b4e7 100644 --- a/sources/dataBase/ui/summaryquerywidget.cpp +++ b/sources/dataBase/ui/summaryquerywidget.cpp @@ -22,9 +22,9 @@ #include /** - * @brief SummaryQueryWidget::SummaryQueryWidget - * @param parent - */ + @brief SummaryQueryWidget::SummaryQueryWidget + @param parent +*/ SummaryQueryWidget::SummaryQueryWidget(QWidget *parent) : QWidget(parent), ui(new Ui::SummaryQueryWidget) @@ -39,17 +39,17 @@ SummaryQueryWidget::SummaryQueryWidget(QWidget *parent) : } /** - * @brief SummaryQueryWidget::~SummaryQueryWidget - */ + @brief SummaryQueryWidget::~SummaryQueryWidget +*/ SummaryQueryWidget::~SummaryQueryWidget() { delete ui; } /** - * @brief SummaryQueryWidget::queryStr - * @return The current query string - */ + @brief SummaryQueryWidget::queryStr + @return The current query string +*/ QString SummaryQueryWidget::queryStr() const { //User define is own query @@ -80,11 +80,11 @@ QString SummaryQueryWidget::queryStr() const } /** - * @brief SummaryQueryWidget::setQuery - * @param query - * set the current query to @query. - * If it's possible, rebuild the state of the widget from the query - */ + @brief SummaryQueryWidget::setQuery + @param query + set the current query to @query. + If it's possible, rebuild the state of the widget from the query +*/ void SummaryQueryWidget::setQuery(const QString &query) { if (query.startsWith("SELECT")) @@ -114,8 +114,8 @@ void SummaryQueryWidget::setQuery(const QString &query) } /** - * @brief SummaryQueryWidget::setUpItems - */ + @brief SummaryQueryWidget::setUpItems +*/ void SummaryQueryWidget::setUpItems() { for (auto key : QETApp::diagramInfoKeys()) @@ -133,9 +133,9 @@ void SummaryQueryWidget::setUpItems() } /** - * @brief SummaryQueryWidget::fillSavedQuery - * Fill the combo box of the saved query - */ + @brief SummaryQueryWidget::fillSavedQuery + Fill the combo box of the saved query +*/ void SummaryQueryWidget::fillSavedQuery() { QFile file(QETApp::configDir() + "/summary.json"); @@ -151,16 +151,16 @@ void SummaryQueryWidget::fillSavedQuery() } /** - * @brief SummaryQueryWidget::updateQueryLine - */ + @brief SummaryQueryWidget::updateQueryLine +*/ void SummaryQueryWidget::updateQueryLine() { ui->m_user_query_le->setText(queryStr()); } /** - * @brief SummaryQueryWidget::selectedKeys - * @return - */ + @brief SummaryQueryWidget::selectedKeys + @return +*/ QStringList SummaryQueryWidget::selectedKeys() const { //Made a string list with the colomns (keys) choosen by the user @@ -176,9 +176,9 @@ QStringList SummaryQueryWidget::selectedKeys() const } /** - * @brief SummaryQueryWidget::on_m_available_list_itemDoubleClicked - * @param item - */ + @brief SummaryQueryWidget::on_m_available_list_itemDoubleClicked + @param item +*/ void SummaryQueryWidget::on_m_available_list_itemDoubleClicked(QListWidgetItem *item) { Q_UNUSED(item) @@ -186,9 +186,9 @@ void SummaryQueryWidget::on_m_available_list_itemDoubleClicked(QListWidgetItem * } /** - * @brief SummaryQueryWidget::on_m_choosen_list_itemDoubleClicked - * @param item - */ + @brief SummaryQueryWidget::on_m_choosen_list_itemDoubleClicked + @param item +*/ void SummaryQueryWidget::on_m_choosen_list_itemDoubleClicked(QListWidgetItem *item) { Q_UNUSED(item) @@ -196,8 +196,8 @@ void SummaryQueryWidget::on_m_choosen_list_itemDoubleClicked(QListWidgetItem *it } /** - * @brief SummaryQueryWidget::on_m_up_pb_clicked - */ + @brief SummaryQueryWidget::on_m_up_pb_clicked +*/ void SummaryQueryWidget::on_m_up_pb_clicked() { auto row = ui->m_choosen_list->currentRow(); @@ -213,8 +213,8 @@ void SummaryQueryWidget::on_m_up_pb_clicked() } /** - * @brief SummaryQueryWidget::on_m_add_pb_clicked - */ + @brief SummaryQueryWidget::on_m_add_pb_clicked +*/ void SummaryQueryWidget::on_m_add_pb_clicked() { if (auto *item = ui->m_available_list->takeItem(ui->m_available_list->currentRow())) { @@ -225,8 +225,8 @@ void SummaryQueryWidget::on_m_add_pb_clicked() } /** - * @brief SummaryQueryWidget::on_m_remove_pb_clicked - */ + @brief SummaryQueryWidget::on_m_remove_pb_clicked +*/ void SummaryQueryWidget::on_m_remove_pb_clicked() { if (auto *item = ui->m_choosen_list->takeItem(ui->m_choosen_list->currentRow())) { @@ -237,8 +237,8 @@ void SummaryQueryWidget::on_m_remove_pb_clicked() } /** - * @brief SummaryQueryWidget::on_m_down_pb_clicked - */ + @brief SummaryQueryWidget::on_m_down_pb_clicked +*/ void SummaryQueryWidget::on_m_down_pb_clicked() { auto row = ui->m_choosen_list->currentRow(); @@ -254,8 +254,8 @@ void SummaryQueryWidget::on_m_down_pb_clicked() } /** - * @brief SummaryQueryWidget::on_m_edit_sql_query_cb_clicked - */ + @brief SummaryQueryWidget::on_m_edit_sql_query_cb_clicked +*/ void SummaryQueryWidget::on_m_edit_sql_query_cb_clicked() { ui->m_user_query_le->setEnabled(ui->m_edit_sql_query_cb->isChecked()); @@ -273,9 +273,9 @@ void SummaryQueryWidget::on_m_edit_sql_query_cb_clicked() } /** - * @brief SummaryQueryWidget::reset - * Clear this widget aka set to initial state - */ + @brief SummaryQueryWidget::reset + Clear this widget aka set to initial state +*/ void SummaryQueryWidget::reset() { //Ugly hack to force to remove all selected infos @@ -286,8 +286,8 @@ void SummaryQueryWidget::reset() } /** - * @brief SummaryQueryWidget::saveConfig - */ + @brief SummaryQueryWidget::saveConfig +*/ void SummaryQueryWidget::saveConfig() { QFile file_(QETApp::configDir() + "/summary.json"); @@ -316,8 +316,8 @@ void SummaryQueryWidget::saveConfig() } /** - * @brief SummaryQueryWidget::loadConfig - */ + @brief SummaryQueryWidget::loadConfig +*/ void SummaryQueryWidget::loadConfig() { auto name = ui->m_config_gb->selectedText(); diff --git a/sources/diagram.cpp b/sources/diagram.cpp index 86e030cd1..e32f2335e 100644 --- a/sources/diagram.cpp +++ b/sources/diagram.cpp @@ -1484,7 +1484,7 @@ bool Diagram::fromXml(QDomElement &document, * @param folioSeq type * @param seq type * @param type of sequential - */ +*/ void Diagram::folioSequentialsFromXml(const QDomElement &root, QHash* hash, @@ -1727,7 +1727,7 @@ void Diagram::updateLabels() * @param sequential to be treated * @param type to be treated * @param Numerotation Context to be manipulated - */ +*/ void Diagram::insertFolioSeqHash(QHash *hash, const QString& title, diff --git a/sources/diagramcontent.cpp b/sources/diagramcontent.cpp index 002f2c6cd..eb9f1a0c8 100644 --- a/sources/diagramcontent.cpp +++ b/sources/diagramcontent.cpp @@ -30,16 +30,16 @@ #include "qetgraphicstableitem.h" /** - * @brief DiagramContent::DiagramContent - */ + @brief DiagramContent::DiagramContent +*/ DiagramContent::DiagramContent() {} /** - * @brief DiagramContent::DiagramContent - * Constructor - * @param diagram : Construct a diagramContent and fill it with the selected item of @diagram - * @param selected : this diagramcontent get only selected items if true. - */ + @brief DiagramContent::DiagramContent + Constructor + @param diagram : Construct a diagramContent and fill it with the selected item of @diagram + @param selected : this diagramcontent get only selected items if true. +*/ DiagramContent::DiagramContent(Diagram *diagram, bool selected) : m_selected_items(diagram->selectedItems()) { @@ -120,12 +120,12 @@ DiagramContent::~DiagramContent() {} /** - * @brief DiagramContent::selectedTexts - * @return a list of every selected texts (every kind of texts) - * Note that the returned list of texts, correspond to the selected texts - * at the moment of the creation of this DiagramContent, - * with the constructor : DiagramContent::DiagramContent(Diagram *diagram) - */ + @brief DiagramContent::selectedTexts + @return a list of every selected texts (every kind of texts) + Note that the returned list of texts, correspond to the selected texts + at the moment of the creation of this DiagramContent, + with the constructor : DiagramContent::DiagramContent(Diagram *diagram) +*/ QList DiagramContent::selectedTexts() const { QList selected_texts; @@ -140,12 +140,12 @@ QList DiagramContent::selectedTexts() const } /** - * @brief DiagramContent::selectedTextsGroup - * @return a list of selected texts group - * Note that the returned list of texts group, correspond to the selected texts group - * at the moment of the creation of this DiagramContent, - * with the constructor : DiagramContent::DiagramContent(Diagram *diagram) - */ + @brief DiagramContent::selectedTextsGroup + @return a list of selected texts group + Note that the returned list of texts group, correspond to the selected texts group + at the moment of the creation of this DiagramContent, + with the constructor : DiagramContent::DiagramContent(Diagram *diagram) +*/ QList DiagramContent::selectedTextsGroup() const { QList groups; @@ -159,10 +159,10 @@ QList DiagramContent::selectedTextsGroup() const } /** - * @brief DiagramContent::conductors - * @param filter - * @return Every conductors according to the filter - */ + @brief DiagramContent::conductors + @param filter + @return Every conductors according to the filter +*/ QList DiagramContent::conductors(int filter) const { QList result; @@ -180,12 +180,12 @@ QList DiagramContent::conductors(int filter) const } /** - * @brief DiagramContent::hasDeletableItems - * @return true if this diagram content have deletable item - * The deletable items correspond to the selected items of diagram - * at the moment of the creation of this DiagramContent, - * with the constructor : DiagramContent::DiagramContent(Diagram *diagram) - */ + @brief DiagramContent::hasDeletableItems + @return true if this diagram content have deletable item + The deletable items correspond to the selected items of diagram + at the moment of the creation of this DiagramContent, + with the constructor : DiagramContent::DiagramContent(Diagram *diagram) +*/ bool DiagramContent::hasDeletableItems() const { for(QGraphicsItem *qgi : m_selected_items) @@ -206,9 +206,9 @@ bool DiagramContent::hasDeletableItems() const } /** - * @brief DiagramContent::hasCopiableItems - * @return true if this diagram content have copiable items. - */ + @brief DiagramContent::hasCopiableItems + @return true if this diagram content have copiable items. +*/ bool DiagramContent::hasCopiableItems() const { if(!m_images.isEmpty()) return true; @@ -220,9 +220,9 @@ bool DiagramContent::hasCopiableItems() const } /** - * @brief DiagramContent::clear - * Remove all items from the diagram content - */ + @brief DiagramContent::clear + Remove all items from the diagram content +*/ void DiagramContent::clear() { m_elements.clear(); @@ -239,10 +239,10 @@ void DiagramContent::clear() } /** - * @brief DiagramContent::removeNonMovableItems - * Remove all non movable item. - * @return : return the numbers of removed item - */ + @brief DiagramContent::removeNonMovableItems + Remove all non movable item. + @return : return the numbers of removed item +*/ int DiagramContent::removeNonMovableItems() { int count_ = 0; @@ -333,10 +333,10 @@ DiagramContent &DiagramContent::operator+=(const DiagramContent &other) } /** - * @brief DiagramContent::potentialIsManaged - * @param conductors a list of conductors at the same potential. - * @return true, if m_potential_conductors already have a conductor of this potential. - */ + @brief DiagramContent::potentialIsManaged + @param conductors a list of conductors at the same potential. + @return true, if m_potential_conductors already have a conductor of this potential. +*/ bool DiagramContent::potentialIsManaged(QList conductors) { bool b = false; @@ -351,9 +351,9 @@ bool DiagramContent::potentialIsManaged(QList conductors) } /** - * @brief DiagramContent::hasTextEditing - * @return true if handle a text currently in editing intercation - */ + @brief DiagramContent::hasTextEditing + @return true if handle a text currently in editing intercation +*/ bool DiagramContent::hasTextEditing() { for (DiagramTextItem *dti : selectedTexts()) { @@ -366,10 +366,10 @@ bool DiagramContent::hasTextEditing() } /** - * @brief DiagramContent::items - * @param filter - * @return The items of this diagram content according to @filter - */ + @brief DiagramContent::items + @param filter + @return The items of this diagram content according to @filter +*/ QList DiagramContent::items(int filter) const { QList items_list; @@ -393,10 +393,10 @@ QList DiagramContent::items(int filter) const } /** - * @brief DiagramContent::count - * @param filter - * @return The number of items, according to @filter - */ + @brief DiagramContent::count + @param filter + @return The number of items, according to @filter +*/ int DiagramContent::count(int filter) const { int count = 0; @@ -428,11 +428,11 @@ int DiagramContent::count(int filter) const } /** - * @brief DiagramContent::sentence - * @param filter - * @return A string that describe the items of the diagram content according to @filter. - * Exemple : X elements, Y conductors etc.... - */ + @brief DiagramContent::sentence + @param filter + @return A string that describe the items of the diagram content according to @filter. + Exemple : X elements, Y conductors etc.... +*/ QString DiagramContent::sentence(int filter) const { int elements_count = (filter & Elements) ? m_elements.count() : 0; @@ -457,11 +457,11 @@ QString DiagramContent::sentence(int filter) const } /** - * @brief operator << Use to debug a diagram content - * @param d : QDebug to use for display the debug info - * @param content : content to debug - * @return - */ + @brief operator << Use to debug a diagram content + @param d : QDebug to use for display the debug info + @param content : content to debug + @return +*/ QDebug &operator<<(QDebug d, DiagramContent &content) { Q_UNUSED(content) d << "DiagramContent {" << "\n"; diff --git a/sources/diagramcontext.cpp b/sources/diagramcontext.cpp index 0afc4e14c..21d2a7fe8 100644 --- a/sources/diagramcontext.cpp +++ b/sources/diagramcontext.cpp @@ -21,13 +21,13 @@ #include /** - * @brief DiagramContext::add - * Add all value of @other to this. - * If a key already exist, the value is replaced. - * If a key doesn't exist, she will be added. - * All other keys of this context, which are not present in @other, stay unchanged. - * @param other - */ + @brief DiagramContext::add + Add all value of @other to this. + If a key already exist, the value is replaced. + If a key doesn't exist, she will be added. + All other keys of this context, which are not present in @other, stay unchanged. + @param other +*/ void DiagramContext::add(DiagramContext other) { for (QString key : other.keys()) { @@ -36,9 +36,9 @@ void DiagramContext::add(DiagramContext other) } /** - * @brief DiagramContext::remove - * @param key - */ + @brief DiagramContext::remove + @param key +*/ void DiagramContext::remove(const QString &key) { m_content.remove(key); } @@ -117,9 +117,9 @@ int DiagramContext::count() { } /** - * @brief DiagramContext::keyMustShow - * @return the value pairs with key, if key no found, return false - */ + @brief DiagramContext::keyMustShow + @return the value pairs with key, if key no found, return false +*/ bool DiagramContext::keyMustShow(const QString &key) const { if (m_content_show.contains(key)) return m_content_show[key]; @@ -163,11 +163,11 @@ void DiagramContext::fromXml(const QDomElement &e, const QString &tag_name) { } /** - * @brief DiagramContext::fromXml - * Read this context properties from the @dom_element, looking for tags named @tag_name - * @param dom_element : dom element to parse - * @param tag_name : tag name to find, by default "property" - */ + @brief DiagramContext::fromXml + Read this context properties from the @dom_element, looking for tags named @tag_name + @param dom_element : dom element to parse + @param tag_name : tag name to find, by default "property" +*/ void DiagramContext::fromXml(const pugi::xml_node &dom_element, const QString &tag_name) { for(auto node = dom_element.child(tag_name.toStdString().c_str()) ; node ; node = node.next_sibling(tag_name.toStdString().c_str())) diff --git a/sources/diagramcontext.h b/sources/diagramcontext.h index 6eeaa1508..f887b0ff6 100644 --- a/sources/diagramcontext.h +++ b/sources/diagramcontext.h @@ -51,7 +51,7 @@ * location -> the location assigned to the element * frozenLabel -> label locked at a given time * - */ +*/ class DiagramContext { public: diff --git a/sources/diagramevent/diagrameventaddelement.cpp b/sources/diagramevent/diagrameventaddelement.cpp index f7417429f..eff821ce7 100644 --- a/sources/diagramevent/diagrameventaddelement.cpp +++ b/sources/diagramevent/diagrameventaddelement.cpp @@ -24,12 +24,12 @@ /** - * @brief DiagramEventAddElement::DiagramEventAddElement - * Defaut constructor - * @param location :location of diagram - * @param diagram : diagram owner of this event - * @param pos : first pos of item ( optional, by defaut QPointF(0,0) ) - */ + @brief DiagramEventAddElement::DiagramEventAddElement + Defaut constructor + @param location :location of diagram + @param diagram : diagram owner of this event + @param pos : first pos of item ( optional, by defaut QPointF(0,0) ) +*/ DiagramEventAddElement::DiagramEventAddElement(ElementsLocation &location, Diagram *diagram, QPointF pos) : DiagramEventInterface(diagram), m_location(location), @@ -53,10 +53,10 @@ DiagramEventAddElement::DiagramEventAddElement(ElementsLocation &location, Diagr } /** - * @brief DiagramEventAddElement::~DiagramEventAddElement - * Destructor - * Enable context menu for each view of diagram - */ + @brief DiagramEventAddElement::~DiagramEventAddElement + Destructor + Enable context menu for each view of diagram +*/ DiagramEventAddElement::~DiagramEventAddElement() { if (m_element) @@ -69,11 +69,11 @@ DiagramEventAddElement::~DiagramEventAddElement() } /** - * @brief DiagramEventAddElement::mouseMoveEvent - * Move the element to new pos of mouse - * the event is always accepted - * @param event - */ + @brief DiagramEventAddElement::mouseMoveEvent + Move the element to new pos of mouse + the event is always accepted + @param event +*/ void DiagramEventAddElement::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if (m_element) { @@ -83,22 +83,22 @@ void DiagramEventAddElement::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddElement::mousePressEvent - * Do nothing, but return true for not transit the event to other thing in diagram. - * the event is always accepted - * @param event - */ + @brief DiagramEventAddElement::mousePressEvent + Do nothing, but return true for not transit the event to other thing in diagram. + the event is always accepted + @param event +*/ void DiagramEventAddElement::mousePressEvent(QGraphicsSceneMouseEvent *event) { event->setAccepted(true); } /** - * @brief DiagramEventAddElement::mouseReleaseEvent - * Right button finish this event (isRunning = false) and emit finish. - * Left button add an element to diagram - * the event is always accepted - * @param event - */ + @brief DiagramEventAddElement::mouseReleaseEvent + Right button finish this event (isRunning = false) and emit finish. + Left button add an element to diagram + the event is always accepted + @param event +*/ void DiagramEventAddElement::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (m_element) @@ -121,11 +121,11 @@ void DiagramEventAddElement::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddElement::mouseDoubleClickEvent - * If mouse left double clic, finish this event (isRunning = false) and emit finish - * the event is always accepted - * @param event - */ + @brief DiagramEventAddElement::mouseDoubleClickEvent + If mouse left double clic, finish this event (isRunning = false) and emit finish + the event is always accepted + @param event +*/ void DiagramEventAddElement::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { if (m_element && (event -> button() == Qt::LeftButton)) @@ -141,11 +141,11 @@ void DiagramEventAddElement::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *eve } /** - * @brief DiagramEventAddElement::keyPressEvent - * Press space key rotate the element to 90° (return true) - * else call DiagramEventInterface::keyPressEvent(event), and return the value. - * @param event - */ + @brief DiagramEventAddElement::keyPressEvent + Press space key rotate the element to 90° (return true) + else call DiagramEventInterface::keyPressEvent(event), and return the value. + @param event +*/ void DiagramEventAddElement::keyPressEvent(QKeyEvent *event) { if (m_element && event->key() == Qt::Key_Space) @@ -159,9 +159,9 @@ void DiagramEventAddElement::keyPressEvent(QKeyEvent *event) } /** - * @brief DiagramEventAddElement::init - * Init this event. - */ + @brief DiagramEventAddElement::init + Init this event. +*/ void DiagramEventAddElement::init() { foreach(QGraphicsView *view, m_diagram->views()) @@ -169,9 +169,9 @@ void DiagramEventAddElement::init() } /** - * @brief DiagramEventAddElement::buildElement - * Build the element, if the element is build successfully, we return true, otherwise false - */ + @brief DiagramEventAddElement::buildElement + Build the element, if the element is build successfully, we return true, otherwise false +*/ bool DiagramEventAddElement::buildElement() { ElementsLocation import_loc = m_diagram->project()->importElement(m_location); @@ -196,10 +196,10 @@ bool DiagramEventAddElement::buildElement() } /** - * @brief DiagramEventAddElement::addElement - * Add an element at the current pos en current rotation, - * if project autoconductor option is enable, and the element can be wired, we do it. - */ + @brief DiagramEventAddElement::addElement + Add an element at the current pos en current rotation, + if project autoconductor option is enable, and the element can be wired, we do it. +*/ void DiagramEventAddElement::addElement() { int state; diff --git a/sources/diagramevent/diagrameventaddelement.h b/sources/diagramevent/diagrameventaddelement.h index a23cbf33a..f06387792 100644 --- a/sources/diagramevent/diagrameventaddelement.h +++ b/sources/diagramevent/diagrameventaddelement.h @@ -24,10 +24,10 @@ class Element; /** - * @brief The DiagramEventAddElement class - * This diagram event add a new element, for each left click button at the position of click. - * Space key rotate current element by 90°, right click button finish this event. - */ + @brief The DiagramEventAddElement class + This diagram event add a new element, for each left click button at the position of click. + Space key rotate current element by 90°, right click button finish this event. +*/ class DiagramEventAddElement : public DiagramEventInterface { Q_OBJECT diff --git a/sources/diagramevent/diagrameventaddimage.cpp b/sources/diagramevent/diagrameventaddimage.cpp index f6b99d831..ac61233d5 100644 --- a/sources/diagramevent/diagrameventaddimage.cpp +++ b/sources/diagramevent/diagrameventaddimage.cpp @@ -22,10 +22,10 @@ #include "diagramcommands.h" /** - * @brief DiagramEventAddImage::DiagramEventAddImage - * Default constructor - * @param diagram : diagram where operate this event - */ + @brief DiagramEventAddImage::DiagramEventAddImage + Default constructor + @param diagram : diagram where operate this event +*/ DiagramEventAddImage::DiagramEventAddImage(Diagram *diagram) : DiagramEventInterface(diagram), m_image (nullptr), @@ -35,8 +35,8 @@ DiagramEventAddImage::DiagramEventAddImage(Diagram *diagram) : } /** - * @brief DiagramEventAddImage::~DiagramEventAddImage - */ + @brief DiagramEventAddImage::~DiagramEventAddImage +*/ DiagramEventAddImage::~DiagramEventAddImage() { if (m_running || m_abort) @@ -50,10 +50,10 @@ DiagramEventAddImage::~DiagramEventAddImage() } /** - * @brief DiagramEventAddImage::mousePressEvent - * Action when mouse is pressed - * @param event : event of mouse pressed - */ + @brief DiagramEventAddImage::mousePressEvent + Action when mouse is pressed + @param event : event of mouse pressed +*/ void DiagramEventAddImage::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (m_image && event -> button() == Qt::LeftButton) @@ -79,10 +79,10 @@ void DiagramEventAddImage::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddImage::mouseMoveEvent - * Action when mouse move - * @param event : event of mouse move - */ + @brief DiagramEventAddImage::mouseMoveEvent + Action when mouse move + @param event : event of mouse move +*/ void DiagramEventAddImage::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if (!m_image || event->buttons() != Qt::NoButton) { @@ -106,20 +106,20 @@ void DiagramEventAddImage::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddImage::mouseDoubleClickEvent - * This method is only use to overwrite double click. - * When double click, image propertie dialog isn't open. - * @param event : event of mouse double click. - */ + @brief DiagramEventAddImage::mouseDoubleClickEvent + This method is only use to overwrite double click. + When double click, image propertie dialog isn't open. + @param event : event of mouse double click. +*/ void DiagramEventAddImage::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { event->setAccepted(true); } /** - * @brief DiagramEventAddImage::wheelEvent - * Action when mouse wheel is rotate - * @param event: evet of mouse wheel - */ + @brief DiagramEventAddImage::wheelEvent + Action when mouse wheel is rotate + @param event: evet of mouse wheel +*/ void DiagramEventAddImage::wheelEvent(QGraphicsSceneWheelEvent *event) { if (!m_is_added || !m_image || event -> modifiers() != Qt::CTRL) { @@ -136,9 +136,9 @@ void DiagramEventAddImage::wheelEvent(QGraphicsSceneWheelEvent *event) } /** - * @brief DiagramEventAddImage::isNull - * @return : true if image can't be loaded, otherwise return false. - */ + @brief DiagramEventAddImage::isNull + @return : true if image can't be loaded, otherwise return false. +*/ bool DiagramEventAddImage::isNull() const { if (!m_image) return true; @@ -146,9 +146,9 @@ bool DiagramEventAddImage::isNull() const } /** - * @brief DiagramEventAddImage::openDialog - * Open dialog for select the image to add. - */ + @brief DiagramEventAddImage::openDialog + Open dialog for select the image to add. +*/ void DiagramEventAddImage::openDialog() { if (m_diagram -> isReadOnly()) return; diff --git a/sources/diagramevent/diagrameventaddimage.h b/sources/diagramevent/diagrameventaddimage.h index 9f23e7250..d6d3ca504 100644 --- a/sources/diagramevent/diagrameventaddimage.h +++ b/sources/diagramevent/diagrameventaddimage.h @@ -24,9 +24,9 @@ class Diagram; class DiagramImageItem; /** - * @brief The DiagramEventAddImage class - * This diagram event, handle the adding of an image in a diagram. - */ + @brief The DiagramEventAddImage class + This diagram event, handle the adding of an image in a diagram. +*/ class DiagramEventAddImage : public DiagramEventInterface { Q_OBJECT diff --git a/sources/diagramevent/diagrameventaddshape.cpp b/sources/diagramevent/diagrameventaddshape.cpp index 1256094f5..be9d69f34 100644 --- a/sources/diagramevent/diagrameventaddshape.cpp +++ b/sources/diagramevent/diagrameventaddshape.cpp @@ -20,11 +20,11 @@ #include "diagramcommands.h" /** - * @brief DiagramEventAddShape::DiagramEventAddShape - * Default constructor - * @param diagram : the diagram where this event must operate - * @param shape_type : the type of shape to draw - */ + @brief DiagramEventAddShape::DiagramEventAddShape + Default constructor + @param diagram : the diagram where this event must operate + @param shape_type : the type of shape to draw +*/ DiagramEventAddShape::DiagramEventAddShape(Diagram *diagram, QetShapeItem::ShapeType shape_type) : DiagramEventInterface(diagram), m_shape_type (shape_type), @@ -37,8 +37,8 @@ DiagramEventAddShape::DiagramEventAddShape(Diagram *diagram, QetShapeItem::Shape } /** - * @brief DiagramEventAddShape::~DiagramEventAddShape - */ + @brief DiagramEventAddShape::~DiagramEventAddShape +*/ DiagramEventAddShape::~DiagramEventAddShape() { if ((m_running || m_abort) && m_shape_item) @@ -54,10 +54,10 @@ DiagramEventAddShape::~DiagramEventAddShape() } /** - * @brief DiagramEventAddShape::mousePressEvent - * Action when mouse is pressed - * @param event : event of mouse press - */ + @brief DiagramEventAddShape::mousePressEvent + Action when mouse is pressed + @param event : event of mouse press +*/ void DiagramEventAddShape::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (Q_UNLIKELY(m_diagram->isReadOnly())) { @@ -107,10 +107,10 @@ void DiagramEventAddShape::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddShape::mouseMoveEvent - * Action when mouse move - * @param event : event of mouse move - */ + @brief DiagramEventAddShape::mouseMoveEvent + Action when mouse move + @param event : event of mouse move +*/ void DiagramEventAddShape::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross(event->scenePos()); @@ -128,10 +128,10 @@ void DiagramEventAddShape::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddShape::mouseReleaseEvent - * Action when mouse button is released - * @param event : event of mouse release - */ + @brief DiagramEventAddShape::mouseReleaseEvent + Action when mouse button is released + @param event : event of mouse release +*/ void DiagramEventAddShape::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::RightButton) @@ -170,10 +170,10 @@ void DiagramEventAddShape::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramEventAddShape::mouseDoubleClickEvent - * Action when mouse button is double clicked - * @param event : event of mouse double click - */ + @brief DiagramEventAddShape::mouseDoubleClickEvent + Action when mouse button is double clicked + @param event : event of mouse double click +*/ void DiagramEventAddShape::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { //If current item is a polyline, add it with an undo command @@ -204,10 +204,10 @@ void DiagramEventAddShape::init() } /** - * @brief DiagramEventAddShape::updateHelpCross - * Create and update the position of the cross to help user for draw new shape - * @param p : the center of the cross - */ + @brief DiagramEventAddShape::updateHelpCross + Create and update the position of the cross to help user for draw new shape + @param p : the center of the cross +*/ void DiagramEventAddShape::updateHelpCross(const QPointF &p) { //If line isn't created yet, we create it. diff --git a/sources/diagramevent/diagrameventaddshape.h b/sources/diagramevent/diagrameventaddshape.h index cc43eff6c..a079a5909 100644 --- a/sources/diagramevent/diagrameventaddshape.h +++ b/sources/diagramevent/diagrameventaddshape.h @@ -22,9 +22,9 @@ #include "qetshapeitem.h" /** - * @brief The DiagramEventAddShape class - * This event manage the creation of a shape. - */ + @brief The DiagramEventAddShape class + This event manage the creation of a shape. +*/ class DiagramEventAddShape : public DiagramEventInterface { Q_OBJECT diff --git a/sources/diagramevent/diagrameventaddtext.cpp b/sources/diagramevent/diagrameventaddtext.cpp index e18414f8e..dd7e1fd7f 100644 --- a/sources/diagramevent/diagrameventaddtext.cpp +++ b/sources/diagramevent/diagrameventaddtext.cpp @@ -22,24 +22,24 @@ #include "diagram.h" /** - * @brief DiagramEventAddText::DiagramEventAddText - * Default constructor - * @param diagram : the diagram where this event must operate - */ + @brief DiagramEventAddText::DiagramEventAddText + Default constructor + @param diagram : the diagram where this event must operate +*/ DiagramEventAddText::DiagramEventAddText(Diagram *diagram) : DiagramEventInterface(diagram) {} /** - * @brief DiagramEventAddText::~DiagramEventAddText - */ + @brief DiagramEventAddText::~DiagramEventAddText +*/ DiagramEventAddText::~DiagramEventAddText() {} /** - * @brief DiagramEventAddText::mousePressEvent - * @param event : event of mouse press event. - */ + @brief DiagramEventAddText::mousePressEvent + @param event : event of mouse press event. +*/ void DiagramEventAddText::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton) diff --git a/sources/diagramevent/diagrameventaddtext.h b/sources/diagramevent/diagrameventaddtext.h index f84ba44df..8f44d6bd1 100644 --- a/sources/diagramevent/diagrameventaddtext.h +++ b/sources/diagramevent/diagrameventaddtext.h @@ -23,9 +23,9 @@ class Diagram; /** - * @brief The DiagramEventAddText class - * This diagram event handle the creation of a new text in a diagram - */ + @brief The DiagramEventAddText class + This diagram event handle the creation of a new text in a diagram +*/ class DiagramEventAddText : public DiagramEventInterface { Q_OBJECT diff --git a/sources/diagramevent/diagrameventinterface.cpp b/sources/diagramevent/diagrameventinterface.cpp index 4915e36a7..c8dcb4844 100644 --- a/sources/diagramevent/diagrameventinterface.cpp +++ b/sources/diagramevent/diagrameventinterface.cpp @@ -52,10 +52,10 @@ void DiagramEventInterface::wheelEvent(QGraphicsSceneWheelEvent *event) { } /** - * @brief DiagramEventInterface::keyPressEvent - * By default, press escape key abort the curent action - * @param event - */ + @brief DiagramEventInterface::keyPressEvent + By default, press escape key abort the curent action + @param event +*/ void DiagramEventInterface::keyPressEvent(QKeyEvent *event) { if (event->key() == Qt::Key_Escape) diff --git a/sources/diagramevent/diagrameventinterface.h b/sources/diagramevent/diagrameventinterface.h index 4150291a0..28dc638fd 100644 --- a/sources/diagramevent/diagrameventinterface.h +++ b/sources/diagramevent/diagrameventinterface.h @@ -26,22 +26,22 @@ class QKeyEvent; class Diagram; /** - * @brief The DiagramEventInterface class - * isRunning() return true if action is running (do something). By default return false. + @brief The DiagramEventInterface class + isRunning() return true if action is running (do something). By default return false. * - * ##USE DiagramEventInterface## - * This class is the basic interface for manage event on a diagram. - * To create a behavior for event diagram, we need to herite this class. - * This interface work like this : - * You need to create an interface and call diagram::setEventInterface(pointer_of_your_interface). - * When a diagram get an event (mouse or key) if they have an event interface, - * they send the event (with the status accepted to false) to the interface (for exemple mousePressEvent). - * If the interface do something with this event, you need to set to true the accepted status of the event, then diagram do nothing. - * When the interface job is done, we need to emit the signal finish(), the diagram use this signal to delete the interface. - * Be carreful with the destructor, diagram can at any time (even if interface is still running) delete the interface, - * the bool m_abort is here for that at destruction time. + ##USE DiagramEventInterface## + This class is the basic interface for manage event on a diagram. + To create a behavior for event diagram, we need to herite this class. + This interface work like this : + You need to create an interface and call diagram::setEventInterface(pointer_of_your_interface). + When a diagram get an event (mouse or key) if they have an event interface, + they send the event (with the status accepted to false) to the interface (for exemple mousePressEvent). + If the interface do something with this event, you need to set to true the accepted status of the event, then diagram do nothing. + When the interface job is done, we need to emit the signal finish(), the diagram use this signal to delete the interface. + Be carreful with the destructor, diagram can at any time (even if interface is still running) delete the interface, + the bool m_abort is here for that at destruction time. * - */ +*/ class DiagramEventInterface : public QObject { Q_OBJECT diff --git a/sources/diagramview.cpp b/sources/diagramview.cpp index 8b22dbbed..34a18c771 100644 --- a/sources/diagramview.cpp +++ b/sources/diagramview.cpp @@ -198,10 +198,10 @@ void DiagramView::handleElementDrop(QDropEvent *event) } /** - * @brief DiagramView::handleTitleBlockDrop - * Handle the dropEvent that contain data of a titleblock - * @param e - */ + @brief DiagramView::handleTitleBlockDrop + Handle the dropEvent that contain data of a titleblock + @param e +*/ void DiagramView::handleTitleBlockDrop(QDropEvent *e) { // fetch the title block template location from the drop event TitleBlockTemplateLocation tbt_loc; @@ -247,10 +247,10 @@ void DiagramView::handleTitleBlockDrop(QDropEvent *e) { } /** - * @brief DiagramView::handleTextDrop + @brief DiagramView::handleTextDrop *handle the drop of text - * @param e the QDropEvent describing the current drag'n drop - */ + @param e the QDropEvent describing the current drag'n drop +*/ void DiagramView::handleTextDrop(QDropEvent *e) { if (m_diagram -> isReadOnly() || (e -> mimeData() -> hasText() == false) ) return; @@ -284,12 +284,12 @@ void DiagramView::setSelectionMode() { } /** - * @brief DiagramView::zoom - * Zomm the view. - * A zoom_factor > 1 zoom in. - * A zoom_factor < 1 zoom out - * @param zoom_factor - */ + @brief DiagramView::zoom + Zomm the view. + A zoom_factor > 1 zoom in. + A zoom_factor < 1 zoom out + @param zoom_factor +*/ void DiagramView::zoom(const qreal zoom_factor) { if (zoom_factor >= 1){ @@ -357,11 +357,11 @@ void DiagramView::copy() { } /** - * @brief DiagramView::paste - * Import the element stored in the clipboard to the diagram. - * @param pos : top left corner of the bounding rect of imported elements - * @param clipboard_mode - */ + @brief DiagramView::paste + Import the element stored in the clipboard to the diagram. + @param pos : top left corner of the bounding rect of imported elements + @param clipboard_mode +*/ void DiagramView::paste(const QPointF &pos, QClipboard::Mode clipboard_mode) { if (!isInteractive() || m_diagram -> isReadOnly()) return; @@ -448,9 +448,9 @@ void DiagramView::mousePressEvent(QMouseEvent *e) } /** - * @brief DiagramView::mouseMoveEvent - * Manage the event move mouse - */ + @brief DiagramView::mouseMoveEvent + Manage the event move mouse +*/ void DiagramView::mouseMoveEvent(QMouseEvent *e) { if (m_event_interface && m_event_interface->mouseMoveEvent(e)) return; @@ -509,9 +509,9 @@ void DiagramView::mouseMoveEvent(QMouseEvent *e) } /** - * @brief DiagramView::mouseReleaseEvent - * Manage event release click mouse - */ + @brief DiagramView::mouseReleaseEvent + Manage event release click mouse +*/ void DiagramView::mouseReleaseEvent(QMouseEvent *e) { if (m_event_interface && m_event_interface->mouseReleaseEvent(e)) return; @@ -563,9 +563,9 @@ void DiagramView::mouseReleaseEvent(QMouseEvent *e) } /** - * @brief DiagramView::gestures - * @return - */ + @brief DiagramView::gestures + @return +*/ bool DiagramView::gestures() const { QSettings settings; @@ -606,11 +606,11 @@ void DiagramView::wheelEvent(QWheelEvent *event) } /** - * @brief DiagramView::gestureEvent - * Use the pinch of the trackpad for zoom - * @param event - * @return - */ + @brief DiagramView::gestureEvent + Use the pinch of the trackpad for zoom + @param event + @return +*/ bool DiagramView::gestureEvent(QGestureEvent *event) { if (QGesture *gesture = event->gesture(Qt::PinchGesture)) @@ -639,11 +639,11 @@ void DiagramView::focusInEvent(QFocusEvent *e) { } /** - * @brief DiagramView::keyPressEvent - * Handles "key press" events. Reimplemented here to switch to visualisation - * mode if needed. - * @param e - */ + @brief DiagramView::keyPressEvent + Handles "key press" events. Reimplemented here to switch to visualisation + mode if needed. + @param e +*/ void DiagramView::keyPressEvent(QKeyEvent *e) { if (m_event_interface && m_event_interface->keyPressEvent(e)) @@ -821,17 +821,17 @@ QString DiagramView::title() const { } /** - * @brief DiagramView::editDiagramProperties - * Edit the properties of the viewed digram - */ + @brief DiagramView::editDiagramProperties + Edit the properties of the viewed digram +*/ void DiagramView::editDiagramProperties() { DiagramPropertiesDialog::diagramPropertiesDialog(m_diagram, diagramEditor()); } /** - * @brief DiagramView::adjustSceneRect - * Calcul and set the area of the scene visualized by this view - */ + @brief DiagramView::adjustSceneRect + Calcul and set the area of the scene visualized by this view +*/ void DiagramView::adjustSceneRect() { QRectF scene_rect = m_diagram->sceneRect(); @@ -912,9 +912,9 @@ void DiagramView::applyReadOnly() { } /** - * @brief DiagramView::editSelectedConductorColor - * Edit the color of the selected conductor; does nothing if multiple conductors are selected - */ + @brief DiagramView::editSelectedConductorColor + Edit the color of the selected conductor; does nothing if multiple conductors are selected +*/ void DiagramView::editSelectedConductorColor() { //retrieve selected content @@ -996,14 +996,14 @@ void DiagramView::resetConductors() { @param e Evenement */ /** - * @brief DiagramView::event - * Manage the event on this diagram view. - * -At first activation (QEvent::WindowActivate or QEvent::Show) we zoomFit. - * -Convert event interpreted to mouse event to gesture event if needed. - * -send Shortcut to view (by default send to QMenu /QAction) - * @param e the event. - * @return - */ + @brief DiagramView::event + Manage the event on this diagram view. + -At first activation (QEvent::WindowActivate or QEvent::Show) we zoomFit. + -Convert event interpreted to mouse event to gesture event if needed. + -send Shortcut to view (by default send to QMenu /QAction) + @param e the event. + @return +*/ bool DiagramView::event(QEvent *e) { if (Q_UNLIKELY(m_first_activation)) { if (e -> type() == QEvent::Show) { @@ -1031,10 +1031,10 @@ bool DiagramView::event(QEvent *e) { } /** - * @brief DiagramView::paintEvent - * Reimplemented from QGraphicsView - * @param event - */ + @brief DiagramView::paintEvent + Reimplemented from QGraphicsView + @param event +*/ void DiagramView::paintEvent(QPaintEvent *event) { QGraphicsView::paintEvent(event); @@ -1113,9 +1113,9 @@ bool DiagramView::selectedItemHasFocus() { } /** - * @brief DiagramView::editSelection - * Edit the selected item if he can be edited and if only one item is selected - */ + @brief DiagramView::editSelection + Edit the selected item if he can be edited and if only one item is selected +*/ void DiagramView::editSelection() { if (m_diagram -> isReadOnly() || m_diagram -> selectedItems().size() != 1 ) return; @@ -1133,11 +1133,11 @@ void DiagramView::editSelection() { } /** - * @brief DiagramView::setEventInterface - * Set an event interface to diagram view. - * If diagram view already have an event interface, he delete it before. - * Diagram view take ownership of event interface and delete it when event interface is finish - */ + @brief DiagramView::setEventInterface + Set an event interface to diagram view. + If diagram view already have an event interface, he delete it before. + Diagram view take ownership of event interface and delete it when event interface is finish +*/ void DiagramView::setEventInterface(DVEventInterface *event_interface) { if (m_event_interface) delete m_event_interface; @@ -1146,10 +1146,10 @@ void DiagramView::setEventInterface(DVEventInterface *event_interface) } /** - * @brief DiagramView::contextMenuActions - * @return a list of actions currently available for a context menu. - * - */ + @brief DiagramView::contextMenuActions + @return a list of actions currently available for a context menu. + +*/ QList DiagramView::contextMenuActions() const { QList list; @@ -1189,9 +1189,9 @@ QList DiagramView::contextMenuActions() const } /** - * @brief DiagramView::contextMenuEvent - * @param e - */ + @brief DiagramView::contextMenuEvent + @param e +*/ void DiagramView::contextMenuEvent(QContextMenuEvent *e) { QGraphicsView::contextMenuEvent(e); @@ -1237,9 +1237,9 @@ QETDiagramEditor *DiagramView::diagramEditor() const { } /** - * @brief DiagramView::mouseDoubleClickEvent - * @param e - */ + @brief DiagramView::mouseDoubleClickEvent + @param e +*/ void DiagramView::mouseDoubleClickEvent(QMouseEvent *e) { if (m_event_interface && m_event_interface -> mouseDoubleClickEvent(e)) return; diff --git a/sources/dvevent/dveventinterface.cpp b/sources/dvevent/dveventinterface.cpp index 4d5a84e57..d436db1f5 100644 --- a/sources/dvevent/dveventinterface.cpp +++ b/sources/dvevent/dveventinterface.cpp @@ -57,12 +57,12 @@ bool DVEventInterface::wheelEvent(QWheelEvent *event) { } /** - * @brief DVEventInterface::keyPressEvent - * By default, press escape key abort the curent action. - * isFinish return true, and emit finish - * @param event - * @return - */ + @brief DVEventInterface::keyPressEvent + By default, press escape key abort the curent action. + isFinish return true, and emit finish + @param event + @return +*/ bool DVEventInterface::keyPressEvent(QKeyEvent *event) { if (event->key() == Qt::Key_Escape) diff --git a/sources/dvevent/dveventinterface.h b/sources/dvevent/dveventinterface.h index 7685b120f..2322f004b 100644 --- a/sources/dvevent/dveventinterface.h +++ b/sources/dvevent/dveventinterface.h @@ -27,14 +27,18 @@ class DiagramView; class Diagram; /** - * @brief The DVEventInterface class - * This class is the main interface for manage event of a Diagram View. - * This do nothing, for create new event behavior, we must to create new class from this. - * Each method return a bool: True if the methode do something else return false. - * Each method of DVEventInterface return false; - * isRunning() return true if action is started but not finish. By default return false. - * isFinish() return true when the action is finish, or not started. By default return true. - */ + @brief The DVEventInterface class + This class is the main interface for manage event of a Diagram View. + This do nothing, for create new event behavior, + we must to create new class from this. + Each method return a bool: + True if the methode do something else return false. + Each method of DVEventInterface return false; + isRunning() return true if action is started but not finish. + By default return false. + isFinish() return true when the action is finish, or not started. + By default return true. +*/ class DVEventInterface : public QObject { Q_OBJECT @@ -54,8 +58,8 @@ class DVEventInterface : public QObject signals: /** - * @brief finish - * emited when the interface finish is work + @brief finish + emited when the interface finish is work */ void finish(); diff --git a/sources/editor/UndoCommand/pastepartscommand.cpp b/sources/editor/UndoCommand/pastepartscommand.cpp index a72cfe8c7..3b53ec7f1 100644 --- a/sources/editor/UndoCommand/pastepartscommand.cpp +++ b/sources/editor/UndoCommand/pastepartscommand.cpp @@ -20,14 +20,14 @@ #include "partterminal.h" /** - * @brief PastePartsCommand::PastePartsCommand - * @param view : view where this command work - * @param content_to_paste : content to paste - * @param parent : parent undo command + @brief PastePartsCommand::PastePartsCommand + @param view : view where this command work + @param content_to_paste : content to paste + @param parent : parent undo command * - * Note : all terminal stored in @content_to_paste get a new uuid in the constructor of this class to avoid have - * several terminal of an element with the same uuid. - */ + Note : all terminal stored in @content_to_paste get a new uuid in the constructor of this class to avoid have + several terminal of an element with the same uuid. +*/ PastePartsCommand::PastePartsCommand(ElementView *view, const ElementContent &content_to_paste, QUndoCommand *parent) : ElementEditionCommand(view ? view -> scene() : nullptr, view, parent) { @@ -44,16 +44,16 @@ PastePartsCommand::PastePartsCommand(ElementView *view, const ElementContent &co } /** - * @brief PastePartsCommand::~PastePartsCommand - */ + @brief PastePartsCommand::~PastePartsCommand +*/ PastePartsCommand::~PastePartsCommand() { m_scene->qgiManager().release(m_pasted_content); } /** - * @brief PastePartsCommand::undo - */ + @brief PastePartsCommand::undo +*/ void PastePartsCommand::undo() { m_scene->blockSignals(true); @@ -72,8 +72,8 @@ void PastePartsCommand::undo() } /** - * @brief PastePartsCommand::redo - */ + @brief PastePartsCommand::redo +*/ void PastePartsCommand::redo() { if (m_first_redo) { @@ -97,13 +97,13 @@ void PastePartsCommand::redo() } /** - * @brief PastePartsCommand::setOffset - * Describe the offset to use with this undo command - * @param old_offset_paste_count - * @param old_start_top_left_corner - * @param new_offset_paste_count - * @param new_start_top_left_corner - */ + @brief PastePartsCommand::setOffset + Describe the offset to use with this undo command + @param old_offset_paste_count + @param old_start_top_left_corner + @param new_offset_paste_count + @param new_start_top_left_corner +*/ void PastePartsCommand::setOffset(int old_offset_paste_count, const QPointF &old_start_top_left_corner, int new_offset_paste_count, const QPointF &new_start_top_left_corner) { m_old_offset_paste_count = old_offset_paste_count; diff --git a/sources/editor/UndoCommand/pastepartscommand.h b/sources/editor/UndoCommand/pastepartscommand.h index eac997eee..34841f6d1 100644 --- a/sources/editor/UndoCommand/pastepartscommand.h +++ b/sources/editor/UndoCommand/pastepartscommand.h @@ -24,9 +24,9 @@ class ElementView; /** - * @brief The PastePartsCommand class - * Undo command for paste element primitive in an element editor - */ + @brief The PastePartsCommand class + Undo command for paste element primitive in an element editor +*/ class PastePartsCommand : public ElementEditionCommand { public: diff --git a/sources/editor/arceditor.cpp b/sources/editor/arceditor.cpp index 4c9a73fbb..87cbcb5dd 100644 --- a/sources/editor/arceditor.cpp +++ b/sources/editor/arceditor.cpp @@ -95,12 +95,12 @@ void ArcEditor::disconnectChangeConnections() } /** - * @brief ArcEditor::setPart - * Specifie to this editor the part to edit. - * Note that an editor can accept or refuse to edit a part. This editor accept only partArc. - * @param new_part - * @return - */ + @brief ArcEditor::setPart + Specifie to this editor the part to edit. + Note that an editor can accept or refuse to edit a part. This editor accept only partArc. + @param new_part + @return +*/ bool ArcEditor::setPart(CustomElementPart *new_part) { if (!new_part) @@ -137,9 +137,9 @@ bool ArcEditor::setParts(QList parts) } /** - * @brief ArcEditor::currentPart - * @return the curent edited part, or 0 if there is no edited part - */ + @brief ArcEditor::currentPart + @return the curent edited part, or 0 if there is no edited part +*/ CustomElementPart *ArcEditor::currentPart() const { return(part); } @@ -149,9 +149,9 @@ QList ArcEditor::currentParts() const { } /** - * @brief ArcEditor::updateArcS - * Update the start angle of the arc according to the edited value. - */ + @brief ArcEditor::updateArcS + Update the start angle of the arc according to the edited value. +*/ void ArcEditor::updateArcS() { if (m_locked) return; @@ -175,9 +175,9 @@ void ArcEditor::updateArcS() } /** - * @brief ArcEditor::updateArcA - * Update the span angle of the arc according to the edited value. - */ + @brief ArcEditor::updateArcA + Update the span angle of the arc according to the edited value. +*/ void ArcEditor::updateArcA() { if (m_locked) return; @@ -200,9 +200,9 @@ void ArcEditor::updateArcA() } /** - * @brief ArcEditor::updateArcRect - * Update the geometrie of the rect that define this arc according the the edited values - */ + @brief ArcEditor::updateArcRect + Update the geometrie of the rect that define this arc according the the edited values +*/ void ArcEditor::updateArcRectX() { if (m_locked) return; @@ -300,9 +300,9 @@ void ArcEditor::updateArcRectV() } /** - * @brief ArcEditor::updateForm - * Update the value of the widgets - */ + @brief ArcEditor::updateForm + Update the value of the widgets +*/ void ArcEditor::updateForm() { if (!part) return; @@ -318,11 +318,11 @@ void ArcEditor::updateForm() } /** - * @brief ArcEditor::activeConnections - * Enable/disable connection between editor widget and slot editingFinished - * True == enable | false == disable - * @param active - */ + @brief ArcEditor::activeConnections + Enable/disable connection between editor widget and slot editingFinished + True == enable | false == disable + @param active +*/ void ArcEditor::activeConnections(bool active) { if (active) diff --git a/sources/editor/arceditor.h b/sources/editor/arceditor.h index aaa79efe2..b5b8d38fc 100644 --- a/sources/editor/arceditor.h +++ b/sources/editor/arceditor.h @@ -67,10 +67,11 @@ class ArcEditor : public ElementItemEditor private: void activeConnections(bool); - /*! - * \brief setUpChangeConnections - * Setup the connection from the arc(s) to the widget, to update it when the arc(s) are changed (moved ...) - */ + /** + @brief setUpChangeConnections + Setup the connection from the arc(s) to the widget, + to update it when the arc(s) are changed (moved ...) + */ void setUpChangeConnections(); void disconnectChangeConnections(); }; diff --git a/sources/editor/editorcommands.cpp b/sources/editor/editorcommands.cpp index 7c4526b79..92dd0a4b4 100644 --- a/sources/editor/editorcommands.cpp +++ b/sources/editor/editorcommands.cpp @@ -523,13 +523,13 @@ void ScalePartsCommand::adjustText() { } } /** - * @brief ChangePropertiesCommand::ChangePropertiesCommand - * Change the properties of the drawed element - * @param scene: scene to belong the property - * @param type: new type of element. - * @param context: new info about type. - * @param parent: parent undo - */ + @brief ChangePropertiesCommand::ChangePropertiesCommand + Change the properties of the drawed element + @param scene: scene to belong the property + @param type: new type of element. + @param context: new info about type. + @param parent: parent undo +*/ ChangePropertiesCommand::ChangePropertiesCommand(ElementScene *scene, const QString& type, const DiagramContext& info, const DiagramContext& elmt_info, QUndoCommand *parent) : ElementEditionCommand(scene, nullptr, parent) { diff --git a/sources/editor/editorcommands.h b/sources/editor/editorcommands.h index d6174ffbf..07ec7a4c2 100644 --- a/sources/editor/editorcommands.h +++ b/sources/editor/editorcommands.h @@ -24,11 +24,11 @@ #include "qgimanager.h" /** - * @brief The ElementEditionCommand class - * ElementEditionCommand is the base class for all commands classes involved in + @brief The ElementEditionCommand class + ElementEditionCommand is the base class for all commands classes involved in the edition of an electrical element. It provides commonly required methods and attributes, such as accessors to the modified scene and view. - */ +*/ class ElementEditionCommand : public QUndoCommand { // constructors, destructor diff --git a/sources/editor/elementprimitivedecorator.cpp b/sources/editor/elementprimitivedecorator.cpp index 612d42ea2..f7c90baed 100644 --- a/sources/editor/elementprimitivedecorator.cpp +++ b/sources/editor/elementprimitivedecorator.cpp @@ -472,8 +472,8 @@ QVector ElementPrimitiveDecorator::getResizingsPoints() const } /** - * @brief ElementPrimitiveDecorator::adjusteHandlerPos - */ + @brief ElementPrimitiveDecorator::adjusteHandlerPos +*/ void ElementPrimitiveDecorator::adjusteHandlerPos() { QVector points_vector = mapToScene(getResizingsPoints()); @@ -482,10 +482,10 @@ void ElementPrimitiveDecorator::adjusteHandlerPos() } /** - * @brief ElementPrimitiveDecorator::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief ElementPrimitiveDecorator::handlerMousePressEvent + @param qghi + @param event +*/ void ElementPrimitiveDecorator::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(event); @@ -499,10 +499,10 @@ void ElementPrimitiveDecorator::handlerMousePressEvent(QetGraphicsHandlerItem *q } /** - * @brief ElementPrimitiveDecorator::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief ElementPrimitiveDecorator::handlerMouseMoveEvent + @param qghi + @param event +*/ void ElementPrimitiveDecorator::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -554,10 +554,10 @@ void ElementPrimitiveDecorator::handlerMouseMoveEvent(QetGraphicsHandlerItem *qg } /** - * @brief ElementPrimitiveDecorator::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief ElementPrimitiveDecorator::handlerMouseReleaseEvent + @param qghi + @param event +*/ void ElementPrimitiveDecorator::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -585,9 +585,9 @@ void ElementPrimitiveDecorator::handlerMouseReleaseEvent(QetGraphicsHandlerItem } /** - * @brief ElementPrimitiveDecorator::addHandler - * Add handlers for this item - */ + @brief ElementPrimitiveDecorator::addHandler + Add handlers for this item +*/ void ElementPrimitiveDecorator::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -605,9 +605,9 @@ void ElementPrimitiveDecorator::addHandler() } /** - * @brief ElementPrimitiveDecorator::removeHandler - * Remove the handlers of this item - */ + @brief ElementPrimitiveDecorator::removeHandler + Remove the handlers of this item +*/ void ElementPrimitiveDecorator::removeHandler() { if (!m_handler_vector.isEmpty()) @@ -688,11 +688,11 @@ QET::ScalingMethod ElementPrimitiveDecorator::scalingMethod(QGraphicsSceneMouseE } /** - * @brief ElementPrimitiveDecorator::itemChange - * @param change - * @param value - * @return - */ + @brief ElementPrimitiveDecorator::itemChange + @param change + @param value + @return +*/ QVariant ElementPrimitiveDecorator::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSceneHasChanged) @@ -718,11 +718,11 @@ QVariant ElementPrimitiveDecorator::itemChange(QGraphicsItem::GraphicsItemChange } /** - * @brief ElementPrimitiveDecorator::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief ElementPrimitiveDecorator::sceneEventFilter + @param watched + @param event + @return +*/ bool ElementPrimitiveDecorator::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler diff --git a/sources/editor/elementscene.cpp b/sources/editor/elementscene.cpp index b206ac3ee..9681bd487 100644 --- a/sources/editor/elementscene.cpp +++ b/sources/editor/elementscene.cpp @@ -75,7 +75,7 @@ ElementScene::ElementScene(QETElementEditor *editor, QObject *parent) : /** @brief ElementScene::~ElementScene - */ +*/ ElementScene::~ElementScene() { //Disconnect to avoid crash, see bug report N° 122. diff --git a/sources/editor/elementview.cpp b/sources/editor/elementview.cpp index a8da50452..3d92e3d5d 100644 --- a/sources/editor/elementview.cpp +++ b/sources/editor/elementview.cpp @@ -144,10 +144,10 @@ void ElementView::zoomReset() { } /** - * @brief ElementView::adjustSceneRect - * Adjust the scenRect, so that he include all primitives of element - * plus the viewport of the scene with a margin of 1/3 of herself - */ + @brief ElementView::adjustSceneRect + Adjust the scenRect, so that he include all primitives of element + plus the viewport of the scene with a margin of 1/3 of herself +*/ void ElementView::adjustSceneRect() { QRectF esgr = m_scene -> elementSceneGeometricRect(); QRectF vpbr = mapToScene(this -> viewport()->rect()).boundingRect(); @@ -156,10 +156,10 @@ void ElementView::adjustSceneRect() { } /** - * @brief ElementView::resetSceneRect - * reset le sceneRect (zone du schéma visualisée par l'ElementView) afin que - * celui-ci inclut uniquement les primitives de l'élément dessiné. - */ + @brief ElementView::resetSceneRect + reset le sceneRect (zone du schéma visualisée par l'ElementView) afin que + celui-ci inclut uniquement les primitives de l'élément dessiné. +*/ void ElementView::resetSceneRect() { setSceneRect(m_scene -> elementSceneGeometricRect()); } @@ -366,9 +366,9 @@ void ElementView::mousePressEvent(QMouseEvent *e) { } /** - * @brief ElementView::mouseMoveEvent - * Manage the event move mouse - */ + @brief ElementView::mouseMoveEvent + Manage the event move mouse +*/ void ElementView::mouseMoveEvent(QMouseEvent *e) { if (e->buttons() == Qt::MidButton) { @@ -384,9 +384,9 @@ void ElementView::mouseMoveEvent(QMouseEvent *e) { } /** - * @brief ElementView::mouseReleaseEvent - * Manage event release click mouse - */ + @brief ElementView::mouseReleaseEvent + Manage event release click mouse +*/ void ElementView::mouseReleaseEvent(QMouseEvent *e) { if (e -> button() == Qt::MidButton) { setCursor(Qt::ArrowCursor); @@ -397,9 +397,9 @@ void ElementView::mouseReleaseEvent(QMouseEvent *e) { } /** - * @brief ElementView::gestures - * @return - */ + @brief ElementView::gestures + @return +*/ bool ElementView::gestures() const { QSettings settings; @@ -408,9 +408,9 @@ bool ElementView::gestures() const /** - * @brief ElementView::wheelEvent - * @param e - */ + @brief ElementView::wheelEvent + @param e +*/ void ElementView::wheelEvent(QWheelEvent *e) { //Zoom and scrolling if ( gestures() ) { @@ -439,11 +439,11 @@ bool ElementView::event(QEvent *e) { } /** - * Utilise le pincement du trackpad pour zoomer - * @brief ElementView::gestureEvent - * @param event - * @return - */ + Utilise le pincement du trackpad pour zoomer + @brief ElementView::gestureEvent + @param event + @return +*/ bool ElementView::gestureEvent(QGestureEvent *event){ if (QGesture *gesture = event->gesture(Qt::PinchGesture)) { QPinchGesture *pinch = static_cast(gesture); diff --git a/sources/editor/ellipseeditor.h b/sources/editor/ellipseeditor.h index 735561631..6dca2d015 100644 --- a/sources/editor/ellipseeditor.h +++ b/sources/editor/ellipseeditor.h @@ -62,10 +62,10 @@ class EllipseEditor : public ElementItemEditor private: void activeConnections(bool); - /*! - * \brief setUpChangeConnections - * Setup the connection from the ellipse(s) to the widget, to update it when the ellipse(s) are changed (moved ...) - */ + /** + @brief setUpChangeConnections + Setup the connection from the ellipse(s) to the widget, to update it when the ellipse(s) are changed (moved ...) + */ void setUpChangeConnections(); void disconnectChangeConnections(); }; diff --git a/sources/editor/esevent/eseventaddarc.cpp b/sources/editor/esevent/eseventaddarc.cpp index 214dc1ed4..5f37f4981 100644 --- a/sources/editor/esevent/eseventaddarc.cpp +++ b/sources/editor/esevent/eseventaddarc.cpp @@ -23,9 +23,9 @@ #include "eseventaddarc.h" /** - * @brief ESEventAddArc::ESEventAddArc - * @param scene - */ + @brief ESEventAddArc::ESEventAddArc + @param scene +*/ ESEventAddArc::ESEventAddArc(ElementScene *scene) : ESEventInterface(scene), m_arc(nullptr), @@ -33,18 +33,18 @@ ESEventAddArc::ESEventAddArc(ElementScene *scene) : {} /** - * @brief ESEventAddArc::~ESEventAddArc - */ + @brief ESEventAddArc::~ESEventAddArc +*/ ESEventAddArc::~ESEventAddArc() { if (m_running || m_abort) delete m_arc; } /** - * @brief ESEventAddPolygon::mousePressEvent - * @param event - * @return - */ + @brief ESEventAddPolygon::mousePressEvent + @param event + @return +*/ bool ESEventAddArc::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) @@ -79,10 +79,10 @@ bool ESEventAddArc::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ESEventAddArc::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddArc::mouseMoveEvent + @param event + @return +*/ bool ESEventAddArc::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross(event -> scenePos()); if (!m_arc) return false; @@ -94,10 +94,10 @@ bool ESEventAddArc::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddArc::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddArc::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddArc::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::RightButton) { if (m_arc) {delete m_arc; m_arc = nullptr;} @@ -108,10 +108,10 @@ bool ESEventAddArc::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddArc::keyPressEvent - * @param event - * @return - */ + @brief ESEventAddArc::keyPressEvent + @param event + @return +*/ bool ESEventAddArc::keyPressEvent(QKeyEvent *event) { if (m_arc && event->key() == Qt::Key_Space) { m_inverted = m_inverted ? false : true; @@ -123,9 +123,9 @@ bool ESEventAddArc::keyPressEvent(QKeyEvent *event) { } /** - * @brief ESEventAddArc::updateArc - * Redraw the arc with curent value - */ + @brief ESEventAddArc::updateArc + Redraw the arc with curent value +*/ void ESEventAddArc::updateArc() { qreal width = (m_mouse_pos.x() - m_origin.x())*2; diff --git a/sources/editor/esevent/eseventaddarc.h b/sources/editor/esevent/eseventaddarc.h index 4418af9d4..382d04016 100644 --- a/sources/editor/esevent/eseventaddarc.h +++ b/sources/editor/esevent/eseventaddarc.h @@ -25,9 +25,9 @@ class PartArc; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddArc class - * This ESEvent manage creation of arc in an ElementScene - */ + @brief The ESEventAddArc class + This ESEvent manage creation of arc in an ElementScene +*/ class ESEventAddArc : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventadddynamictextfield.cpp b/sources/editor/esevent/eseventadddynamictextfield.cpp index b556bf131..9933ce513 100644 --- a/sources/editor/esevent/eseventadddynamictextfield.cpp +++ b/sources/editor/esevent/eseventadddynamictextfield.cpp @@ -23,9 +23,9 @@ #include /** - * @brief ESEventAddDynamicTextField::ESEventAddDynamicTextField - * @param scene - */ + @brief ESEventAddDynamicTextField::ESEventAddDynamicTextField + @param scene +*/ ESEventAddDynamicTextField::ESEventAddDynamicTextField(ElementScene *scene) : ESEventInterface(scene) { @@ -35,17 +35,17 @@ ESEventAddDynamicTextField::ESEventAddDynamicTextField(ElementScene *scene) : } /** - * @brief ESEventAddDynamicTextField::~ESEventAddDynamicTextField - */ + @brief ESEventAddDynamicTextField::~ESEventAddDynamicTextField +*/ ESEventAddDynamicTextField::~ESEventAddDynamicTextField() { delete m_text; } /** - * @brief ESEventAddDynamicTextField::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddDynamicTextField::mouseMoveEvent + @param event + @return +*/ bool ESEventAddDynamicTextField::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { QPointF pos = m_scene->snapToGrid(event->scenePos()); @@ -55,10 +55,10 @@ bool ESEventAddDynamicTextField::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ESEventAddDynamicTextField::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddDynamicTextField::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddDynamicTextField::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton) diff --git a/sources/editor/esevent/eseventadddynamictextfield.h b/sources/editor/esevent/eseventadddynamictextfield.h index 8e322e532..8734f41d8 100644 --- a/sources/editor/esevent/eseventadddynamictextfield.h +++ b/sources/editor/esevent/eseventadddynamictextfield.h @@ -25,9 +25,9 @@ class PartDynamicTextField; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddDynamicTextField class - * This ESEvent manage creation of dynamic text field in an ElementScene - */ + @brief The ESEventAddDynamicTextField class + This ESEvent manage creation of dynamic text field in an ElementScene +*/ class ESEventAddDynamicTextField : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventaddellipse.cpp b/sources/editor/esevent/eseventaddellipse.cpp index 059bed288..4fa910ab0 100644 --- a/sources/editor/esevent/eseventaddellipse.cpp +++ b/sources/editor/esevent/eseventaddellipse.cpp @@ -23,17 +23,17 @@ #include "elementscene.h" /** - * @brief ESEventAddEllipse::ESEventAddEllipse - * @param scene - */ + @brief ESEventAddEllipse::ESEventAddEllipse + @param scene +*/ ESEventAddEllipse::ESEventAddEllipse(ElementScene *scene) : ESEventInterface(scene), m_ellipse(nullptr) {} /** - * @brief ESEventAddEllipse::~ESEventAddEllipse - */ + @brief ESEventAddEllipse::~ESEventAddEllipse +*/ ESEventAddEllipse::~ESEventAddEllipse() { if (m_running || m_abort){ delete m_ellipse; @@ -41,10 +41,10 @@ ESEventAddEllipse::~ESEventAddEllipse() { } /** - * @brief ESEventAddEllipse::mousePressEvent - * @param event - * @return - */ + @brief ESEventAddEllipse::mousePressEvent + @param event + @return +*/ bool ESEventAddEllipse::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) { if(!m_running) m_running = true; @@ -72,10 +72,10 @@ bool ESEventAddEllipse::mousePressEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddRect::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddRect::mouseMoveEvent + @param event + @return +*/ bool ESEventAddEllipse::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross(event -> scenePos()); if (!m_ellipse) return false; @@ -94,10 +94,10 @@ bool ESEventAddEllipse::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddEllipse::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddEllipse::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddEllipse::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::RightButton) { if (m_ellipse) {delete m_ellipse; m_ellipse = nullptr;} diff --git a/sources/editor/esevent/eseventaddellipse.h b/sources/editor/esevent/eseventaddellipse.h index d9a5a276f..585683652 100644 --- a/sources/editor/esevent/eseventaddellipse.h +++ b/sources/editor/esevent/eseventaddellipse.h @@ -26,9 +26,9 @@ class PartEllipse; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddEllipse class - * This ESEvent manage creation of ellpise in an ElementScene - */ + @brief The ESEventAddEllipse class + This ESEvent manage creation of ellpise in an ElementScene +*/ class ESEventAddEllipse : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventaddline.cpp b/sources/editor/esevent/eseventaddline.cpp index 5dd9d2e63..7c7373775 100644 --- a/sources/editor/esevent/eseventaddline.cpp +++ b/sources/editor/esevent/eseventaddline.cpp @@ -25,29 +25,29 @@ #include "editorcommands.h" /** - * @brief ESEventAddLine::ESEventAddLine - * Constructor - * @param scene : scene where we operate this action - */ + @brief ESEventAddLine::ESEventAddLine + Constructor + @param scene : scene where we operate this action +*/ ESEventAddLine::ESEventAddLine(ElementScene *scene) : ESEventInterface (scene), m_line (nullptr) {} /** - * @brief ESEventAddLine::~ESEventAddLine - * destructor - */ + @brief ESEventAddLine::~ESEventAddLine + destructor +*/ ESEventAddLine::~ESEventAddLine() { if (m_running || m_abort) delete m_line; } /** - * @brief ESEventAddLine::mousePressEvent - * @param event - * @return - */ + @brief ESEventAddLine::mousePressEvent + @param event + @return +*/ bool ESEventAddLine::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) { @@ -76,10 +76,10 @@ bool ESEventAddLine::mousePressEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddLine::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddLine::mouseMoveEvent + @param event + @return +*/ bool ESEventAddLine::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross (event -> scenePos()); @@ -92,10 +92,10 @@ bool ESEventAddLine::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ESEventAddLine::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddLine::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddLine::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::RightButton) { if (m_line) {delete m_line; m_line = nullptr;} diff --git a/sources/editor/esevent/eseventaddline.h b/sources/editor/esevent/eseventaddline.h index f7f122119..00ffe8576 100644 --- a/sources/editor/esevent/eseventaddline.h +++ b/sources/editor/esevent/eseventaddline.h @@ -25,9 +25,9 @@ class PartLine; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddLine class - * This ESEvent manage creation of line in a ElementScene - */ + @brief The ESEventAddLine class + This ESEvent manage creation of line in a ElementScene +*/ class ESEventAddLine : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventaddpolygon.cpp b/sources/editor/esevent/eseventaddpolygon.cpp index 5de96f7a4..07dc78789 100644 --- a/sources/editor/esevent/eseventaddpolygon.cpp +++ b/sources/editor/esevent/eseventaddpolygon.cpp @@ -23,27 +23,27 @@ #include "editorcommands.h" /** - * @brief ESEventAddPolygon::ESEventAddPolygon - * @param scene - */ + @brief ESEventAddPolygon::ESEventAddPolygon + @param scene +*/ ESEventAddPolygon::ESEventAddPolygon(ElementScene *scene) : ESEventInterface(scene), m_polygon(nullptr) {} /** - * @brief ESEventAddPolygon::~ESEventAddPolygon - */ + @brief ESEventAddPolygon::~ESEventAddPolygon +*/ ESEventAddPolygon::~ESEventAddPolygon() { if (m_running || m_abort) delete m_polygon; } /** - * @brief ESEventAddPolygon::mousePressEvent - * @param event - * @return - */ + @brief ESEventAddPolygon::mousePressEvent + @param event + @return +*/ bool ESEventAddPolygon::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) { if(!m_running) m_running = true; @@ -63,10 +63,10 @@ bool ESEventAddPolygon::mousePressEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddPolygon::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddPolygon::mouseMoveEvent + @param event + @return +*/ bool ESEventAddPolygon::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross(event -> scenePos()); if (!m_polygon) return false; @@ -76,10 +76,10 @@ bool ESEventAddPolygon::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddPolygon::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddPolygon::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddPolygon::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::RightButton) { if (m_polygon) { @@ -99,10 +99,10 @@ bool ESEventAddPolygon::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddPolygon::mouseDoubleClickEvent - * @param event - * @return - */ + @brief ESEventAddPolygon::mouseDoubleClickEvent + @param event + @return +*/ bool ESEventAddPolygon::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) diff --git a/sources/editor/esevent/eseventaddpolygon.h b/sources/editor/esevent/eseventaddpolygon.h index 7b05251e3..b31673acd 100644 --- a/sources/editor/esevent/eseventaddpolygon.h +++ b/sources/editor/esevent/eseventaddpolygon.h @@ -25,9 +25,9 @@ class PartPolygon; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddPolygon class - * This ESEvent manage creation of polygon in an ElementScene - */ + @brief The ESEventAddPolygon class + This ESEvent manage creation of polygon in an ElementScene +*/ class ESEventAddPolygon : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventaddrect.cpp b/sources/editor/esevent/eseventaddrect.cpp index 2ac973a85..0e3386701 100644 --- a/sources/editor/esevent/eseventaddrect.cpp +++ b/sources/editor/esevent/eseventaddrect.cpp @@ -23,27 +23,27 @@ #include "editorcommands.h" /** - * @brief ESEventAddRect::ESEventAddRect - * @param scene - */ + @brief ESEventAddRect::ESEventAddRect + @param scene +*/ ESEventAddRect::ESEventAddRect(ElementScene *scene) : ESEventInterface(scene), m_rect(nullptr) {} /** - * @brief ESEventAddRect::~ESEventAddRect - */ + @brief ESEventAddRect::~ESEventAddRect +*/ ESEventAddRect::~ESEventAddRect() { if (m_running || m_abort) delete m_rect; } /** - * @brief ESEventAddRect::mousePressEvent - * @param event - * @return - */ + @brief ESEventAddRect::mousePressEvent + @param event + @return +*/ bool ESEventAddRect::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) @@ -75,10 +75,10 @@ bool ESEventAddRect::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ESEventAddRect::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddRect::mouseMoveEvent + @param event + @return +*/ bool ESEventAddRect::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { updateHelpCross(event -> scenePos()); if (!m_rect) return false; @@ -89,10 +89,10 @@ bool ESEventAddRect::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddRect::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddRect::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddRect::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::RightButton) { if (m_rect) {delete m_rect; m_rect = nullptr;} diff --git a/sources/editor/esevent/eseventaddterminal.cpp b/sources/editor/esevent/eseventaddterminal.cpp index 55efe3ae4..beac60416 100644 --- a/sources/editor/esevent/eseventaddterminal.cpp +++ b/sources/editor/esevent/eseventaddterminal.cpp @@ -23,9 +23,9 @@ #include "eseventaddterminal.h" /** - * @brief ESEventAddTerminal::ESEventAddTerminal - * @param scene - */ + @brief ESEventAddTerminal::ESEventAddTerminal + @param scene +*/ ESEventAddTerminal::ESEventAddTerminal(ElementScene *scene) : ESEventInterface(scene) { @@ -35,17 +35,17 @@ ESEventAddTerminal::ESEventAddTerminal(ElementScene *scene) : } /** - * @brief ESEventAddTerminal::~ESEventAddTerminal - */ + @brief ESEventAddTerminal::~ESEventAddTerminal +*/ ESEventAddTerminal::~ESEventAddTerminal() { delete m_terminal; } /** - * @brief ESEventAddTerminal::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddTerminal::mouseMoveEvent + @param event + @return +*/ bool ESEventAddTerminal::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { QPointF pos = m_scene -> snapToGrid(event -> scenePos()); updateHelpCross(pos); @@ -54,10 +54,10 @@ bool ESEventAddTerminal::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddTerminal::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddTerminal::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddTerminal::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event -> button() == Qt::LeftButton) { m_scene -> undoStack().push(new AddPartCommand(QObject::tr("Borne"), m_scene, m_terminal)); @@ -80,10 +80,10 @@ bool ESEventAddTerminal::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddTerminal::keyPressEvent - * @param event - * @return - */ + @brief ESEventAddTerminal::keyPressEvent + @param event + @return +*/ bool ESEventAddTerminal::keyPressEvent(QKeyEvent *event) { if (event -> key() == Qt::Key_Space) { switch (m_terminal->orientation()) { diff --git a/sources/editor/esevent/eseventaddterminal.h b/sources/editor/esevent/eseventaddterminal.h index c3af503ea..edb856181 100644 --- a/sources/editor/esevent/eseventaddterminal.h +++ b/sources/editor/esevent/eseventaddterminal.h @@ -25,9 +25,9 @@ class PartTerminal; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddTerminal class - * This ESEvent manage creation of terminal in an ElementScene - */ + @brief The ESEventAddTerminal class + This ESEvent manage creation of terminal in an ElementScene +*/ class ESEventAddTerminal : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventaddtext.cpp b/sources/editor/esevent/eseventaddtext.cpp index e8a1e6588..041747a1f 100644 --- a/sources/editor/esevent/eseventaddtext.cpp +++ b/sources/editor/esevent/eseventaddtext.cpp @@ -23,9 +23,9 @@ #include "elementscene.h" /** - * @brief ESEventAddText::ESEventAddText - * @param scene - */ + @brief ESEventAddText::ESEventAddText + @param scene +*/ ESEventAddText::ESEventAddText(ElementScene *scene) : ESEventInterface(scene) { @@ -35,17 +35,17 @@ ESEventAddText::ESEventAddText(ElementScene *scene) : } /** - * @brief ESEventAddText::~ESEventAddText - */ + @brief ESEventAddText::~ESEventAddText +*/ ESEventAddText::~ESEventAddText() { delete m_text; } /** - * @brief ESEventAddText::mouseMoveEvent - * @param event - * @return - */ + @brief ESEventAddText::mouseMoveEvent + @param event + @return +*/ bool ESEventAddText::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { QPointF pos = m_scene -> snapToGrid(event -> scenePos()); updateHelpCross(pos); @@ -54,10 +54,10 @@ bool ESEventAddText::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ESEventAddText::mouseReleaseEvent - * @param event - * @return - */ + @brief ESEventAddText::mouseReleaseEvent + @param event + @return +*/ bool ESEventAddText::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton) { m_scene -> undoStack().push(new AddPartCommand(QObject::tr("Texte"), m_scene, m_text)); diff --git a/sources/editor/esevent/eseventaddtext.h b/sources/editor/esevent/eseventaddtext.h index 4a587693b..2c00423b8 100644 --- a/sources/editor/esevent/eseventaddtext.h +++ b/sources/editor/esevent/eseventaddtext.h @@ -25,9 +25,9 @@ class PartText; class QGraphicsSceneMouseEvent; /** - * @brief The ESEventAddText class - * This ESEvent manage creation of text in an ElementScene - */ + @brief The ESEventAddText class + This ESEvent manage creation of text in an ElementScene +*/ class ESEventAddText : public ESEventInterface { public: diff --git a/sources/editor/esevent/eseventinterface.cpp b/sources/editor/esevent/eseventinterface.cpp index 1a65330d8..d44fa0811 100644 --- a/sources/editor/esevent/eseventinterface.cpp +++ b/sources/editor/esevent/eseventinterface.cpp @@ -32,9 +32,9 @@ ESEventInterface::ESEventInterface(ElementScene *scene) : } /** - * @brief ESEventInterface::init - * Init this event interface - */ + @brief ESEventInterface::init + Init this event interface +*/ void ESEventInterface::init() { m_scene->setBehavior(ElementScene::Behavior::AddPart); @@ -42,9 +42,9 @@ void ESEventInterface::init() } /** - * @brief ESEventInterface::~ESEventInterface - * Destructor - */ + @brief ESEventInterface::~ESEventInterface + Destructor +*/ ESEventInterface::~ESEventInterface() { delete m_help_horiz; @@ -80,11 +80,11 @@ bool ESEventInterface::wheelEvent(QGraphicsSceneWheelEvent *event) { } /** - * @brief ESEventInterface::keyPressEvent - * By default, press escape key abort the curent action - * @param event - * @return - */ + @brief ESEventInterface::keyPressEvent + By default, press escape key abort the curent action + @param event + @return +*/ bool ESEventInterface::keyPressEvent(QKeyEvent *event) { if (event->key() == Qt::Key_Escape) { m_running = false; diff --git a/sources/editor/graphicspart/abstractpartellipse.cpp b/sources/editor/graphicspart/abstractpartellipse.cpp index 2efbad722..32a1920fd 100644 --- a/sources/editor/graphicspart/abstractpartellipse.cpp +++ b/sources/editor/graphicspart/abstractpartellipse.cpp @@ -18,11 +18,11 @@ #include "abstractpartellipse.h" /** - * @brief AbstractPartEllipse::AbstractPartEllipse - * Constructor - * @param editor : QETElementEditor of this part - * @param parent : parent item - */ + @brief AbstractPartEllipse::AbstractPartEllipse + Constructor + @param editor : QETElementEditor of this part + @param parent : parent item +*/ AbstractPartEllipse::AbstractPartEllipse(QETElementEditor *editor, QGraphicsItem *parent) : CustomElementGraphicPart(editor, parent), m_rect (QRectF(0, 0, 0, 0)), @@ -31,17 +31,17 @@ AbstractPartEllipse::AbstractPartEllipse(QETElementEditor *editor, QGraphicsItem {} /** - * @brief AbstractPartEllipse::~AbstractPartEllipse - * Destructor - */ + @brief AbstractPartEllipse::~AbstractPartEllipse + Destructor +*/ AbstractPartEllipse::~AbstractPartEllipse() {} /** - * @brief AbstractPartEllipse::startUserTransformation - * Start the user-induced transformation, provided this primitive is contained - * within the initial_selection_rect bounding rectangle. - * @param initial_selection_rect - */ + @brief AbstractPartEllipse::startUserTransformation + Start the user-induced transformation, provided this primitive is contained + within the initial_selection_rect bounding rectangle. + @param initial_selection_rect +*/ void AbstractPartEllipse::startUserTransformation(const QRectF &initial_selection_rect) { Q_UNUSED(initial_selection_rect) @@ -51,11 +51,11 @@ void AbstractPartEllipse::startUserTransformation(const QRectF &initial_selectio } /** - * @brief AbstractPartEllipse::handleUserTransformation - * Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect - * @param initial_selection_rect - * @param new_selection_rect - */ + @brief AbstractPartEllipse::handleUserTransformation + Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect + @param initial_selection_rect + @param new_selection_rect +*/ void AbstractPartEllipse::handleUserTransformation(const QRectF &initial_selection_rect, const QRectF &new_selection_rect) { QList mapped_points = mapPoints(initial_selection_rect, new_selection_rect, saved_points_); @@ -63,10 +63,10 @@ void AbstractPartEllipse::handleUserTransformation(const QRectF &initial_selecti } /** - * @brief AbstractPartEllipse::boundingRect - * Bounding rectangle this part can fit into - * @return - */ + @brief AbstractPartEllipse::boundingRect + Bounding rectangle this part can fit into + @return +*/ QRectF AbstractPartEllipse::boundingRect() const { qreal adjust = (SHADOWS_HEIGHT + penWeight()) / 2; @@ -79,40 +79,43 @@ QRectF AbstractPartEllipse::boundingRect() const } /** - * @brief AbstractPartEllipse::sceneGeometricRect - * @return the minimum, margin-less rectangle this part can fit into in scene coordinates. - * It is different from boundingRect() because it is not supposed - * to imply any margin, and it is different from shape because it is a regular - * rectangle, not a complex shape. - */ + @brief AbstractPartEllipse::sceneGeometricRect + @return the minimum, + margin-less rectangle this part can fit into in scene coordinates. + It is different from boundingRect() because it is not supposed + to imply any margin, + and it is different from shape because it is a regular + rectangle, not a complex shape. +*/ QRectF AbstractPartEllipse::sceneGeometricRect() const { return(mapToScene(rect()).boundingRect()); } /** - * @brief AbstractPartEllipse::sceneTopLeft - * @return return the top left of rectangle, in scene coordinate - */ + @brief AbstractPartEllipse::sceneTopLeft + @return return the top left of rectangle, in scene coordinate +*/ QPointF AbstractPartEllipse::sceneTopLeft() const { return(mapToScene(rect().topLeft())); } /** - * @brief AbstractPartEllipse::rect - * Returns the item's ellipse geometry as a QRectF. - */ + @brief AbstractPartEllipse::rect + Returns the item's ellipse geometry as a QRectF. +*/ QRectF AbstractPartEllipse::rect() const { return m_rect; } /** - * @brief AbstractPartEllipse::setRect - * Sets the item's ellipse geometry to rect. - * The rectangle's left edge defines the left edge of the ellipse, - * and the rectangle's top edge describes the top of the ellipse - * The height and width of the rectangle describe the height and width of the ellipse. - * @param rect - */ + @brief AbstractPartEllipse::setRect + Sets the item's ellipse geometry to rect. + The rectangle's left edge defines the left edge of the ellipse, + and the rectangle's top edge describes the top of the ellipse + The height and width of the rectangle + describe the height and width of the ellipse. + @param rect +*/ void AbstractPartEllipse::setRect(const QRectF &rect) { if (rect == m_rect) return; @@ -123,21 +126,24 @@ void AbstractPartEllipse::setRect(const QRectF &rect) } /** - * @brief AbstractPartEllipse::isUseless - * @return true if this part is irrelevant and does not deserve to be Retained / registered. - * An ellipse is relevant when is rect is not null. - */ + @brief AbstractPartEllipse::isUseless + @return true if this part is irrelevant + and does not deserve to be Retained / registered. + An ellipse is relevant when is rect is not null. +*/ bool AbstractPartEllipse::isUseless() const { return(rect().isNull()); } /** - * @brief AbstractPartEllipse::setStartAngle - * Sets the start angle for an ellipse segment to angle, which is in 16ths of a degree. - * This angle is used together with spanAngle() for representing an ellipse segment (a pie). - * By default, the start angle is 0. - * @param start_angle - */ + @brief AbstractPartEllipse::setStartAngle + Sets the start angle for an ellipse segment to angle, + which is in 16ths of a degree. + This angle is used together with spanAngle() + for representing an ellipse segment (a pie). + By default, the start angle is 0. + @param start_angle +*/ void AbstractPartEllipse::setStartAngle(const int &start_angle) { if (m_start_angle == start_angle) return; @@ -147,12 +153,13 @@ void AbstractPartEllipse::setStartAngle(const int &start_angle) } /** - * @brief AbstractPartEllipse::setSpanAngle - * Returns the span angle of an ellipse segment in 16ths of a degree. - * This angle is used together with startAngle() for representing an ellipse segment (a pie). - * By default, this function returns 5760 (360 * 16, a full ellipse). - * @param span_angle - */ + @brief AbstractPartEllipse::setSpanAngle + Returns the span angle of an ellipse segment in 16ths of a degree. + This angle is used together with startAngle() + for representing an ellipse segment (a pie). + By default, this function returns 5760 (360 * 16, a full ellipse). + @param span_angle +*/ void AbstractPartEllipse::setSpanAngle(const int &span_angle) { if (m_span_angle == span_angle) return; diff --git a/sources/editor/graphicspart/abstractpartellipse.h b/sources/editor/graphicspart/abstractpartellipse.h index 3503cd8b3..c4dd5b136 100644 --- a/sources/editor/graphicspart/abstractpartellipse.h +++ b/sources/editor/graphicspart/abstractpartellipse.h @@ -23,15 +23,19 @@ class QetGraphicsHandlerItem; /** - * @brief The AbstractPartEllipse class - * This is the base class for all ellipse based item like ellipse, circle, arc. - * This class only provide common method for edit the ellipse like rect that contain the ellipse. - * All coordinates is in item coordinate, except pos(), center(), centerX() and centerY() - * which are in parent coordinate (or scene if no parent). - * - * In several points, this class is a copy of QGraphicsEllipseItem with some change, - * (the use of Q_PROPERTY) to be easily used with Element editor. - */ + @brief The AbstractPartEllipse class + This is the base class for all ellipse based item like ellipse, + circle, arc. + This class only provide common method for edit the ellipse + like rect that contain the ellipse. + All coordinates is in item coordinate, except pos(), + center(), centerX() and centerY() + which are in parent coordinate (or scene if no parent). + + In several points, + this class is a copy of QGraphicsEllipseItem with some change, + (the use of Q_PROPERTY) to be easily used with Element editor. +*/ class AbstractPartEllipse : public CustomElementGraphicPart { Q_OBJECT diff --git a/sources/editor/graphicspart/customelementgraphicpart.cpp b/sources/editor/graphicspart/customelementgraphicpart.cpp index d01114d8c..193a7bd5b 100644 --- a/sources/editor/graphicspart/customelementgraphicpart.cpp +++ b/sources/editor/graphicspart/customelementgraphicpart.cpp @@ -20,12 +20,12 @@ #include "QPropertyUndoCommand/qpropertyundocommand.h" /** - * @brief CustomElementGraphicPart::CustomElementGraphicPart - * Default constructor. - * By default, item is selectable, send geometry change (Qt > 4.6), - * accept mouse left button and accept hover event - * @param editor QETElement editor that belong this. - */ + @brief CustomElementGraphicPart::CustomElementGraphicPart + Default constructor. + By default, item is selectable, send geometry change (Qt > 4.6), + accept mouse left button and accept hover event + @param editor QETElement editor that belong this. +*/ CustomElementGraphicPart::CustomElementGraphicPart(QETElementEditor *editor, QGraphicsItem *parent) : QGraphicsObject (parent), CustomElementPart(editor), @@ -41,18 +41,18 @@ CustomElementGraphicPart::CustomElementGraphicPart(QETElementEditor *editor, QGr } /** - * @brief CustomElementGraphicPart::~CustomElementGraphicPart - * Destructor - */ + @brief CustomElementGraphicPart::~CustomElementGraphicPart + Destructor +*/ CustomElementGraphicPart::~CustomElementGraphicPart() {} /** - * @brief CustomElementGraphicPart::drawCross - * Draw a cross at pos center - * @param center : center of cross - * @param painter : painter to use for draw cross, - * the painter state is restored at end of this method. - */ + @brief CustomElementGraphicPart::drawCross + Draw a cross at pos center + @param center : center of cross + @param painter : painter to use for draw cross, + the painter state is restored at end of this method. +*/ void CustomElementGraphicPart::drawCross(const QPointF ¢er, QPainter *painter) { painter -> save(); @@ -64,10 +64,10 @@ void CustomElementGraphicPart::drawCross(const QPointF ¢er, QPainter *painte } /** - * @brief CustomElementGraphicPart::setLineStyle - * Set line style to ls - * @param ls - */ + @brief CustomElementGraphicPart::setLineStyle + Set line style to ls + @param ls +*/ void CustomElementGraphicPart::setLineStyle(const LineStyle ls) { if (_linestyle == ls) return; @@ -76,10 +76,10 @@ void CustomElementGraphicPart::setLineStyle(const LineStyle ls) } /** - * @brief CustomElementGraphicPart::setLineWeight - * Set line weight to lw - * @param lw - */ + @brief CustomElementGraphicPart::setLineWeight + Set line weight to lw + @param lw +*/ void CustomElementGraphicPart::setLineWeight(const LineWeight lw) { if (_lineweight == lw) return; @@ -88,9 +88,9 @@ void CustomElementGraphicPart::setLineWeight(const LineWeight lw) } /** - * @brief CustomElementGraphicPart::penWeight - * @return the weight of pen - */ + @brief CustomElementGraphicPart::penWeight + @return the weight of pen +*/ qreal CustomElementGraphicPart::penWeight() const { if (_lineweight == NoneWeight || _lineweight == ThinWeight) return 0; @@ -101,10 +101,10 @@ qreal CustomElementGraphicPart::penWeight() const } /** - * @brief CustomElementGraphicPart::setFilling - * Set filling to f - * @param f - */ + @brief CustomElementGraphicPart::setFilling + Set filling to f + @param f +*/ void CustomElementGraphicPart::setFilling(const Filling f) { if (_filling == f) return; @@ -113,10 +113,10 @@ void CustomElementGraphicPart::setFilling(const Filling f) } /** - * @brief CustomElementGraphicPart::setColor - * Set color to c - * @param c - */ + @brief CustomElementGraphicPart::setColor + Set color to c + @param c +*/ void CustomElementGraphicPart::setColor(const Color c) { if (_color == c) return; @@ -125,10 +125,10 @@ void CustomElementGraphicPart::setColor(const Color c) } /** - * @brief CustomElementGraphicPart::setAntialiased - * Set antialias to b - * @param b - */ + @brief CustomElementGraphicPart::setAntialiased + Set antialias to b + @param b +*/ void CustomElementGraphicPart::setAntialiased(const bool b) { if (_antialiased == b) return; @@ -137,13 +137,13 @@ void CustomElementGraphicPart::setAntialiased(const bool b) } /** - * @brief CustomElementGraphicPart::stylesToXml - * Write the curent style to xml element. - * The style are stored like this: - * name-of-style:value;name-of-style:value - * Each style separate by ; and name-style/value are separate by : - * @param qde : QDOmElement used to write the style. - */ + @brief CustomElementGraphicPart::stylesToXml + Write the curent style to xml element. + The style are stored like this: + name-of-style:value;name-of-style:value + Each style separate by ; and name-style/value are separate by : + @param qde : QDOmElement used to write the style. +*/ void CustomElementGraphicPart::stylesToXml(QDomElement &qde) const { QString css_like_styles; @@ -486,10 +486,10 @@ void CustomElementGraphicPart::stylesToXml(QDomElement &qde) const /** - * @brief CustomElementGraphicPart::stylesFromXml - * Read the style used by this, from a xml element. - * @param qde : QDomElement used to read the style - */ + @brief CustomElementGraphicPart::stylesFromXml + Read the style used by this, from a xml element. + @param qde : QDomElement used to read the style +*/ void CustomElementGraphicPart::stylesFromXml(const QDomElement &qde) { resetStyles(); @@ -849,10 +849,10 @@ void CustomElementGraphicPart::stylesFromXml(const QDomElement &qde) /** - * @brief CustomElementGraphicPart::resetStyles - * Reset the curent style to default, - * same style of default constructor - */ + @brief CustomElementGraphicPart::resetStyles + Reset the curent style to default, + same style of default constructor +*/ void CustomElementGraphicPart::resetStyles() { _linestyle = NormalStyle; @@ -863,10 +863,10 @@ void CustomElementGraphicPart::resetStyles() } /** - * @brief CustomElementGraphicPart::applyStylesToQPainter - * Apply the current style to the QPainter - * @param painter - */ + @brief CustomElementGraphicPart::applyStylesToQPainter + Apply the current style to the QPainter + @param painter +*/ void CustomElementGraphicPart::applyStylesToQPainter(QPainter &painter) const { //Get the pen and brush @@ -1216,12 +1216,12 @@ void CustomElementGraphicPart::applyStylesToQPainter(QPainter &painter) const } /** - * @brief CustomElementGraphicPart::drawShadowShape - * Draw a transparent blue shadow arround the shape of this item. - * The QPainterPathStroker used to draw shadows have a width of SHADOWS_HEIGHT - * Be carefull if penWeight of this item is to 0 the outline of strock is bigger of 0.5 - * @param painter : painter to use for draw this shadows - */ + @brief CustomElementGraphicPart::drawShadowShape + Draw a transparent blue shadow arround the shape of this item. + The QPainterPathStroker used to draw shadows have a width of SHADOWS_HEIGHT + Be carefull if penWeight of this item is to 0 the outline of strock is bigger of 0.5 + @param painter : painter to use for draw this shadows +*/ void CustomElementGraphicPart::drawShadowShape(QPainter *painter) { //@FIXME if pen weight is 0, the strock outline is SHADOWS_HEIGHT/2 + 0.5 @@ -1240,14 +1240,14 @@ void CustomElementGraphicPart::drawShadowShape(QPainter *painter) } /** - * @brief CustomElementGraphicPart::itemChange - * Reimplemented from QGraphicsObject. - * If the item position change call updateCurrentPartEditor() - * the change is always send to QGraphicsObject - * @param change - * @param value - * @return the returned value of QGraphicsObject::itemChange - */ + @brief CustomElementGraphicPart::itemChange + Reimplemented from QGraphicsObject. + If the item position change call updateCurrentPartEditor() + the change is always send to QGraphicsObject + @param change + @param value + @return the returned value of QGraphicsObject::itemChange +*/ QVariant CustomElementGraphicPart::itemChange(GraphicsItemChange change, const QVariant &value) { if (scene()) @@ -1258,11 +1258,11 @@ QVariant CustomElementGraphicPart::itemChange(GraphicsItemChange change, const Q } /** - * @brief CustomElementGraphicPart::hoverEnterEvent - * Reimplemented from QGraphicsObject. - * Set m_hovered to true - * @param event - */ + @brief CustomElementGraphicPart::hoverEnterEvent + Reimplemented from QGraphicsObject. + Set m_hovered to true + @param event +*/ void CustomElementGraphicPart::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { m_hovered = true; @@ -1270,11 +1270,11 @@ void CustomElementGraphicPart::hoverEnterEvent(QGraphicsSceneHoverEvent *event) } /** - * @brief CustomElementGraphicPart::hoverLeaveEvent - * Reimplemented from QGraphicsObject. - * Set m_hovered to false - * @param event - */ + @brief CustomElementGraphicPart::hoverLeaveEvent + Reimplemented from QGraphicsObject. + Set m_hovered to false + @param event +*/ void CustomElementGraphicPart::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { m_hovered = false; diff --git a/sources/editor/graphicspart/customelementgraphicpart.h b/sources/editor/graphicspart/customelementgraphicpart.h index 341c245c2..e4500a606 100644 --- a/sources/editor/graphicspart/customelementgraphicpart.h +++ b/sources/editor/graphicspart/customelementgraphicpart.h @@ -26,10 +26,12 @@ class QPainter; /** - * @brief The CustomElementGraphicPart class - * This class is the base for all home-made primitive like line, rectangle, ellipse etc.... - * It provides methods and enums to manage style attributes available for primitive (color, pen style, etc...) - */ + @brief The CustomElementGraphicPart class + This class is the base for all home-made primitive like line, + rectangle, ellipse etc.... + It provides methods and enums to manage style attributes available + for primitive (color, pen style, etc...) +*/ class CustomElementGraphicPart : public QGraphicsObject, public CustomElementPart { #define SHADOWS_HEIGHT 4.0 diff --git a/sources/editor/graphicspart/partarc.cpp b/sources/editor/graphicspart/partarc.cpp index a42bff805..344f6a8e0 100644 --- a/sources/editor/graphicspart/partarc.cpp +++ b/sources/editor/graphicspart/partarc.cpp @@ -23,11 +23,11 @@ /** - * @brief PartArc::PartArc - * Constructor - * @param editor : QETElementEditor of this part - * @param parent : parent item - */ + @brief PartArc::PartArc + Constructor + @param editor : QETElementEditor of this part + @param parent : parent item +*/ PartArc::PartArc(QETElementEditor *editor, QGraphicsItem *parent) : AbstractPartEllipse(editor, parent) { @@ -36,9 +36,9 @@ PartArc::PartArc(QETElementEditor *editor, QGraphicsItem *parent) : } /** - * @brief PartArc::~PartArc - * Destructor - */ + @brief PartArc::~PartArc + Destructor +*/ PartArc::~PartArc() { if(m_undo_command) delete m_undo_command; @@ -46,12 +46,12 @@ PartArc::~PartArc() } /** - * @brief PartArc::paint - * Draw this arc - * @param painter - * @param options - * @param widget - */ + @brief PartArc::paint + Draw this arc + @param painter + @param options + @param widget +*/ void PartArc::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *widget) { Q_UNUSED(widget); @@ -90,11 +90,11 @@ void PartArc::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, } /** - * @brief PartArc::toXml - * Export this arc in xml - * @param xml_document : Xml document to use for create the xml element. - * @return : an xml element that describe this arc - */ + @brief PartArc::toXml + Export this arc in xml + @param xml_document : Xml document to use for create the xml element. + @return : an xml element that describe this arc +*/ const QDomElement PartArc::toXml(QDomDocument &xml_document) const { QDomElement xml_element = xml_document.createElement("arc"); QPointF top_left(sceneTopLeft()); @@ -110,10 +110,10 @@ const QDomElement PartArc::toXml(QDomDocument &xml_document) const { } /** - * @brief PartArc::fromXml - * Import the properties of this arc from a xml element. - * @param qde : Xml document to use. - */ + @brief PartArc::fromXml + Import the properties of this arc from a xml element. + @param qde : Xml document to use. +*/ void PartArc::fromXml(const QDomElement &qde) { stylesFromXml(qde); m_rect = QRectF(mapFromScene(qde.attribute("x", "0").toDouble(), @@ -126,9 +126,9 @@ void PartArc::fromXml(const QDomElement &qde) { } /** - * @brief PartArc::shape - * @return the shape of this item - */ + @brief PartArc::shape + @return the shape of this item +*/ QPainterPath PartArc::shape() const { QPainterPath shape; @@ -155,10 +155,10 @@ QPainterPath PartArc::shadowShape() const } /** - * @brief PartArc::mouseReleaseEvent - * Handle mouse release event - * @param event - */ + @brief PartArc::mouseReleaseEvent + Handle mouse release event + @param event +*/ void PartArc::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton && event->buttonDownPos(Qt::LeftButton) == event->pos()) @@ -168,11 +168,11 @@ void PartArc::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief PartArc::itemChange - * @param change - * @param value - * @return - */ + @brief PartArc::itemChange + @param change + @param value + @return +*/ QVariant PartArc::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged && scene()) @@ -208,11 +208,11 @@ QVariant PartArc::itemChange(QGraphicsItem::GraphicsItemChange change, const QVa } /** - * @brief PartArc::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief PartArc::sceneEventFilter + @param watched + @param event + @return +*/ bool PartArc::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -248,8 +248,8 @@ bool PartArc::sceneEventFilter(QGraphicsItem *watched, QEvent *event) } /** - * @brief PartArc::switchResizeMode - */ + @brief PartArc::switchResizeMode +*/ void PartArc::switchResizeMode() { if (m_resize_mode == 1) @@ -283,8 +283,8 @@ void PartArc::switchResizeMode() } /** - * @brief PartArc::adjusteHandlerPos - */ + @brief PartArc::adjusteHandlerPos +*/ void PartArc::adjusteHandlerPos() { if (m_handler_vector.isEmpty()) @@ -307,10 +307,10 @@ void PartArc::adjusteHandlerPos() } /** - * @brief PartArc::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief PartArc::handlerMousePressEvent + @param qghi + @param event +*/ void PartArc::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -346,10 +346,10 @@ void PartArc::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsScen } /** - * @brief PartArc::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief PartArc::handlerMouseMoveEvent + @param qghi + @param event +*/ void PartArc::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -380,10 +380,10 @@ void PartArc::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsScene } /** - * @brief PartArc::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief PartArc::handlerMouseReleaseEvent + @param qghi + @param event +*/ void PartArc::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -421,9 +421,9 @@ void PartArc::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSc } /** - * @brief PartArc::sceneSelectionChanged - * When the scene selection change, if there are several primitive selected, we remove the handler of this item - */ + @brief PartArc::sceneSelectionChanged + When the scene selection change, if there are several primitive selected, we remove the handler of this item +*/ void PartArc::sceneSelectionChanged() { if (this->isSelected() && scene()->selectedItems().size() == 1) @@ -433,9 +433,9 @@ void PartArc::sceneSelectionChanged() } /** - * @brief PartArc::addHandler - * Add handlers for this item - */ + @brief PartArc::addHandler + Add handlers for this item +*/ void PartArc::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -464,9 +464,9 @@ void PartArc::addHandler() } /** - * @brief PartArc::removeHandler - * Remove the handlers of this item - */ + @brief PartArc::removeHandler + Remove the handlers of this item +*/ void PartArc::removeHandler() { if (!m_handler_vector.isEmpty()) diff --git a/sources/editor/graphicspart/partarc.h b/sources/editor/graphicspart/partarc.h index b0c8a8816..29a3c93e0 100644 --- a/sources/editor/graphicspart/partarc.h +++ b/sources/editor/graphicspart/partarc.h @@ -24,10 +24,10 @@ class QPropertyUndoCommand; class QetGraphicsHandlerItem; /** - * @brief The PartArc class - * This class represents an elliptical arc primitive which may be used to - * compose the drawing of an electrical element within the element editor. - */ + @brief The PartArc class + This class represents an elliptical arc primitive which may be used to + compose the drawing of an electrical element within the element editor. +*/ class PartArc : public AbstractPartEllipse { Q_OBJECT @@ -42,9 +42,9 @@ class PartArc : public AbstractPartEllipse public: enum { Type = UserType + 1101 }; /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartArc. - * @return the QGraphicsItem type - */ + Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartArc. + @return the QGraphicsItem type + */ int type() const override { return Type; } void paint(QPainter *, const QStyleOptionGraphicsItem *, QWidget * = nullptr) override; diff --git a/sources/editor/graphicspart/partdynamictextfield.cpp b/sources/editor/graphicspart/partdynamictextfield.cpp index ee005048a..285cddbbe 100644 --- a/sources/editor/graphicspart/partdynamictextfield.cpp +++ b/sources/editor/graphicspart/partdynamictextfield.cpp @@ -58,22 +58,24 @@ QString PartDynamicTextField::xmlName() const { } /** - * @brief PartDynamicTextField::startUserTransformation - * @param initial_selection_rect - * Start the user-induced transformation, provided this primitive is contained - * within the initial_selection_rect bounding rectangle. - */ + @brief PartDynamicTextField::startUserTransformation + @param initial_selection_rect + Start the user-induced transformation, + provided this primitive is contained + within the initial_selection_rect bounding rectangle. +*/ void PartDynamicTextField::startUserTransformation(const QRectF &initial_selection_rect) { Q_UNUSED(initial_selection_rect) m_saved_point = pos(); // scene coordinates, no need to mapFromScene() } /** - * @brief PartDynamicTextField::handleUserTransformation - * @param initial_selection_rect - * @param new_selection_rect - * Handle the user-induced transformation from initial_selection_rect to new_selection_rect - */ + @brief PartDynamicTextField::handleUserTransformation + @param initial_selection_rect + @param new_selection_rect + Handle the user-induced transformation + from initial_selection_rect to new_selection_rect +*/ void PartDynamicTextField::handleUserTransformation( const QRectF &initial_selection_rect, const QRectF &new_selection_rect) @@ -84,10 +86,10 @@ void PartDynamicTextField::handleUserTransformation( } /** - * @brief PartDynamicTextField::toXml - * @param document - * @return - */ + @brief PartDynamicTextField::toXml + @param document + @return +*/ const QDomElement PartDynamicTextField::toXml(QDomDocument &dom_doc) const { QDomElement root_element = dom_doc.createElement(xmlName()); @@ -147,9 +149,9 @@ const QDomElement PartDynamicTextField::toXml(QDomDocument &dom_doc) const { } /** - * @brief PartDynamicTextField::fromXml - * @param element - */ + @brief PartDynamicTextField::fromXml + @param element +*/ void PartDynamicTextField::fromXml(const QDomElement &dom_elmt) { if (dom_elmt.tagName() != xmlName()) { qDebug() << "PartDynamicTextField::fromXml : Wrong tagg name"; @@ -215,10 +217,11 @@ void PartDynamicTextField::fromXml(const QDomElement &dom_elmt) { } /** - * @brief PartDynamicTextField::fromTextFieldXml - * Setup this text from the xml definition of a text field (The xml tagg of a text field is "input"); - * @param dom_element - */ + @brief PartDynamicTextField::fromTextFieldXml + Setup this text from the xml definition + of a text field (The xml tagg of a text field is "input"); + @param dom_element +*/ void PartDynamicTextField::fromTextFieldXml(const QDomElement &dom_element) { if(dom_element.tagName() != "input") @@ -254,18 +257,18 @@ void PartDynamicTextField::fromTextFieldXml(const QDomElement &dom_element) } /** - * @brief PartDynamicTextField::textFrom - * @return what the final text is created from. - */ + @brief PartDynamicTextField::textFrom + @return what the final text is created from. +*/ DynamicElementTextItem::TextFrom PartDynamicTextField::textFrom() const { return m_text_from; } /** - * @brief PartDynamicTextField::setTextFrom - * Set the final text is created from. - * @param text_from - */ + @brief PartDynamicTextField::setTextFrom + Set the final text is created from. + @param text_from +*/ void PartDynamicTextField::setTextFrom(DynamicElementTextItem::TextFrom text_from) { m_text_from = text_from; switch (m_text_from) { @@ -285,18 +288,18 @@ void PartDynamicTextField::setTextFrom(DynamicElementTextItem::TextFrom text_fro } /** - * @brief PartDynamicTextField::text - * @return the text of this text - */ + @brief PartDynamicTextField::text + @return the text of this text +*/ QString PartDynamicTextField::text() const { return m_text; } /** - * @brief PartDynamicTextField::setText - * Set the text of this text - * @param text - */ + @brief PartDynamicTextField::setText + Set the text of this text + @param text +*/ void PartDynamicTextField::setText(const QString &text) { m_text = text; setPlainText(m_text); @@ -311,18 +314,18 @@ void PartDynamicTextField::setInfoName(const QString &info_name) { } /** - * @brief PartDynamicTextField::infoName - * @return the info name of this text - */ + @brief PartDynamicTextField::infoName + @return the info name of this text +*/ QString PartDynamicTextField::infoName() const{ return m_info_name; } /** - * @brief PartDynamicTextField::setCompositeText - * Set the composite text of this text item to @text - * @param text - */ + @brief PartDynamicTextField::setCompositeText + Set the composite text of this text item to @text + @param text +*/ void PartDynamicTextField::setCompositeText(const QString &text) { m_composite_text = text; if(m_text_from == DynamicElementTextItem::CompositeText && elementScene()) @@ -331,26 +334,26 @@ void PartDynamicTextField::setCompositeText(const QString &text) { } /** - * @brief PartDynamicTextField::compositeText - * @return the composite text of this text - */ + @brief PartDynamicTextField::compositeText + @return the composite text of this text +*/ QString PartDynamicTextField::compositeText() const { return m_composite_text; } /** - * @brief PartDynamicTextField::setColor - * @param color set text color to color - */ + @brief PartDynamicTextField::setColor + @param color set text color to color +*/ void PartDynamicTextField::setColor(const QColor& color) { setDefaultTextColor(color); emit colorChanged(color); } /** - * @brief PartDynamicTextField::color - * @return The color of this text - */ + @brief PartDynamicTextField::color + @return The color of this text +*/ QColor PartDynamicTextField::color() const { return defaultTextColor(); } @@ -415,9 +418,9 @@ void PartDynamicTextField::setFont(const QFont &font) { } /** - * @brief PartDynamicTextField::mouseMoveEvent - * @param event - */ + @brief PartDynamicTextField::mouseMoveEvent + @param event +*/ void PartDynamicTextField::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if((event -> buttons() & Qt::LeftButton) && (flags() & QGraphicsItem::ItemIsMovable)) { QPointF pos = event -> scenePos() + (m_origine_pos - event -> buttonDownScenePos(Qt::LeftButton)); @@ -428,9 +431,9 @@ void PartDynamicTextField::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief PartDynamicTextField::mousePressEvent - * @param event - */ + @brief PartDynamicTextField::mousePressEvent + @param event +*/ void PartDynamicTextField::mousePressEvent(QGraphicsSceneMouseEvent *event) { if(event -> button() == Qt::LeftButton) m_origine_pos = this -> pos(); @@ -439,9 +442,9 @@ void PartDynamicTextField::mousePressEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief PartDynamicTextField::mouseReleaseEvent - * @param event - */ + @brief PartDynamicTextField::mouseReleaseEvent + @param event +*/ void PartDynamicTextField::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if((event -> button() & Qt::LeftButton) && (flags() & QGraphicsItem::ItemIsMovable) && @@ -457,11 +460,11 @@ void PartDynamicTextField::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief PartDynamicTextField::itemChange - * @param change - * @param value - * @return - */ + @brief PartDynamicTextField::itemChange + @param change + @param value + @return +*/ QVariant PartDynamicTextField::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == QGraphicsItem::ItemPositionHasChanged || change == QGraphicsItem::ItemSceneHasChanged) { updateCurrentPartEditor(); @@ -525,9 +528,10 @@ void PartDynamicTextField::paint(QPainter *painter, const QStyleOptionGraphicsIt } /** - * @brief PartDynamicTextField::elementInfoChanged - * Used to up to date this text field, when the element information (see elementScene) changed - */ + @brief PartDynamicTextField::elementInfoChanged + Used to up to date this text field, + when the element information (see elementScene) changed +*/ void PartDynamicTextField::elementInfoChanged() { if(!elementScene()) return; diff --git a/sources/editor/graphicspart/partdynamictextfield.h b/sources/editor/graphicspart/partdynamictextfield.h index 509407e23..2ed40a123 100644 --- a/sources/editor/graphicspart/partdynamictextfield.h +++ b/sources/editor/graphicspart/partdynamictextfield.h @@ -23,12 +23,13 @@ #include "dynamicelementtextitem.h" /** - * @brief The PartDynamicTextField class - * This class represents an editable dynamic text field which may be used to compose the - * drawing of an electrical element within the element editor. - * The field will remain editable once the element is added onto - * a diagram - */ + @brief The PartDynamicTextField class + This class represents an editable dynamic text field + which may be used to compose the + drawing of an electrical element within the element editor. + The field will remain editable once the element is added onto + a diagram +*/ class PartDynamicTextField : public QGraphicsTextItem, public CustomElementPart { Q_OBJECT diff --git a/sources/editor/graphicspart/partellipse.cpp b/sources/editor/graphicspart/partellipse.cpp index c6fbdcba4..8e30f2636 100644 --- a/sources/editor/graphicspart/partellipse.cpp +++ b/sources/editor/graphicspart/partellipse.cpp @@ -22,20 +22,20 @@ #include "QetGraphicsItemModeler/qetgraphicshandlerutility.h" /** - * @brief PartEllipse::PartEllipse - * Constructor - * @param editor : QETElementEditor of this part - * @param parent : parent item - */ + @brief PartEllipse::PartEllipse + Constructor + @param editor : QETElementEditor of this part + @param parent : parent item +*/ PartEllipse::PartEllipse(QETElementEditor *editor, QGraphicsItem *parent) : AbstractPartEllipse(editor, parent), m_undo_command(nullptr) {} /** - * @brief PartEllipse::~PartEllipse - * Destructor - */ + @brief PartEllipse::~PartEllipse + Destructor +*/ PartEllipse::~PartEllipse() { if(m_undo_command) delete m_undo_command; @@ -43,12 +43,12 @@ PartEllipse::~PartEllipse() } /** - * @brief PartEllipse::paint - * Draw this ellpise - * @param painter - * @param options - * @param widget - */ + @brief PartEllipse::paint + Draw this ellpise + @param painter + @param options + @param widget +*/ void PartEllipse::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *widget) { Q_UNUSED(widget); @@ -71,11 +71,11 @@ void PartEllipse::paint(QPainter *painter, const QStyleOptionGraphicsItem *optio } /** - * @brief PartEllipse::toXml - * Export this ellipse in xml - * @param xml_document : Xml document to use for create the xml element. - * @return : an xml element that describe this ellipse - */ + @brief PartEllipse::toXml + Export this ellipse in xml + @param xml_document : Xml document to use for create the xml element. + @return : an xml element that describe this ellipse +*/ const QDomElement PartEllipse::toXml(QDomDocument &xml_document) const { QDomElement xml_element; @@ -101,10 +101,10 @@ const QDomElement PartEllipse::toXml(QDomDocument &xml_document) const } /** - * @brief PartEllipse::fromXml - * Import the properties of this ellipse from a xml element. - * @param qde : Xml document to use. - */ + @brief PartEllipse::fromXml + Import the properties of this ellipse from a xml element. + @param qde : Xml document to use. +*/ void PartEllipse::fromXml(const QDomElement &qde) { stylesFromXml(qde); @@ -124,9 +124,9 @@ void PartEllipse::fromXml(const QDomElement &qde) } /** - * @brief PartEllipse::shape - * @return the shape of this item - */ + @brief PartEllipse::shape + @return the shape of this item +*/ QPainterPath PartEllipse::shape() const { QPainterPath shape; @@ -151,10 +151,10 @@ QPainterPath PartEllipse::shadowShape() const } /** - * @brief PartEllipse::mouseReleaseEvent - * Handle mouse release event - * @param event - */ + @brief PartEllipse::mouseReleaseEvent + Handle mouse release event + @param event +*/ void PartEllipse::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton && event->buttonDownPos(Qt::LeftButton) == event->pos()) @@ -164,11 +164,11 @@ void PartEllipse::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief PartEllipse::itemChange - * @param change - * @param value - * @return - */ + @brief PartEllipse::itemChange + @param change + @param value + @return +*/ QVariant PartEllipse::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged && scene()) @@ -204,11 +204,11 @@ QVariant PartEllipse::itemChange(QGraphicsItem::GraphicsItemChange change, const } /** - * @brief PartEllipse::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief PartEllipse::sceneEventFilter + @param watched + @param event + @return +*/ bool PartEllipse::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -260,8 +260,8 @@ void PartEllipse::switchResizeMode() } /** - * @brief PartEllipse::adjusteHandlerPos - */ + @brief PartEllipse::adjusteHandlerPos +*/ void PartEllipse::adjusteHandlerPos() { if (m_handler_vector.isEmpty()) @@ -278,10 +278,10 @@ void PartEllipse::adjusteHandlerPos() } /** - * @brief PartEllipse::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief PartEllipse::handlerMousePressEvent + @param qghi + @param event +*/ void PartEllipse::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -294,10 +294,10 @@ void PartEllipse::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphics } /** - * @brief PartEllipse::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief PartEllipse::handlerMouseMoveEvent + @param qghi + @param event +*/ void PartEllipse::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -316,10 +316,10 @@ void PartEllipse::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsS } /** - * @brief PartEllipse::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief PartEllipse::handlerMouseReleaseEvent + @param qghi + @param event +*/ void PartEllipse::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -332,9 +332,9 @@ void PartEllipse::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphi } /** - * @brief PartEllipse::sceneSelectionChanged - * When the scene selection change, if there are several primitive selected, we remove the handler of this item - */ + @brief PartEllipse::sceneSelectionChanged + When the scene selection change, if there are several primitive selected, we remove the handler of this item +*/ void PartEllipse::sceneSelectionChanged() { if (this->isSelected() && scene()->selectedItems().size() == 1) @@ -344,9 +344,9 @@ void PartEllipse::sceneSelectionChanged() } /** - * @brief PartEllipse::addHandler - * Add handlers for this item - */ + @brief PartEllipse::addHandler + Add handlers for this item +*/ void PartEllipse::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -368,9 +368,9 @@ void PartEllipse::addHandler() } /** - * @brief PartEllipse::removeHandler - * Remove the handlers of this item - */ + @brief PartEllipse::removeHandler + Remove the handlers of this item +*/ void PartEllipse::removeHandler() { if (!m_handler_vector.isEmpty()) diff --git a/sources/editor/graphicspart/partellipse.h b/sources/editor/graphicspart/partellipse.h index b7f42dcf7..477db5111 100644 --- a/sources/editor/graphicspart/partellipse.h +++ b/sources/editor/graphicspart/partellipse.h @@ -23,10 +23,10 @@ class QPropertyUndoCommand; /** - * @brief The PartEllipse class - * This class represents an ellipse primitive which may be used to compose the - * drawing of an electrical element within the element editor. - */ + @brief The PartEllipse class + This class represents an ellipse primitive which may be used to compose the + drawing of an electrical element within the element editor. +*/ class PartEllipse : public AbstractPartEllipse { Q_OBJECT @@ -43,9 +43,9 @@ class PartEllipse : public AbstractPartEllipse public: enum { Type = UserType + 1103 }; /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartEllipse. - * @return the QGraphicsItem type - */ + Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartEllipse. + @return the QGraphicsItem type + */ int type() const override { return Type; } void paint(QPainter *, const QStyleOptionGraphicsItem *, QWidget * = nullptr) override; diff --git a/sources/editor/graphicspart/partline.cpp b/sources/editor/graphicspart/partline.cpp index fc6d0746e..c6cd22339 100644 --- a/sources/editor/graphicspart/partline.cpp +++ b/sources/editor/graphicspart/partline.cpp @@ -23,11 +23,11 @@ /** - * @brief PartLine::PartLine - * Constructor - * @param editor : QETElementEditor of this part - * @param parent : parent item - */ + @brief PartLine::PartLine + Constructor + @param editor : QETElementEditor of this part + @param parent : parent item +*/ PartLine::PartLine(QETElementEditor *editor, QGraphicsItem *parent) : CustomElementGraphicPart(editor, parent), first_end(Qet::None), @@ -47,10 +47,10 @@ PartLine::~PartLine() } /** - * @brief PartLine::requiredLengthForEndType - * @param end_type - * @return the number of "length" needed to draw a extremity of type Qet::EndType. - */ + @brief PartLine::requiredLengthForEndType + @param end_type + @return the number of "length" needed to draw a extremity of type Qet::EndType. +*/ uint PartLine::requiredLengthForEndType(const Qet::EndType &end_type) { uint length_count_required = 0; @@ -64,12 +64,12 @@ uint PartLine::requiredLengthForEndType(const Qet::EndType &end_type) } /** - * @brief PartLine::paint - * Draw this line - * @param painter - * @param options - * @param widget - */ + @brief PartLine::paint + Draw this line + @param painter + @param options + @param widget +*/ void PartLine::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *widget) { Q_UNUSED(widget); @@ -97,11 +97,11 @@ void PartLine::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, } /** - * @brief PartLine::toXml - * Export this line in xml - * @param xml_document : Xml document to use for create the xml element. - * @return an xml element that describe this line - */ + @brief PartLine::toXml + Export this line in xml + @param xml_document : Xml document to use for create the xml element. + @return an xml element that describe this line +*/ const QDomElement PartLine::toXml(QDomDocument &xml_document) const { QPointF p1(sceneP1()); @@ -122,10 +122,10 @@ const QDomElement PartLine::toXml(QDomDocument &xml_document) const } /** - * @brief PartLine::fromXml - * Import the properties of this line from a xml element. - * @param qde : Xml document to use - */ + @brief PartLine::fromXml + Import the properties of this line from a xml element. + @param qde : Xml document to use +*/ void PartLine::fromXml(const QDomElement &qde) { stylesFromXml(qde); m_line = QLineF(mapFromScene(qde.attribute("x1", "0").toDouble(), @@ -140,11 +140,11 @@ void PartLine::fromXml(const QDomElement &qde) { } /** - * @brief PartLine::itemChange - * @param change - * @param value - * @return - */ + @brief PartLine::itemChange + @param change + @param value + @return +*/ QVariant PartLine::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged && scene()) @@ -180,11 +180,11 @@ QVariant PartLine::itemChange(QGraphicsItem::GraphicsItemChange change, const QV } /** - * @brief PartLine::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief PartLine::sceneEventFilter + @param watched + @param event + @return +*/ bool PartLine::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -220,9 +220,9 @@ bool PartLine::sceneEventFilter(QGraphicsItem *watched, QEvent *event) } /** - * @brief PartLine::adjusteHandlerPos - * Adjust the position of the handler item - */ + @brief PartLine::adjusteHandlerPos + Adjust the position of the handler item +*/ void PartLine::adjusteHandlerPos() { if(m_handler_vector.isEmpty()) @@ -240,10 +240,10 @@ void PartLine::adjusteHandlerPos() } /** - * @brief PartLine::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief PartLine::handlerMousePressEvent + @param qghi + @param event +*/ void PartLine::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -256,10 +256,10 @@ void PartLine::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSce } /** - * @brief PartLine::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief PartLine::handlerMouseMoveEvent + @param qghi + @param event +*/ void PartLine::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -279,10 +279,10 @@ void PartLine::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsScen } /** - * @brief PartLine::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief PartLine::handlerMouseReleaseEvent + @param qghi + @param event +*/ void PartLine::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -295,9 +295,9 @@ void PartLine::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsS } /** - * @brief PartLine::sceneSelectionChanged - * When the scene selection change, if there are several primitive selected, we remove the handler of this item - */ + @brief PartLine::sceneSelectionChanged + When the scene selection change, if there are several primitive selected, we remove the handler of this item +*/ void PartLine::sceneSelectionChanged() { if (this->isSelected() && scene()->selectedItems().size() == 1) @@ -307,9 +307,9 @@ void PartLine::sceneSelectionChanged() } /** - * @brief PartLine::addHandler - * Add handlers for this item - */ + @brief PartLine::addHandler + Add handlers for this item +*/ void PartLine::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -330,9 +330,9 @@ void PartLine::addHandler() } /** - * @brief PartLine::removeHandler - * Remove the handlers of this item - */ + @brief PartLine::removeHandler + Remove the handlers of this item +*/ void PartLine::removeHandler() { if (!m_handler_vector.isEmpty()) @@ -343,25 +343,25 @@ void PartLine::removeHandler() } /** - * @brief PartLine::sceneP1 - * @return the point p1 in scene coordinate - */ + @brief PartLine::sceneP1 + @return the point p1 in scene coordinate +*/ QPointF PartLine::sceneP1() const { return(mapToScene(m_line.p1())); } /** - * @brief PartLine::sceneP2 - * @return the point p2 in scen coordinate - */ + @brief PartLine::sceneP2 + @return the point p2 in scen coordinate +*/ QPointF PartLine::sceneP2() const { return(mapToScene(m_line.p2())); } /** - * @brief PartLine::shape - * @return the shape of this item - */ + @brief PartLine::shape + @return the shape of this item +*/ QPainterPath PartLine::shape() const { QPainterPath shape; @@ -404,10 +404,10 @@ QPainterPath PartLine::shadowShape() const } /** - * @brief PartLine::fourShapePoints - * @return a list with the two points that delimite the line - * + the four points surrounding these two points - */ + @brief PartLine::fourShapePoints + @return a list with the two points that delimite the line + + the four points surrounding these two points +*/ QList PartLine::fourShapePoints() const { const qreal marge = 2.0; @@ -452,9 +452,9 @@ QList PartLine::fourShapePoints() const } /** - * @brief PartLine::firstEndCircleRect - * @return the rectangle bordering the entirety of the first extremity - */ + @brief PartLine::firstEndCircleRect + @return the rectangle bordering the entirety of the first extremity +*/ QRectF PartLine::firstEndCircleRect() const { QList interesting_points = fourEndPoints(m_line.p1(), @@ -470,9 +470,9 @@ QRectF PartLine::firstEndCircleRect() const } /** - * @brief PartLine::secondEndCircleRect - * @return the rectangle bordering the entirety of the second extremity - */ + @brief PartLine::secondEndCircleRect + @return the rectangle bordering the entirety of the second extremity +*/ QRectF PartLine::secondEndCircleRect() const { QList interesting_points = fourEndPoints(m_line.p2(), m_line.p1(), @@ -487,13 +487,13 @@ QRectF PartLine::secondEndCircleRect() const { } /** - * @brief PartLine::debugPaint - * Display several composante of the drawing - * -the bounding rect - * -special points at each extremity - * -the quadrature of the circle at each extremity, even if itself is an other type - * @param painter - */ + @brief PartLine::debugPaint + Display several composante of the drawing + -the bounding rect + -special points at each extremity + -the quadrature of the circle at each extremity, even if itself is an other type + @param painter +*/ void PartLine::debugPaint(QPainter *painter) { painter -> save(); @@ -516,9 +516,9 @@ void PartLine::debugPaint(QPainter *painter) } /** - * @brief PartLine::boundingRect - * @return the bounding rect of this part - */ + @brief PartLine::boundingRect + @return the bounding rect of this part +*/ QRectF PartLine::boundingRect() const { QRectF bound; @@ -539,31 +539,31 @@ QRectF PartLine::boundingRect() const } /** - * @brief PartLine::isUseless - * @return true if this part is irrelevant and does not deserve to be Retained / registered. - * A line is relevant when is two point is different - */ + @brief PartLine::isUseless + @return true if this part is irrelevant and does not deserve to be Retained / registered. + A line is relevant when is two point is different +*/ bool PartLine::isUseless() const { return(m_line.p1() == m_line.p2()); } /** - * @brief PartLine::sceneGeometricRect - * @return the minimum, margin-less rectangle this part can fit into, in scene - * coordinates. It is different from boundingRect() because it is not supposed - * to imply any margin, and it is different from shape because it is a regular - * rectangle, not a complex shape. - */ + @brief PartLine::sceneGeometricRect + @return the minimum, margin-less rectangle this part can fit into, in scene + coordinates. It is different from boundingRect() because it is not supposed + to imply any margin, and it is different from shape because it is a regular + rectangle, not a complex shape. +*/ QRectF PartLine::sceneGeometricRect() const { return(QRectF(sceneP1(), sceneP2())); } /** - * @brief PartLine::startUserTransformation - * Start the user-induced transformation, provided this primitive is contained - * within the \a initial_selection_rect bounding rectangle. - * @param initial_selection_rect - */ + @brief PartLine::startUserTransformation + Start the user-induced transformation, provided this primitive is contained + within the \a initial_selection_rect bounding rectangle. + @param initial_selection_rect +*/ void PartLine::startUserTransformation(const QRectF &initial_selection_rect) { Q_UNUSED(initial_selection_rect) @@ -572,11 +572,11 @@ void PartLine::startUserTransformation(const QRectF &initial_selection_rect) } /** - * @brief PartLine::handleUserTransformation - * Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect - * @param initial_selection_rect - * @param new_selection_rect - */ + @brief PartLine::handleUserTransformation + Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect + @param initial_selection_rect + @param new_selection_rect +*/ void PartLine::handleUserTransformation(const QRectF &initial_selection_rect, const QRectF &new_selection_rect) { QList mapped_points = mapPoints(initial_selection_rect, new_selection_rect, saved_points_); @@ -585,19 +585,19 @@ void PartLine::handleUserTransformation(const QRectF &initial_selection_rect, co } /** - * @brief PartLine::fourEndPoints - * Return the four interesting point needed to draw the shape - * at extremity of line (circle, diamond, arrow, triangle) - * This points are in order : + @brief PartLine::fourEndPoints + Return the four interesting point needed to draw the shape + at extremity of line (circle, diamond, arrow, triangle) + This points are in order : * O : point on the line, at a distance 'length' of the extremity * A : point on the line at a 'length' of 2x the extremity length * B : point at a distance of length O - O is the projection of B on the line * C : point at a distance of length O - O is the projection of C on the line - * @param end_point : The concerned extremity - * @param other_point : other needed point to define the line - * @param length : length to use between the extremity and the point O - * @return - */ + @param end_point : The concerned extremity + @param other_point : other needed point to define the line + @param length : length to use between the extremity and the point O + @return +*/ QList PartLine::fourEndPoints(const QPointF &end_point, const QPointF &other_point, const qreal &length) { //Vector and length of the line @@ -665,12 +665,12 @@ void PartLine::setSecondEndLength(const qreal &l) } /** - * @brief PartLine::path - * @return this line has a QPainterPath. - * It's notably use when this line have an end type (circle, triangle etc....), - * because return a QPainterPath with end already draw. - * Else if there isn't an end type get P1 and P2 of line is better (faster). - */ + @brief PartLine::path + @return this line has a QPainterPath. + It's notably use when this line have an end type (circle, triangle etc....), + because return a QPainterPath with end already draw. + Else if there isn't an end type get P1 and P2 of line is better (faster). +*/ QPainterPath PartLine::path() const { QPainterPath path; diff --git a/sources/editor/graphicspart/partline.h b/sources/editor/graphicspart/partline.h index 9c2d858d7..148599ed1 100644 --- a/sources/editor/graphicspart/partline.h +++ b/sources/editor/graphicspart/partline.h @@ -63,9 +63,9 @@ class PartLine : public CustomElementGraphicPart enum { Type = UserType + 1104 }; /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartLine. - * @return the QGraphicsItem type - */ + Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartLine. + @return the QGraphicsItem type + */ int type() const override { return Type; } void paint(QPainter *, const QStyleOptionGraphicsItem *, QWidget * = nullptr) override; QString name() const override { return(QObject::tr("ligne", "element part name")); } diff --git a/sources/editor/graphicspart/partpolygon.cpp b/sources/editor/graphicspart/partpolygon.cpp index 4767337ca..70afc569a 100644 --- a/sources/editor/graphicspart/partpolygon.cpp +++ b/sources/editor/graphicspart/partpolygon.cpp @@ -25,11 +25,11 @@ /** - * @brief PartPolygon::PartPolygon - * Constructor - * @param editor : editor of this item - * @param parent : parent item - */ + @brief PartPolygon::PartPolygon + Constructor + @param editor : editor of this item + @param parent : parent item +*/ PartPolygon::PartPolygon(QETElementEditor *editor, QGraphicsItem *parent) : CustomElementGraphicPart(editor, parent), m_closed(false), @@ -44,8 +44,8 @@ PartPolygon::PartPolygon(QETElementEditor *editor, QGraphicsItem *parent) : } /** - * @brief PartPolygon::~PartPolygon - */ + @brief PartPolygon::~PartPolygon +*/ PartPolygon::~PartPolygon() { if(m_undo_command) delete m_undo_command; @@ -53,12 +53,12 @@ PartPolygon::~PartPolygon() } /** - * @brief PartPolygon::paint - * Draw this polygon - * @param painter - * @param options - * @param widget - */ + @brief PartPolygon::paint + Draw this polygon + @param painter + @param options + @param widget +*/ void PartPolygon::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *widget) { Q_UNUSED(widget); @@ -78,10 +78,10 @@ void PartPolygon::paint(QPainter *painter, const QStyleOptionGraphicsItem *optio } /** - * @brief PartPolygon::fromXml - * Import the properties of this polygon from a xml element - * @param qde : Xml document to use - */ + @brief PartPolygon::fromXml + Import the properties of this polygon from a xml element + @param qde : Xml document to use +*/ void PartPolygon::fromXml(const QDomElement &qde) { stylesFromXml(qde); @@ -108,11 +108,11 @@ void PartPolygon::fromXml(const QDomElement &qde) } /** - * @brief PartPolygon::toXml - * Export this polygin in xml - * @param xml_document : Xml document to use for create the xml element - * @return an xml element that describe this polygon - */ + @brief PartPolygon::toXml + Export this polygin in xml + @param xml_document : Xml document to use for create the xml element + @return an xml element that describe this polygon +*/ const QDomElement PartPolygon::toXml(QDomDocument &xml_document) const { QDomElement xml_element = xml_document.createElement("polygon"); @@ -129,10 +129,10 @@ const QDomElement PartPolygon::toXml(QDomDocument &xml_document) const } /** - * @brief PartPolygon::isUseless - * @return true if this part is irrelevant and does not deserve to be Retained / registered. - * A polygon is relevant when he have 2 differents points - */ + @brief PartPolygon::isUseless + @return true if this part is irrelevant and does not deserve to be Retained / registered. + A polygon is relevant when he have 2 differents points +*/ bool PartPolygon::isUseless() const { if (m_polygon.count() < 2) return(true); @@ -144,22 +144,22 @@ bool PartPolygon::isUseless() const } /** - * @brief PartPolygon::sceneGeometricRect - * @return the minimum, margin-less rectangle this part can fit into, in scene - * coordinates. It is different from boundingRect() because it is not supposed - * to imply any margin, and it is different from shape because it is a regular - * rectangle, not a complex shape. - */ + @brief PartPolygon::sceneGeometricRect + @return the minimum, margin-less rectangle this part can fit into, in scene + coordinates. It is different from boundingRect() because it is not supposed + to imply any margin, and it is different from shape because it is a regular + rectangle, not a complex shape. +*/ QRectF PartPolygon::sceneGeometricRect() const { return(mapToScene(m_polygon.boundingRect()).boundingRect()); } /** - * @brief PartPolygon::startUserTransformation - * Start the user-induced transformation, provided this primitive is contained - * within the initial_selection_rect bounding rectangle. - * @param initial_selection_rect - */ + @brief PartPolygon::startUserTransformation + Start the user-induced transformation, provided this primitive is contained + within the initial_selection_rect bounding rectangle. + @param initial_selection_rect +*/ void PartPolygon::startUserTransformation(const QRectF &initial_selection_rect) { Q_UNUSED(initial_selection_rect) @@ -167,11 +167,11 @@ void PartPolygon::startUserTransformation(const QRectF &initial_selection_rect) } /** - * @brief PartPolygon::handleUserTransformation - * Handle the user-induced transformation from initial_selection_rect to new_selection_rect - * @param initial_selection_rect - * @param new_selection_rect - */ + @brief PartPolygon::handleUserTransformation + Handle the user-induced transformation from initial_selection_rect to new_selection_rect + @param initial_selection_rect + @param new_selection_rect +*/ void PartPolygon::handleUserTransformation(const QRectF &initial_selection_rect, const QRectF &new_selection_rect) { QList mapped_points = mapPoints(initial_selection_rect, new_selection_rect, saved_points_); @@ -179,29 +179,29 @@ void PartPolygon::handleUserTransformation(const QRectF &initial_selection_rect, } /** - * @brief PartPolygon::preferredScalingMethod - * This method is called by the decorator when it needs to determine the best - * way to interactively scale a primitive. It is typically called when only a - * single primitive is being scaled. - * @return : This reimplementation systematically returns QET::RoundScaleRatios. - */ + @brief PartPolygon::preferredScalingMethod + This method is called by the decorator when it needs to determine the best + way to interactively scale a primitive. It is typically called when only a + single primitive is being scaled. + @return : This reimplementation systematically returns QET::RoundScaleRatios. +*/ QET::ScalingMethod PartPolygon::preferredScalingMethod() const { return(QET::RoundScaleRatios); } /** - * @brief PartPolygon::polygon - * @return the item's polygon, or an empty polygon if no polygon has been set. - */ + @brief PartPolygon::polygon + @return the item's polygon, or an empty polygon if no polygon has been set. +*/ QPolygonF PartPolygon::polygon() const { return m_polygon; } /** - * @brief PartPolygon::setPolygon - * Sets the item's polygon to be the given polygon. - * @param polygon - */ + @brief PartPolygon::setPolygon + Sets the item's polygon to be the given polygon. + @param polygon +*/ void PartPolygon::setPolygon(const QPolygonF &polygon) { if (m_polygon == polygon) return; @@ -212,10 +212,10 @@ void PartPolygon::setPolygon(const QPolygonF &polygon) } /** - * @brief PartPolygon::addPoint - * Add new point to polygon - * @param point - */ + @brief PartPolygon::addPoint + Add new point to polygon + @param point +*/ void PartPolygon::addPoint(const QPointF &point) { prepareGeometryChange(); @@ -223,10 +223,10 @@ void PartPolygon::addPoint(const QPointF &point) } /** - * @brief PartPolygon::setLastPoint - * Set the last point of polygon to @point - * @param point - */ + @brief PartPolygon::setLastPoint + Set the last point of polygon to @point + @param point +*/ void PartPolygon::setLastPoint(const QPointF &point) { if (m_polygon.size()) @@ -237,9 +237,9 @@ void PartPolygon::setLastPoint(const QPointF &point) } /** - * @brief PartPolygon::removeLastPoint - * Remove the last point of polygon - */ + @brief PartPolygon::removeLastPoint + Remove the last point of polygon +*/ void PartPolygon::removeLastPoint() { if (m_polygon.size()) @@ -258,11 +258,11 @@ void PartPolygon::setClosed(bool close) } /** - * @brief PartPolygon::setHandlerColor - * Set the handler at pos @pos (in polygon coordinate) to color @color. - * @param pos - * @param color - */ + @brief PartPolygon::setHandlerColor + Set the handler at pos @pos (in polygon coordinate) to color @color. + @param pos + @param color +*/ void PartPolygon::setHandlerColor(QPointF pos, const QColor &color) { for (QetGraphicsHandlerItem *qghi : m_handler_vector) { @@ -273,8 +273,8 @@ void PartPolygon::setHandlerColor(QPointF pos, const QColor &color) } /** - * @brief PartPolygon::resetAllHandlerColor - * Reset the color of every handlers + @brief PartPolygon::resetAllHandlerColor + Reset the color of every handlers */ void PartPolygon::resetAllHandlerColor() { @@ -284,11 +284,11 @@ void PartPolygon::resetAllHandlerColor() } /** - * @brief PartPolygon::itemChange - * @param change - * @param value - * @return - */ + @brief PartPolygon::itemChange + @param change + @param value + @return +*/ QVariant PartPolygon::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged && scene()) @@ -324,11 +324,11 @@ QVariant PartPolygon::itemChange(QGraphicsItem::GraphicsItemChange change, const } /** - * @brief PartPolygon::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief PartPolygon::sceneEventFilter + @param watched + @param event + @return +*/ bool PartPolygon::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -388,8 +388,8 @@ void PartPolygon::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) } /** - * @brief PartPolygon::adjusteHandlerPos - */ + @brief PartPolygon::adjusteHandlerPos +*/ void PartPolygon::adjusteHandlerPos() { if(m_handler_vector.isEmpty()) @@ -410,10 +410,10 @@ void PartPolygon::adjusteHandlerPos() } /** - * @brief PartPolygon::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief PartPolygon::handlerMousePressEvent + @param qghi + @param event +*/ void PartPolygon::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -424,10 +424,10 @@ void PartPolygon::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphics } /** - * @brief PartPolygon::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief PartPolygon::handlerMouseMoveEvent + @param qghi + @param event +*/ void PartPolygon::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -444,10 +444,10 @@ void PartPolygon::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsS } /** - * @brief PartPolygon::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief PartPolygon::handlerMouseReleaseEvent + @param qghi + @param event +*/ void PartPolygon::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -460,9 +460,9 @@ void PartPolygon::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphi } /** - * @brief PartPolygon::sceneSelectionChanged - * When the scene selection change, if there are several primitive selected, we remove the handler of this item - */ + @brief PartPolygon::sceneSelectionChanged + When the scene selection change, if there are several primitive selected, we remove the handler of this item +*/ void PartPolygon::sceneSelectionChanged() { if (this->isSelected() && scene()->selectedItems().size() == 1) @@ -472,9 +472,9 @@ void PartPolygon::sceneSelectionChanged() } /** - * @brief PartPolygon::addHandler - * Add handlers for this item - */ + @brief PartPolygon::addHandler + Add handlers for this item +*/ void PartPolygon::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -492,9 +492,9 @@ void PartPolygon::addHandler() } /** - * @brief PartPolygon::removeHandler - * Remove the handlers of this item - */ + @brief PartPolygon::removeHandler + Remove the handlers of this item +*/ void PartPolygon::removeHandler() { if (!m_handler_vector.isEmpty()) @@ -505,9 +505,9 @@ void PartPolygon::removeHandler() } /** - * @brief PartPolygon::insertPoint - * Insert a point in this polygone - */ + @brief PartPolygon::insertPoint + Insert a point in this polygone +*/ void PartPolygon::insertPoint() { QPolygonF new_polygon = QetGraphicsHandlerUtility::polygonForInsertPoint(m_polygon, m_closed, elementScene()->snapToGrid(m_context_menu_pos)); @@ -522,9 +522,9 @@ void PartPolygon::insertPoint() } /** - * @brief PartPolygon::removePoint - * remove a point on this polygon - */ + @brief PartPolygon::removePoint + remove a point on this polygon +*/ void PartPolygon::removePoint() { if (m_handler_vector.size() == 2) @@ -556,9 +556,9 @@ void PartPolygon::removePoint() } /** - * @brief PartPolygon::shape - * @return the shape of this item - */ + @brief PartPolygon::shape + @return the shape of this item +*/ QPainterPath PartPolygon::shape() const { QPainterPath shape; @@ -589,9 +589,9 @@ QPainterPath PartPolygon::shadowShape() const } /** - * @brief PartPolygon::boundingRect - * @return the bounding rect of this item - */ + @brief PartPolygon::boundingRect + @return the bounding rect of this item +*/ QRectF PartPolygon::boundingRect() const { QRectF r = m_polygon.boundingRect(); diff --git a/sources/editor/graphicspart/partpolygon.h b/sources/editor/graphicspart/partpolygon.h index e10eadff1..4a7891459 100644 --- a/sources/editor/graphicspart/partpolygon.h +++ b/sources/editor/graphicspart/partpolygon.h @@ -26,10 +26,10 @@ class QetGraphicsHandlerItem; class QAction; /** - * @brief The PartPolygon class - * This class represents a polygon primitive which may be used to compose the - * drawing of an electrical element within the element editor. - */ + @brief The PartPolygon class + This class represents a polygon primitive which may be used to compose the + drawing of an electrical element within the element editor. +*/ class PartPolygon : public CustomElementGraphicPart { Q_OBJECT diff --git a/sources/editor/graphicspart/partrectangle.cpp b/sources/editor/graphicspart/partrectangle.cpp index 5f17b7252..152bf659f 100644 --- a/sources/editor/graphicspart/partrectangle.cpp +++ b/sources/editor/graphicspart/partrectangle.cpp @@ -22,29 +22,29 @@ #include "QetGraphicsItemModeler/qetgraphicshandlerutility.h" /** - * @brief PartRectangle::PartRectangle - * Constructor - * @param editor the QETElementEditor of this item - * @param parent parent item - */ + @brief PartRectangle::PartRectangle + Constructor + @param editor the QETElementEditor of this item + @param parent parent item +*/ PartRectangle::PartRectangle(QETElementEditor *editor, QGraphicsItem *parent) : CustomElementGraphicPart(editor, parent) {} /** - * @brief PartRectangle::~PartRectangle - */ + @brief PartRectangle::~PartRectangle +*/ PartRectangle::~PartRectangle() { removeHandler(); } /** - * @brief PartRectangle::paint - * Draw this Rectangle - * @param painter - * @param options - * @param widget - */ + @brief PartRectangle::paint + Draw this Rectangle + @param painter + @param options + @param widget +*/ void PartRectangle::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *widget) { Q_UNUSED(widget); @@ -72,11 +72,11 @@ void PartRectangle::paint(QPainter *painter, const QStyleOptionGraphicsItem *opt } /** - * @brief PartRectangle::toXml - * Export this rectangle in xml - * @param xml_document : Xml document to use for create the xml element. - * @return an xml element that describe this ellipse - */ + @brief PartRectangle::toXml + Export this rectangle in xml + @param xml_document : Xml document to use for create the xml element. + @return an xml element that describe this ellipse +*/ const QDomElement PartRectangle::toXml(QDomDocument &xml_document) const { QDomElement xml_element = xml_document.createElement("rect"); @@ -104,10 +104,10 @@ const QDomElement PartRectangle::toXml(QDomDocument &xml_document) const } /** - * @brief PartRectangle::fromXml - * Import the properties of this rectangle from a xml element. - * @param qde : Xml document to use. - */ + @brief PartRectangle::fromXml + Import the properties of this rectangle from a xml element. + @param qde : Xml document to use. +*/ void PartRectangle::fromXml(const QDomElement &qde) { stylesFromXml(qde); @@ -123,18 +123,18 @@ void PartRectangle::fromXml(const QDomElement &qde) } /** - * @brief PartRectangle::rect - * @return : Returns the item's rectangle. - */ + @brief PartRectangle::rect + @return : Returns the item's rectangle. +*/ QRectF PartRectangle::rect() const { return m_rect; } /** - * @brief PartRectangle::setRect - * Sets the item's rectangle to be the given rectangle. - * @param rect - */ + @brief PartRectangle::setRect + Sets the item's rectangle to be the given rectangle. + @param rect +*/ void PartRectangle::setRect(const QRectF &rect) { if (rect == m_rect) return; @@ -161,28 +161,28 @@ void PartRectangle::setYRadius(qreal Y) } /** - * @brief PartRectangle::sceneGeometricRect - * @return the minimum, margin-less rectangle this part can fit into, in scene - * coordinates. It is different from boundingRect() because it is not supposed - * to imply any margin, and it is different from shape because it is a regular - * rectangle, not a complex shape. - */ + @brief PartRectangle::sceneGeometricRect + @return the minimum, margin-less rectangle this part can fit into, in scene + coordinates. It is different from boundingRect() because it is not supposed + to imply any margin, and it is different from shape because it is a regular + rectangle, not a complex shape. +*/ QRectF PartRectangle::sceneGeometricRect() const { return(mapToScene(rect()).boundingRect()); } /** - * @brief PartRectangle::sceneTopLeft - * @return the top left of rectangle, in scene coordinate - */ + @brief PartRectangle::sceneTopLeft + @return the top left of rectangle, in scene coordinate +*/ QPointF PartRectangle::sceneTopLeft() const { return(mapToScene(rect().topLeft())); } /** - * @brief PartRectangle::shape - * @return the shape of this item - */ + @brief PartRectangle::shape + @return the shape of this item +*/ QPainterPath PartRectangle::shape() const { QPainterPath shape; @@ -207,9 +207,9 @@ QPainterPath PartRectangle::shadowShape() const } /** - * @brief PartRectangle::boundingRect - * @return Bounding rectangle this part can fit into - */ + @brief PartRectangle::boundingRect + @return Bounding rectangle this part can fit into +*/ QRectF PartRectangle::boundingRect() const { qreal adjust = (SHADOWS_HEIGHT + penWeight()) / 2; @@ -224,20 +224,20 @@ QRectF PartRectangle::boundingRect() const } /** - * @brief PartRectangle::isUseless - * @return true if this part is irrelevant and does not deserve to be Retained / registered. - * An rectangle is relevant when he's not null. - */ + @brief PartRectangle::isUseless + @return true if this part is irrelevant and does not deserve to be Retained / registered. + An rectangle is relevant when he's not null. +*/ bool PartRectangle::isUseless() const { return(rect().isNull()); } /** - * @brief PartRectangle::startUserTransformation - * Start the user-induced transformation, provided this primitive is contained - * within the initial_selection_rect bounding rectangle. - * @param initial_selection_rect - */ + @brief PartRectangle::startUserTransformation + Start the user-induced transformation, provided this primitive is contained + within the initial_selection_rect bounding rectangle. + @param initial_selection_rect +*/ void PartRectangle::startUserTransformation(const QRectF &initial_selection_rect) { Q_UNUSED(initial_selection_rect) @@ -247,11 +247,11 @@ void PartRectangle::startUserTransformation(const QRectF &initial_selection_rect } /** - * @brief PartRectangle::handleUserTransformation - * Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect - * @param initial_selection_rect - * @param new_selection_rect - */ + @brief PartRectangle::handleUserTransformation + Handle the user-induced transformation from \a initial_selection_rect to \a new_selection_rect + @param initial_selection_rect + @param new_selection_rect +*/ void PartRectangle::handleUserTransformation(const QRectF &initial_selection_rect, const QRectF &new_selection_rect) { QList mapped_points = mapPoints(initial_selection_rect, new_selection_rect, saved_points_); @@ -259,10 +259,10 @@ void PartRectangle::handleUserTransformation(const QRectF &initial_selection_rec } /** - * @brief PartRectangle::mouseReleaseEvent - * Handle mouse release event - * @param event - */ + @brief PartRectangle::mouseReleaseEvent + Handle mouse release event + @param event +*/ void PartRectangle::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton && event->buttonDownPos(Qt::LeftButton) == event->pos()) @@ -272,11 +272,11 @@ void PartRectangle::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief PartRectangle::itemChange - * @param change - * @param value - * @return - */ + @brief PartRectangle::itemChange + @param change + @param value + @return +*/ QVariant PartRectangle::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged && scene()) @@ -312,11 +312,11 @@ QVariant PartRectangle::itemChange(QGraphicsItem::GraphicsItemChange change, con } /** - * @brief PartRectangle::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief PartRectangle::sceneEventFilter + @param watched + @param event + @return +*/ bool PartRectangle::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -352,8 +352,8 @@ bool PartRectangle::sceneEventFilter(QGraphicsItem *watched, QEvent *event) } /** - * @brief PartRectangle::switchResizeMode - */ + @brief PartRectangle::switchResizeMode +*/ void PartRectangle::switchResizeMode() { if (m_resize_mode == 1) @@ -385,8 +385,8 @@ void PartRectangle::switchResizeMode() } /** - * @brief PartRectangle::adjusteHandlerPos - */ + @brief PartRectangle::adjusteHandlerPos +*/ void PartRectangle::adjusteHandlerPos() { if (m_handler_vector.isEmpty()) { @@ -417,10 +417,10 @@ void PartRectangle::adjusteHandlerPos() } /** - * @brief PartRectangle::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief PartRectangle::handlerMousePressEvent + @param qghi + @param event +*/ void PartRectangle::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi) @@ -435,10 +435,10 @@ void PartRectangle::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphi } /** - * @brief PartRectangle::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief PartRectangle::handlerMouseMoveEvent + @param qghi + @param event +*/ void PartRectangle::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi) @@ -496,9 +496,9 @@ void PartRectangle::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGrap } /** - * @brief PartRectangle::sceneSelectionChanged - * When the scene selection change, if there are several primitive selected, we remove the handler of this item - */ + @brief PartRectangle::sceneSelectionChanged + When the scene selection change, if there are several primitive selected, we remove the handler of this item +*/ void PartRectangle::sceneSelectionChanged() { if (this->isSelected() && scene()->selectedItems().size() == 1) @@ -508,9 +508,9 @@ void PartRectangle::sceneSelectionChanged() } /** - * @brief PartRectangle::addHandler - * Add handlers for this item - */ + @brief PartRectangle::addHandler + Add handlers for this item +*/ void PartRectangle::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -538,9 +538,9 @@ void PartRectangle::addHandler() } /** - * @brief PartRectangle::removeHandler - * Remove the handlers of this item - */ + @brief PartRectangle::removeHandler + Remove the handlers of this item +*/ void PartRectangle::removeHandler() { if (!m_handler_vector.isEmpty()) diff --git a/sources/editor/graphicspart/partrectangle.h b/sources/editor/graphicspart/partrectangle.h index d6d7a6608..4c001fae6 100644 --- a/sources/editor/graphicspart/partrectangle.h +++ b/sources/editor/graphicspart/partrectangle.h @@ -23,9 +23,9 @@ class QetGraphicsHandlerItem; /** - * This class represents a rectangle primitive which may be used to compose the - * drawing of an electrical element within the element editor. - * All coordinates is in item coordinate, except pos() + This class represents a rectangle primitive which may be used to compose the + drawing of an electrical element within the element editor. + All coordinates is in item coordinate, except pos() */ class PartRectangle : public CustomElementGraphicPart { @@ -52,9 +52,9 @@ class PartRectangle : public CustomElementGraphicPart public: enum { Type = UserType + 1109 }; /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartRectangle. - * @return the QGraphicsItem type - */ + Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartRectangle. + @return the QGraphicsItem type + */ int type () const override { return Type; } void paint (QPainter *, const QStyleOptionGraphicsItem *, QWidget * = nullptr) override; QString name () const override { return(QObject::tr("rectangle", "element part name")); } diff --git a/sources/editor/graphicspart/partterminal.cpp b/sources/editor/graphicspart/partterminal.cpp index b8586ec64..a3d55b8b4 100644 --- a/sources/editor/graphicspart/partterminal.cpp +++ b/sources/editor/graphicspart/partterminal.cpp @@ -93,9 +93,9 @@ void PartTerminal::paint(QPainter *p, const QStyleOptionGraphicsItem *options, Q } /** - * @brief PartTerminal::shape - * @return the shape of this item - */ + @brief PartTerminal::shape + @return the shape of this item +*/ QPainterPath PartTerminal::shape() const { QPainterPath shape; shape.lineTo(d -> second_point); @@ -107,9 +107,9 @@ QPainterPath PartTerminal::shape() const { } /** - * @brief PartTerminal::boundingRect - * @return the bounding rect of this item - */ + @brief PartTerminal::boundingRect + @return the bounding rect of this item +*/ QRectF PartTerminal::boundingRect() const { QRectF br(QPointF(0, 0), d -> second_point); br = br.normalized(); diff --git a/sources/editor/graphicspart/partterminal.h b/sources/editor/graphicspart/partterminal.h index 5cff09fe7..49f7beafd 100644 --- a/sources/editor/graphicspart/partterminal.h +++ b/sources/editor/graphicspart/partterminal.h @@ -47,9 +47,9 @@ class PartTerminal : public CustomElementGraphicPart { public: enum { Type = UserType + 1106 }; /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartTerminal. - * @return the QGraphicsItem type - */ + Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a PartTerminal. + @return the QGraphicsItem type + */ int type() const override { return Type; } QString name() const override { return d -> m_name; } QString xmlName() const override { return(QString("terminal")); } diff --git a/sources/editor/lineeditor.cpp b/sources/editor/lineeditor.cpp index 90498ae51..ecb9ae939 100644 --- a/sources/editor/lineeditor.cpp +++ b/sources/editor/lineeditor.cpp @@ -110,12 +110,12 @@ void LineEditor::disconnectChangeConnections() } /** - * @brief LineEditor::setPart - * Specifie to this editor the part to edit. - * Note that an editor can accept or refuse to edit a part. This editor accept only PartLine. - * @param new_part - * @return - */ + @brief LineEditor::setPart + Specifie to this editor the part to edit. + Note that an editor can accept or refuse to edit a part. This editor accept only PartLine. + @param new_part + @return +*/ bool LineEditor::setPart(CustomElementPart *new_part) { if (!new_part) @@ -164,17 +164,17 @@ QList LineEditor::currentParts() const { } /** - * @brief LineEditor::editedP1 - * @return The edited P1 in item coordinate - */ + @brief LineEditor::editedP1 + @return The edited P1 in item coordinate +*/ QPointF LineEditor::editedP1() const { return part -> mapFromScene(x1->value(), y1->value()); } /** - * @brief LineEditor::editedP2 - * @return The edited P2 in item coordinate - */ + @brief LineEditor::editedP2 + @return The edited P2 in item coordinate +*/ QPointF LineEditor::editedP2() const { return part -> mapFromScene(x2->value(), y2->value()); } @@ -366,9 +366,9 @@ void LineEditor::lineEditingFinishedY2() } /** - * @brief LineEditor::updateForm - * Update the value of the widgets - */ + @brief LineEditor::updateForm + Update the value of the widgets +*/ void LineEditor::updateForm() { if (!part) return; @@ -387,11 +387,11 @@ void LineEditor::updateForm() } /** - * @brief LineEditor::activeConnections - * Enable/disable connection between editor widget and slot editingFinished - * True == enable | false == disable - * @param active - */ + @brief LineEditor::activeConnections + Enable/disable connection between editor widget and slot editingFinished + True == enable | false == disable + @param active +*/ void LineEditor::activeConnections(bool active) { if (active) diff --git a/sources/editor/lineeditor.h b/sources/editor/lineeditor.h index e04d01558..9cf24ba05 100644 --- a/sources/editor/lineeditor.h +++ b/sources/editor/lineeditor.h @@ -70,10 +70,11 @@ class LineEditor : public ElementItemEditor private: void activeConnections(bool); - /*! - * \brief setUpChangeConnections - * Setup the connection from the line(s) to the widget, to update it when the line(s) are changed (moved ...) - */ + /** + @brief setUpChangeConnections + Setup the connection from the line(s) to the widget, + to update it when the line(s) are changed (moved ...) + */ void setUpChangeConnections(); void disconnectChangeConnections(); }; diff --git a/sources/editor/qetelementeditor.cpp b/sources/editor/qetelementeditor.cpp index 39cb8c243..3ba4c1094 100644 --- a/sources/editor/qetelementeditor.cpp +++ b/sources/editor/qetelementeditor.cpp @@ -106,10 +106,10 @@ QETElementEditor::~QETElementEditor() { } /** - * @brief QETElementEditor::setLocation - * The new location to edit - * @param el - */ + @brief QETElementEditor::setLocation + The new location to edit + @param el +*/ void QETElementEditor::setLocation(const ElementsLocation &el) { location_ = el; opened_from_file = false; @@ -132,9 +132,9 @@ void QETElementEditor::setFileName(const QString &fn) { } /** - * @brief QETElementEditor::setupActions - * Create action used in Element editor - */ + @brief QETElementEditor::setupActions + Create action used in Element editor +*/ void QETElementEditor::setupActions() { new_element = new QAction(QET::Icons::DocumentNew, tr("&Nouveau"), this); open = new QAction(QET::Icons::FolderOpen, tr("&Ouvrir"), this); @@ -260,7 +260,7 @@ void QETElementEditor::setupActions() { addToolBar(Qt::TopToolBarArea, depth_toolbar); /* - * Action related to zoom + Action related to zoom */ m_zoom_ag = new QActionGroup(this); @@ -280,7 +280,7 @@ void QETElementEditor::setupActions() { connect(zoom_reset, SIGNAL(triggered()), m_view, SLOT(zoomReset() )); /* - * Action related to primitive creation + Action related to primitive creation */ connect (m_elmt_scene, SIGNAL(partsAdded()), this, SLOT(UncheckAddPrimitive())); parts = new QActionGroup(this); @@ -359,8 +359,8 @@ void QETElementEditor::setupActions() { } /** - * @brief QETElementEditor::setupMenus - */ + @brief QETElementEditor::setupMenus +*/ void QETElementEditor::setupMenus() { file_menu = new QMenu(tr("&Fichier"), this); edit_menu = new QMenu(tr("&Édition"), this); @@ -422,11 +422,11 @@ void QETElementEditor::setupMenus() { } /** - * @brief QETElementEditor::contextMenu - * Display a context menu, with all available action. - * @param p, the pos of the menu, in screen coordinate - * @param actions, a list of actions who can be prepended to the context menu. - */ + @brief QETElementEditor::contextMenu + Display a context menu, with all available action. + @param p, the pos of the menu, in screen coordinate + @param actions, a list of actions who can be prepended to the context menu. +*/ void QETElementEditor::contextMenu(QPoint p, QList actions) { QMenu menu(this); menu.addActions(std::move(actions)); @@ -511,8 +511,8 @@ void QETElementEditor::slot_updateTitle() { } /** - * @brief QETElementEditor::setupInterface - */ + @brief QETElementEditor::setupInterface +*/ void QETElementEditor::setupInterface() { // editeur m_elmt_scene = new ElementScene(this, this); @@ -747,10 +747,10 @@ void QETElementEditor::slot_updateInformations() { } /** - * @brief QETElementEditor::checkElement - * Do several check about element. - * If error is occurred return false - */ + @brief QETElementEditor::checkElement + Do several check about element. + If error is occurred return false +*/ bool QETElementEditor::checkElement() { //List of warning and error typedef QPair QETWarning; @@ -897,11 +897,11 @@ void QETElementEditor::fromFile(const QString &filepath) { } /** - * @brief QETElementEditor::toFile - * Save to file the drawed element. - * @param fn : path of the file - * @return : true if succesfully save. - */ + @brief QETElementEditor::toFile + Save to file the drawed element. + @param fn : path of the file + @return : true if succesfully save. +*/ bool QETElementEditor::toFile(const QString &fn) { m_elmt_scene -> clearEventInterface(); m_elmt_scene -> clearSelection(); @@ -920,11 +920,11 @@ bool QETElementEditor::toFile(const QString &fn) { } /** - * @brief QETElementEditor::toLocation - * Save the element to Location - * @param location : location where we must save the current element - * @return true if succesfully saved - */ + @brief QETElementEditor::toLocation + Save the element to Location + @param location : location where we must save the current element + @return true if succesfully saved +*/ bool QETElementEditor::toLocation(const ElementsLocation &location) { m_elmt_scene -> clearEventInterface(); m_elmt_scene -> clearSelection(); @@ -1002,73 +1002,73 @@ bool QETElementEditor::isReadOnly() const { } /** - * @brief QETElementEditor::addLine - * Set line creation interface to scene - */ + @brief QETElementEditor::addLine + Set line creation interface to scene +*/ void QETElementEditor::addLine() { m_elmt_scene -> setEventInterface(new ESEventAddLine(m_elmt_scene)); } /** - * @brief QETElementEditor::addRect - * Set rectangle creation interface to scene - */ + @brief QETElementEditor::addRect + Set rectangle creation interface to scene +*/ void QETElementEditor::addRect() { m_elmt_scene -> setEventInterface(new ESEventAddRect(m_elmt_scene)); } /** - * @brief QETElementEditor::addEllipse - * Set ellipse creation interface to scene - */ + @brief QETElementEditor::addEllipse + Set ellipse creation interface to scene +*/ void QETElementEditor::addEllipse() { m_elmt_scene -> setEventInterface(new ESEventAddEllipse(m_elmt_scene)); } /** - * @brief QETElementEditor::addPolygon - * Set polygon creation interface to scene - */ + @brief QETElementEditor::addPolygon + Set polygon creation interface to scene +*/ void QETElementEditor::addPolygon() { m_elmt_scene -> setEventInterface(new ESEventAddPolygon(m_elmt_scene)); } /** - * @brief QETElementEditor::addArc - * Set arc creation interface to scene - */ + @brief QETElementEditor::addArc + Set arc creation interface to scene +*/ void QETElementEditor::addArc() { m_elmt_scene -> setEventInterface(new ESEventAddArc(m_elmt_scene)); } /** - * @brief QETElementEditor::addText - * Set text creation interface to scene - */ + @brief QETElementEditor::addText + Set text creation interface to scene +*/ void QETElementEditor::addText() { m_elmt_scene -> setEventInterface(new ESEventAddText(m_elmt_scene)); } /** - * @brief QETElementEditor::addTerminal - * Set terminal creation interface to scene - */ + @brief QETElementEditor::addTerminal + Set terminal creation interface to scene +*/ void QETElementEditor::addTerminal() { m_elmt_scene -> setEventInterface(new ESEventAddTerminal(m_elmt_scene)); } /** - * @brief QETElementEditor::addDynamicTextField - * Set dynamic text field creation interface to scene - */ + @brief QETElementEditor::addDynamicTextField + Set dynamic text field creation interface to scene +*/ void QETElementEditor::addDynamicTextField() { m_elmt_scene -> setEventInterface(new ESEventAddDynamicTextField(m_elmt_scene)); } /** - * @brief QETElementEditor::UncheckAddPrimitive - * Uncheck all action related to primitive - */ + @brief QETElementEditor::UncheckAddPrimitive + Uncheck all action related to primitive +*/ void QETElementEditor::UncheckAddPrimitive() { foreach(QAction *action, parts -> actions()) { action -> setChecked(false); @@ -1126,8 +1126,8 @@ void QETElementEditor::openRecentFile(const QString &filepath) { } /** - * @brief QETElementEditor::slot_openDxf - */ + @brief QETElementEditor::slot_openDxf +*/ void QETElementEditor::slot_openDxf (){ #if defined(Q_OS_WIN32) || defined(Q_OS_WIN64) @@ -1170,9 +1170,9 @@ void QETElementEditor::openElement(const QString &filepath) { } /** - * @brief QETElementEditor::slot_reload - * Reload the element from the file or location - */ + @brief QETElementEditor::slot_reload + Reload the element from the file or location +*/ void QETElementEditor::slot_reload() { //If user already edit the element, ask confirmation to reload if (!m_elmt_scene -> undoStack().isClean()) { @@ -1197,11 +1197,11 @@ void QETElementEditor::slot_reload() { } /** - * @brief QETElementEditor::slot_save - * Save the current editing element. - * If the filepath or location is unknown, use save_as instead - * @return true if save with success - */ + @brief QETElementEditor::slot_save + Save the current editing element. + If the filepath or location is unknown, use save_as instead + @return true if save with success +*/ bool QETElementEditor::slot_save() { // Check element befor writing if (checkElement()) { @@ -1236,11 +1236,11 @@ bool QETElementEditor::slot_save() { } /** - * @brief QETElementEditor::slot_saveAs - * Ask a location to user and save the current edited element - * to this location - * @return true if save with success - */ + @brief QETElementEditor::slot_saveAs + Ask a location to user and save the current edited element + to this location + @return true if save with success +*/ bool QETElementEditor::slot_saveAs() { // Check element befor writing if (checkElement()) { @@ -1264,10 +1264,10 @@ bool QETElementEditor::slot_saveAs() { } /** - * @brief QETElementEditor::slot_saveAsFile - * Ask a file to user and save the current edited element to this file - * @return true if save with success - */ + @brief QETElementEditor::slot_saveAsFile + Ask a file to user and save the current edited element to this file + @return true if save with success +*/ bool QETElementEditor::slot_saveAsFile() { // Check element befor writing if (checkElement()) { @@ -1480,9 +1480,9 @@ void QETElementEditor::slot_updateSelectionFromPartsList() { } /** - * @brief QETElementEditor::readSettings - * Read settings - */ + @brief QETElementEditor::readSettings + Read settings +*/ void QETElementEditor::readSettings() { QSettings settings; @@ -1503,9 +1503,9 @@ void QETElementEditor::readSettings() { } /** - * @brief QETElementEditor::writeSettings - * Write the settings - */ + @brief QETElementEditor::writeSettings + Write the settings +*/ void QETElementEditor::writeSettings() { QSettings settings; settings.setValue("elementeditor/geometry", saveGeometry()); @@ -1547,10 +1547,10 @@ QString QETElementEditor::getOpenElementFileName(QWidget *parent, const QString } /** - * @brief QETElementEditor::fromLocation - * Location of the element to edit - * @param location - */ + @brief QETElementEditor::fromLocation + Location of the element to edit + @param location +*/ void QETElementEditor::fromLocation(const ElementsLocation &location) { if (!location.isElement()) { QET::QetMessageBox::critical(this, @@ -1622,10 +1622,10 @@ void QETElementEditor::pasteFromFile() { } /** - * @brief QETElementEditor::pasteFromElement - * Ask an element to user, copy the xml definition of the element - * to the clipboard and call ElementView::PasteInArea - */ + @brief QETElementEditor::pasteFromElement + Ask an element to user, copy the xml definition of the element + to the clipboard and call ElementView::PasteInArea +*/ void QETElementEditor::pasteFromElement() { //Ask for a location ElementsLocation location = ElementDialog::getOpenElementLocation(this); diff --git a/sources/editor/styleeditor.cpp b/sources/editor/styleeditor.cpp index 08a41dec9..09cb543fd 100644 --- a/sources/editor/styleeditor.cpp +++ b/sources/editor/styleeditor.cpp @@ -432,9 +432,9 @@ void StyleEditor::updatePartFilling() { } /** - * @brief StyleEditor::updateForm - * Update the edition form according to the value of edited part(s) - */ + @brief StyleEditor::updateForm + Update the edition form according to the value of edited part(s) +*/ void StyleEditor::updateForm() { if (!part && m_part_list.isEmpty()) return; @@ -471,12 +471,12 @@ void StyleEditor::updateForm() } /** - * @brief StyleEditor::setPart - * Set the part to edit by this editor. - * Note : editor can accept or refuse to edit a part - * @param new_part : part to edit - * @return true if editor accept to edit this CustomElementPart otherwise false - */ + @brief StyleEditor::setPart + Set the part to edit by this editor. + Note : editor can accept or refuse to edit a part + @param new_part : part to edit + @return true if editor accept to edit this CustomElementPart otherwise false +*/ bool StyleEditor::setPart(CustomElementPart *new_part) { m_part_list.clear(); m_cep_list.clear(); @@ -499,14 +499,14 @@ bool StyleEditor::setPart(CustomElementPart *new_part) { } /** - * @brief StyleEditor::setParts - * Set several parts to edit by this editor. - * Note : editor can accept or refuse to edit several parts. - * @param part_list - * @return true if every customeElementPart stored in part_list can - * be edited by this part editor, otherwise return false - * (see StyleEditor::isStyleEditable) - */ + @brief StyleEditor::setParts + Set several parts to edit by this editor. + Note : editor can accept or refuse to edit several parts. + @param part_list + @return true if every customeElementPart stored in part_list can + be edited by this part editor, otherwise return false + (see StyleEditor::isStyleEditable) +*/ bool StyleEditor::setParts(QList part_list) { if (part_list.isEmpty()) return false; @@ -545,10 +545,10 @@ QList StyleEditor::currentParts() const { } /** - * @brief StyleEditor::isStyleEditable - * @param cep_list - * @return true if all of the content of cep_list can be edited by style editor, else return false. - */ + @brief StyleEditor::isStyleEditable + @param cep_list + @return true if all of the content of cep_list can be edited by style editor, else return false. +*/ bool StyleEditor::isStyleEditable(QList cep_list) { QStringList str; diff --git a/sources/editor/ui/dynamictextfieldeditor.cpp b/sources/editor/ui/dynamictextfieldeditor.cpp index 7b5f5e750..018d58455 100644 --- a/sources/editor/ui/dynamictextfieldeditor.cpp +++ b/sources/editor/ui/dynamictextfieldeditor.cpp @@ -53,11 +53,11 @@ DynamicTextFieldEditor::~DynamicTextFieldEditor() { } /** - * @brief DynamicTextFieldEditor::setPart - * Set @part as current edited part of this widget. - * @param part - * @return true if @part can be edited by this widget - */ + @brief DynamicTextFieldEditor::setPart + Set @part as current edited part of this widget. + @param part + @return true if @part can be edited by this widget +*/ bool DynamicTextFieldEditor::setPart(CustomElementPart *part) { disconnectConnections(); @@ -104,10 +104,10 @@ bool DynamicTextFieldEditor::setParts(QList parts) { } /** - * @brief DynamicTextFieldEditor::currentPart - * @return The current edited part, note they can return nullptr if - * there is not a currently edited part. - */ + @brief DynamicTextFieldEditor::currentPart + @return The current edited part, note they can return nullptr if + there is not a currently edited part. +*/ CustomElementPart *DynamicTextFieldEditor::currentPart() const { return m_text_field.data(); } @@ -187,9 +187,9 @@ void DynamicTextFieldEditor::disconnectConnections() { } /** - * @brief DynamicTextFieldEditor::fillInfoComboBox - * Fill the combo box "element information" - */ + @brief DynamicTextFieldEditor::fillInfoComboBox + Fill the combo box "element information" +*/ void DynamicTextFieldEditor::fillInfoComboBox() { ui -> m_elmt_info_cb -> clear(); diff --git a/sources/editor/ui/dynamictextfieldeditor.h b/sources/editor/ui/dynamictextfieldeditor.h index a9991283c..2d5630f52 100644 --- a/sources/editor/ui/dynamictextfieldeditor.h +++ b/sources/editor/ui/dynamictextfieldeditor.h @@ -26,9 +26,9 @@ namespace Ui { } /** - * @brief The DynamicTextFieldEditor class - * This class provide a widget used to edit the property of a dynamic text field - */ + @brief The DynamicTextFieldEditor class + This class provide a widget used to edit the property of a dynamic text field +*/ class DynamicTextFieldEditor : public ElementItemEditor { Q_OBJECT diff --git a/sources/editor/ui/elementpropertieseditorwidget.cpp b/sources/editor/ui/elementpropertieseditorwidget.cpp index d17bff735..20b366650 100644 --- a/sources/editor/ui/elementpropertieseditorwidget.cpp +++ b/sources/editor/ui/elementpropertieseditorwidget.cpp @@ -22,10 +22,10 @@ #include /** - * @brief The EditorDelegate class - * This delegate is only use for disable the edition of the first - * column of the information tree widget - */ + @brief The EditorDelegate class + This delegate is only use for disable the edition of the first + column of the information tree widget +*/ class EditorDelegate : public QItemDelegate { public: @@ -44,13 +44,13 @@ class EditorDelegate : public QItemDelegate }; /** - * @brief ElementPropertiesEditorWidget::ElementPropertiesEditorWidget - * Default constructor - * @param basic_type : QString of the drawed element - * @param kind_info : DiagramContext to store kindInfo of drawed element - * @param elmt_info : the information of element (label, manufacturer etc...] - * @param parent : parent widget - */ + @brief ElementPropertiesEditorWidget::ElementPropertiesEditorWidget + Default constructor + @param basic_type : QString of the drawed element + @param kind_info : DiagramContext to store kindInfo of drawed element + @param elmt_info : the information of element (label, manufacturer etc...] + @param parent : parent widget +*/ ElementPropertiesEditorWidget::ElementPropertiesEditorWidget(QString &basic_type, DiagramContext &kind_info, DiagramContext &elmt_info, QWidget *parent) : QDialog(parent), ui(new Ui::ElementPropertiesEditorWidget), @@ -64,18 +64,18 @@ ElementPropertiesEditorWidget::ElementPropertiesEditorWidget(QString &basic_type } /** - * @brief ElementPropertiesEditorWidget::~ElementPropertiesEditorWidget - * Default destructor - */ + @brief ElementPropertiesEditorWidget::~ElementPropertiesEditorWidget + Default destructor +*/ ElementPropertiesEditorWidget::~ElementPropertiesEditorWidget() { delete ui; } /** - * @brief ElementPropertiesEditorWidget::upDateInterface - * Update the interface with the curent value - */ + @brief ElementPropertiesEditorWidget::upDateInterface + Update the interface with the curent value +*/ void ElementPropertiesEditorWidget::upDateInterface() { ui->m_base_type_cb->setCurrentIndex(ui->m_base_type_cb->findData(QVariant(m_basic_type))); @@ -94,8 +94,8 @@ void ElementPropertiesEditorWidget::upDateInterface() } /** - * @brief ElementPropertiesEditorWidget::setUpInterface - */ + @brief ElementPropertiesEditorWidget::setUpInterface +*/ void ElementPropertiesEditorWidget::setUpInterface() { // Type combo box @@ -147,9 +147,9 @@ void ElementPropertiesEditorWidget::updateTree() } /** - * @brief ElementPropertiesEditorWidget::populateTree - * Create QTreeWidgetItem of the tree widget and populate it - */ + @brief ElementPropertiesEditorWidget::populateTree + Create QTreeWidgetItem of the tree widget and populate it +*/ void ElementPropertiesEditorWidget::populateTree() { QStringList keys{"label", "plant", "comment", "description", "designation", "manufacturer", "manufacturer_reference", "supplier", "quantity", "unity", "machine_manufacturer_reference"}; @@ -165,9 +165,9 @@ void ElementPropertiesEditorWidget::populateTree() } /** - * @brief ElementPropertiesEditorWidget::on_m_buttonBox_accepted - * Action on button accepted : the new information is set - */ + @brief ElementPropertiesEditorWidget::on_m_buttonBox_accepted + Action on button accepted : the new information is set +*/ void ElementPropertiesEditorWidget::on_m_buttonBox_accepted() { m_basic_type = ui -> m_base_type_cb -> itemData(ui -> m_base_type_cb -> currentIndex()).toString(); @@ -194,9 +194,9 @@ void ElementPropertiesEditorWidget::on_m_buttonBox_accepted() } /** - * @brief ElementPropertiesEditorWidget::on_m_base_type_cb_currentIndexChanged - * @param index : Action when combo-box base type index change - */ + @brief ElementPropertiesEditorWidget::on_m_base_type_cb_currentIndexChanged + @param index : Action when combo-box base type index change +*/ void ElementPropertiesEditorWidget::on_m_base_type_cb_currentIndexChanged(int index) { bool slave = false , master = false; diff --git a/sources/editor/ui/elementpropertieseditorwidget.h b/sources/editor/ui/elementpropertieseditorwidget.h index 105c4512d..ca0337ca4 100644 --- a/sources/editor/ui/elementpropertieseditorwidget.h +++ b/sources/editor/ui/elementpropertieseditorwidget.h @@ -27,10 +27,10 @@ namespace Ui { } /** - * @brief The ElementPropertiesEditorWidget class - * This class provide a dialog for edit various property of element, like - * the type (master, slave, report etc....) and kind info. - */ + @brief The ElementPropertiesEditorWidget class + This class provide a dialog for edit various property of element, like + the type (master, slave, report etc....) and kind info. +*/ class ElementPropertiesEditorWidget : public QDialog { Q_OBJECT diff --git a/sources/editor/ui/polygoneditor.cpp b/sources/editor/ui/polygoneditor.cpp index bea8ae54a..4658d00db 100644 --- a/sources/editor/ui/polygoneditor.cpp +++ b/sources/editor/ui/polygoneditor.cpp @@ -24,11 +24,11 @@ #include "QPropertyUndoCommand/qpropertyundocommand.h" /** - * @brief PolygonEditor::PolygonEditor - * @param editor - * @param part - * @param parent - */ + @brief PolygonEditor::PolygonEditor + @param editor + @param part + @param parent +*/ PolygonEditor::PolygonEditor(QETElementEditor *editor, PartPolygon *part, QWidget *parent) : ElementItemEditor(editor, parent), ui(new Ui::PolygonEditor), @@ -44,8 +44,8 @@ PolygonEditor::PolygonEditor(QETElementEditor *editor, PartPolygon *part, QWidge } /** - * @brief PolygonEditor::~PolygonEditor - */ + @brief PolygonEditor::~PolygonEditor +*/ PolygonEditor::~PolygonEditor() { delete ui; } @@ -67,10 +67,10 @@ void PolygonEditor::disconnectChangeConnections() } /** - * @brief PolygonEditor::setPart - * @param new_part - * @return - */ + @brief PolygonEditor::setPart + @param new_part + @return +*/ bool PolygonEditor::setPart(CustomElementPart *new_part) { if (!new_part) @@ -98,9 +98,9 @@ bool PolygonEditor::setPart(CustomElementPart *new_part) } /** - * @brief PolygonEditor::currentPart - * @return the curent edited part - */ + @brief PolygonEditor::currentPart + @return the curent edited part +*/ CustomElementPart *PolygonEditor::currentPart() const { return m_part; } @@ -110,9 +110,9 @@ QList PolygonEditor::currentParts() const { } /** - * @brief PolygonEditor::updateForm - * Update the widget - */ + @brief PolygonEditor::updateForm + Update the widget +*/ void PolygonEditor::updateForm() { if (!m_part) { @@ -135,10 +135,10 @@ void PolygonEditor::updateForm() } /** - * @brief PolygonEditor::pointsFromTree - * @return the point of polygon from the current value of the tree editor - * if part coordinate. - */ + @brief PolygonEditor::pointsFromTree + @return the point of polygon from the current value of the tree editor + if part coordinate. +*/ QVector PolygonEditor::pointsFromTree() { QVector points; @@ -173,8 +173,8 @@ bool PolygonEditor::eventFilter(QObject *watched, QEvent *event) } /** - * @brief PolygonEditor::on_m_close_polygon_cb_stateChanged - */ + @brief PolygonEditor::on_m_close_polygon_cb_stateChanged +*/ void PolygonEditor::on_m_close_polygon_cb_stateChanged(int arg1) { Q_UNUSED(arg1); @@ -192,9 +192,9 @@ void PolygonEditor::on_m_close_polygon_cb_stateChanged(int arg1) } /** - * @brief PolygonEditor::on_m_points_list_tree_itemChanged - * Update the polygon according to the current value of the tree editor - */ + @brief PolygonEditor::on_m_points_list_tree_itemChanged + Update the polygon according to the current value of the tree editor +*/ void PolygonEditor::on_m_points_list_tree_itemChanged(QTreeWidgetItem *item, int column) { Q_UNUSED(item); @@ -220,9 +220,9 @@ void PolygonEditor::on_m_points_list_tree_itemChanged(QTreeWidgetItem *item, int } /** - * @brief PolygonEditor::on_m_points_list_tree_itemSelectionChanged - * Used to change the color of the current selected point. - */ + @brief PolygonEditor::on_m_points_list_tree_itemSelectionChanged + Used to change the color of the current selected point. +*/ void PolygonEditor::on_m_points_list_tree_itemSelectionChanged() { //Prevent when selection change but the widget ins't focused diff --git a/sources/editor/ui/polygoneditor.h b/sources/editor/ui/polygoneditor.h index 66117d100..f8ccbefba 100644 --- a/sources/editor/ui/polygoneditor.h +++ b/sources/editor/ui/polygoneditor.h @@ -51,10 +51,11 @@ class PolygonEditor : public ElementItemEditor void on_m_remove_point_action_triggered(); private: - /*! - * \brief setUpChangeConnections - * Setup the connection from the line(s) to the widget, to update it when the line(s) are changed (moved ...) - */ + /** + @brief setUpChangeConnections + Setup the connection from the line(s) to the widget, + to update it when the line(s) are changed (moved ...) + */ void setUpChangeConnections(); void disconnectChangeConnections(); diff --git a/sources/editor/ui/rectangleeditor.cpp b/sources/editor/ui/rectangleeditor.cpp index cc8e05c2a..913b1976c 100644 --- a/sources/editor/ui/rectangleeditor.cpp +++ b/sources/editor/ui/rectangleeditor.cpp @@ -24,11 +24,11 @@ #include "qeticons.h" /** - * @brief RectangleEditor::RectangleEditor - * @param editor - * @param rect - * @param parent - */ + @brief RectangleEditor::RectangleEditor + @param editor + @param rect + @param parent +*/ RectangleEditor::RectangleEditor(QETElementEditor *editor, PartRectangle *rect, QWidget *parent) : ElementItemEditor(editor, parent), m_part(rect), @@ -40,8 +40,8 @@ RectangleEditor::RectangleEditor(QETElementEditor *editor, PartRectangle *rect, } /** - * @brief RectangleEditor::~RectangleEditor - */ + @brief RectangleEditor::~RectangleEditor +*/ RectangleEditor::~RectangleEditor() { delete ui; } @@ -64,10 +64,10 @@ void RectangleEditor::disconnectChangeConnections() } /** - * @brief RectangleEditor::setPart - * @param part - * @return - */ + @brief RectangleEditor::setPart + @param part + @return +*/ bool RectangleEditor::setPart(CustomElementPart *part) { if (!part) @@ -109,9 +109,9 @@ bool RectangleEditor::setParts(QList parts) } /** - * @brief RectangleEditor::currentPart - * @return - */ + @brief RectangleEditor::currentPart + @return +*/ CustomElementPart *RectangleEditor::currentPart() const { return m_part; } @@ -121,16 +121,16 @@ QList RectangleEditor::currentParts() const { } /** - * @brief RectangleEditor::topLeft - * @return The edited topLeft already mapped to part coordinate - */ + @brief RectangleEditor::topLeft + @return The edited topLeft already mapped to part coordinate +*/ QPointF RectangleEditor::editedTopLeft() const { return m_part->mapFromScene(ui->m_x_sb->value(), ui->m_y_sb->value()); } /** - * @brief RectangleEditor::updateForm - */ + @brief RectangleEditor::updateForm +*/ void RectangleEditor::updateForm() { if (!m_part) { @@ -153,10 +153,10 @@ void RectangleEditor::updateForm() } /** - * @brief RectangleEditor::editingFinished - * Slot called when a editor widget is finish to be edited - * Update the geometry of the rectangle according to value of editing widget. - */ + @brief RectangleEditor::editingFinished + Slot called when a editor widget is finish to be edited + Update the geometry of the rectangle according to value of editing widget. +*/ void RectangleEditor::editingFinished() { if (m_locked) { @@ -340,11 +340,11 @@ void RectangleEditor::yRadiusChanged() /** - * @brief RectangleEditor::activeConnections - * Enable/disable connection between editor widget and slot editingFinished - * True == enable | false == disable - * @param active - */ + @brief RectangleEditor::activeConnections + Enable/disable connection between editor widget and slot editingFinished + True == enable | false == disable + @param active +*/ void RectangleEditor::activeConnections(bool active) { if (active) diff --git a/sources/editor/ui/rectangleeditor.h b/sources/editor/ui/rectangleeditor.h index 09e606897..94c7480d1 100644 --- a/sources/editor/ui/rectangleeditor.h +++ b/sources/editor/ui/rectangleeditor.h @@ -29,9 +29,9 @@ namespace Ui { } /** - * @brief The RectangleEditor class - * This class provides a widget to edit rectangles within the element editor. - */ + @brief The RectangleEditor class + This class provides a widget to edit rectangles within the element editor. +*/ class RectangleEditor : public ElementItemEditor { Q_OBJECT @@ -58,9 +58,9 @@ class RectangleEditor : public ElementItemEditor void xRadiusChanged(); void yRadiusChanged(); /*! - * \brief setUpChangeConnections - * Setup the connection from the rectangles(s) to the widget, to update it when the rectangles(s) are changed (moved ...) - */ + \brief setUpChangeConnections + Setup the connection from the rectangles(s) to the widget, to update it when the rectangles(s) are changed (moved ...) + */ void setUpChangeConnections(); void disconnectChangeConnections(); diff --git a/sources/editor/ui/texteditor.cpp b/sources/editor/ui/texteditor.cpp index 0749f6de4..e7a30df70 100644 --- a/sources/editor/ui/texteditor.cpp +++ b/sources/editor/ui/texteditor.cpp @@ -22,12 +22,12 @@ #include /** - * @brief TextEditor::TextEditor - * Default constructor - * @param editor : the element editor who use this editor - * @param text : the text to edit - * @param parent : the parent widget - */ + @brief TextEditor::TextEditor + Default constructor + @param editor : the element editor who use this editor + @param text : the text to edit + @param parent : the parent widget +*/ TextEditor::TextEditor(QETElementEditor *editor, PartText *text, QWidget *parent) : ElementItemEditor(editor, parent), ui(new Ui::TextEditor) { @@ -40,16 +40,16 @@ TextEditor::TextEditor(QETElementEditor *editor, PartText *text, QWidget *paren } /** - * @brief TextEditor::~TextEditor - */ + @brief TextEditor::~TextEditor +*/ TextEditor::~TextEditor() { delete ui; } /** - * @brief TextEditor::updateForm - * Update the gui - */ + @brief TextEditor::updateForm + Update the gui +*/ void TextEditor::updateForm() { if (m_text.isNull()) { @@ -94,12 +94,12 @@ void TextEditor::disconnectEditConnection() { } /** - * @brief TextEditor::setPart - * Set the current text to edit. - * Set @part to nullptr to clear the current text. - * @param part : part to edit - * @return : return if @part is a partext or nullptr, else return false - */ + @brief TextEditor::setPart + Set the current text to edit. + Set @part to nullptr to clear the current text. + @param part : part to edit + @return : return if @part is a partext or nullptr, else return false +*/ bool TextEditor::setPart(CustomElementPart *part) { if (!part) { m_text = nullptr; @@ -147,9 +147,9 @@ bool TextEditor::setParts(QList parts) { } /** - * @brief TextEditor::currentPart - * @return The current part - */ + @brief TextEditor::currentPart + @return The current part +*/ CustomElementPart *TextEditor::currentPart() const { return m_text; } @@ -163,10 +163,10 @@ QList TextEditor::currentParts() const { } /** - * @brief TextEditor::setUpEditConnection - * Setup the connection between the widgets of this editor and the undo command - * use to apply the change to the edited text. - */ + @brief TextEditor::setUpEditConnection + Setup the connection between the widgets of this editor and the undo command + use to apply the change to the edited text. +*/ void TextEditor::setUpEditConnection() { disconnectEditConnection(); @@ -234,8 +234,8 @@ void TextEditor::setUpEditConnection() { } /** - * @brief TextEditor::on_m_font_pb_clicked - */ + @brief TextEditor::on_m_font_pb_clicked +*/ void TextEditor::on_m_font_pb_clicked() { bool ok; QFont font_ = QFontDialog::getFont(&ok, m_text -> font(), this); @@ -259,9 +259,9 @@ void TextEditor::on_m_font_pb_clicked() { } /** - * @brief TextEditor::on_m_color_pb_changed - * @param newColor - */ + @brief TextEditor::on_m_color_pb_changed + @param newColor +*/ void TextEditor::on_m_color_pb_changed(const QColor &newColor) { for (int i=0; i < m_parts.length(); i++) { PartText* partText = m_parts[i]; diff --git a/sources/elementdialog.cpp b/sources/elementdialog.cpp index d42b0f8c0..777911865 100644 --- a/sources/elementdialog.cpp +++ b/sources/elementdialog.cpp @@ -30,10 +30,10 @@ #include "qetmessagebox.h" /** - * @brief ElementDialog::ElementDialog - * @param mode - * @param parent - */ + @brief ElementDialog::ElementDialog + @param mode + @param parent +*/ ElementDialog::ElementDialog(uint mode, QWidget *parent) : QDialog(parent), m_mode(mode) @@ -43,9 +43,9 @@ ElementDialog::ElementDialog(uint mode, QWidget *parent) : } /** - * @brief ElementDialog::setUpWidget - * Build and setup the widgets of this dialog - */ + @brief ElementDialog::setUpWidget + Build and setup the widgets of this dialog +*/ void ElementDialog::setUpWidget() { setWindowModality(Qt::WindowModal); @@ -124,9 +124,9 @@ void ElementDialog::setUpWidget() } /** - * @brief ElementDialog::setUpConnection - * Setup connection of this dialog - */ + @brief ElementDialog::setUpConnection + Setup connection of this dialog +*/ void ElementDialog::setUpConnection() { connect(m_tree_view, &QTreeView::clicked, this, &ElementDialog::indexClicked); @@ -137,9 +137,9 @@ void ElementDialog::setUpConnection() } /** - * @brief ElementDialog::indexClicked - * @param index - */ + @brief ElementDialog::indexClicked + @param index +*/ void ElementDialog::indexClicked(const QModelIndex &index) { ElementCollectionItem *eci = static_cast (m_model->itemFromIndex(index)); @@ -148,9 +148,9 @@ void ElementDialog::indexClicked(const QModelIndex &index) } /** - * @brief ElementDialog::checkCurrentLocation - * Update this dialog according to the current selected location and the current mode - */ + @brief ElementDialog::checkCurrentLocation + Update this dialog according to the current selected location and the current mode +*/ void ElementDialog::checkCurrentLocation() { if (m_mode == OpenElement) { @@ -236,10 +236,10 @@ void ElementDialog::checkAccept() } /** - * @brief ElementDialog::location - * @return The selected location or a null location if user has selected nothing - * or selection isn't compatible with the curent mode - */ + @brief ElementDialog::location + @return The selected location or a null location if user has selected nothing + or selection isn't compatible with the curent mode +*/ ElementsLocation ElementDialog::location() const { if (m_mode == OpenElement) @@ -272,32 +272,32 @@ ElementsLocation ElementDialog::location() const } /** - * @brief ElementDialog::getOpenElementLocation - * Display a dialog for open an element through her location - * @param parentWidget - * @return The location of the selected element - */ + @brief ElementDialog::getOpenElementLocation + Display a dialog for open an element through her location + @param parentWidget + @return The location of the selected element +*/ ElementsLocation ElementDialog::getOpenElementLocation(QWidget *parentWidget) { return(ElementDialog::execConfiguredDialog(ElementDialog::OpenElement, parentWidget)); } /** - * @brief ElementDialog::getSaveElementLocation - * Display a dialog that allow to user to select an element (existing or not) who he want to save - * @param parentWidget - * @return The location where the element must be save - */ + @brief ElementDialog::getSaveElementLocation + Display a dialog that allow to user to select an element (existing or not) who he want to save + @param parentWidget + @return The location where the element must be save +*/ ElementsLocation ElementDialog::getSaveElementLocation(QWidget *parentWidget) { return(ElementDialog::execConfiguredDialog(ElementDialog::SaveElement, parentWidget)); } /** - * @brief ElementDialog::execConfiguredDialog - * launch a dialog with the chosen mode - * @param mode : mode of the dialog - * @param parentWidget : parent widget of the dialog - * @return the chosen location - */ + @brief ElementDialog::execConfiguredDialog + launch a dialog with the chosen mode + @param mode : mode of the dialog + @param parentWidget : parent widget of the dialog + @return the chosen location +*/ ElementsLocation ElementDialog::execConfiguredDialog(int mode, QWidget *parentWidget) { ElementDialog *element_dialog = new ElementDialog(mode, parentWidget); diff --git a/sources/elementprovider.cpp b/sources/elementprovider.cpp index 50847b348..2653fac4e 100644 --- a/sources/elementprovider.cpp +++ b/sources/elementprovider.cpp @@ -23,10 +23,10 @@ #include /** - * @brief ElementProvider::ElementProvider Constructor - * @param prj the project where we must find element - * @param diagram the diagram to exclude from the search - */ + @brief ElementProvider::ElementProvider Constructor + @param prj the project where we must find element + @param diagram the diagram to exclude from the search +*/ ElementProvider::ElementProvider(QETProject *prj, Diagram *diagram) { m_diagram_list = prj->diagrams(); @@ -34,22 +34,22 @@ ElementProvider::ElementProvider(QETProject *prj, Diagram *diagram) } /** - * @brief ElementProvider::ElementProvider Constructor - * @param diag Diagram to search - */ + @brief ElementProvider::ElementProvider Constructor + @param diag Diagram to search +*/ ElementProvider::ElementProvider(Diagram *diag) { m_diagram_list << diag; } /** - * @brief ElementProvider::FreeElement - * Search and return the asked element corresponding with the given filter - * All returned element are free, ie element aren't connected with another element - * @param filter - * the filter for search element - * (You can find all filter with the #define in Element.h) - * @return - */ + @brief ElementProvider::FreeElement + Search and return the asked element corresponding with the given filter + All returned element are free, ie element aren't connected with another element + @param filter + the filter for search element + (You can find all filter with the #define in Element.h) + @return +*/ QList ElementProvider::freeElement(const int filter) const{ QList free_elmt; @@ -67,10 +67,10 @@ QList ElementProvider::freeElement(const int filter) const{ } /** - * @brief ElementProvider::fromUuids - * @param uuid_list list of uuid must be found - * @return all elements with uuid corresponding to uuid in @uuid_list - */ + @brief ElementProvider::fromUuids + @param uuid_list list of uuid must be found + @return all elements with uuid corresponding to uuid in @uuid_list +*/ QList ElementProvider::fromUuids(QList uuid_list) const { QList found_element; @@ -86,12 +86,12 @@ QList ElementProvider::fromUuids(QList uuid_list) const { } /** - * @brief ElementProvider::find - * Search and return the asked element corresponding with the given filter - * @param filter - * the filter for search element - * (You can find all filter with the #define in Element.h) - */ + @brief ElementProvider::find + Search and return the asked element corresponding with the given filter + @param filter + the filter for search element + (You can find all filter with the #define in Element.h) +*/ QList ElementProvider::find(const int filter) const { QList elmt_; @@ -109,12 +109,12 @@ QList ElementProvider::find(const int filter) const { } /** - * @brief ElementProvider::table - * @param table - * @param model - * @return All tables wich display the derivated class of @model (if set) and not already in all the chain of next/previous table of @table (if set) - * If table and model are nullptr, return every tables - */ + @brief ElementProvider::table + @param table + @param model + @return All tables wich display the derivated class of @model (if set) and not already in all the chain of next/previous table of @table (if set) + If table and model are nullptr, return every tables +*/ QVector ElementProvider::table(QetGraphicsTableItem *table, QAbstractItemModel *model) { QVector v_; @@ -158,10 +158,10 @@ QVector ElementProvider::table(QetGraphicsTableItem *tab } /** - * @brief ElementProvider::tableFromUuid - * @param uuid - * @return the table with uuid @uuid or nullptr if not found - */ + @brief ElementProvider::tableFromUuid + @param uuid + @return the table with uuid @uuid or nullptr if not found +*/ QetGraphicsTableItem *ElementProvider::tableFromUuid(const QUuid &uuid) { for (auto table : this->table()) diff --git a/sources/elementscategoryeditor.cpp b/sources/elementscategoryeditor.cpp index 43e2e1a9e..6eceedc65 100644 --- a/sources/elementscategoryeditor.cpp +++ b/sources/elementscategoryeditor.cpp @@ -28,12 +28,12 @@ #include /** - * @brief ElementsCategoryEditor::ElementsCategoryEditor - * Constructor - * @param location : location of the category to edit, or parent directory/category for the creation of a new category - * @param edit : true = edit mode, false = creation mode - * @param parent : parent widget - */ + @brief ElementsCategoryEditor::ElementsCategoryEditor + Constructor + @param location : location of the category to edit, or parent directory/category for the creation of a new category + @param edit : true = edit mode, false = creation mode + @param parent : parent widget +*/ ElementsCategoryEditor::ElementsCategoryEditor(const ElementsLocation &location, bool edit, QWidget *parent) : QDialog(parent), m_edit_mode(edit), @@ -84,24 +84,24 @@ ElementsCategoryEditor::ElementsCategoryEditor(const ElementsLocation &location, } /** - * @brief ElementsCategoryEditor::~ElementsCategoryEditor - * Destructor - */ + @brief ElementsCategoryEditor::~ElementsCategoryEditor + Destructor +*/ ElementsCategoryEditor::~ElementsCategoryEditor() { } /** - * @brief ElementsCategoryEditor::createdLocation - * @return the location of the created directory - */ + @brief ElementsCategoryEditor::createdLocation + @return the location of the created directory +*/ ElementsLocation ElementsCategoryEditor::createdLocation() const { return m_created_location; } /** - * @brief ElementsCategoryEditor::setUpWidget - */ + @brief ElementsCategoryEditor::setUpWidget +*/ void ElementsCategoryEditor::setUpWidget() { QVBoxLayout *editor_layout = new QVBoxLayout(); @@ -125,9 +125,9 @@ void ElementsCategoryEditor::setUpWidget() } /** - * @brief ElementsCategoryEditor::acceptCreation - * Valid the creation of the category - */ + @brief ElementsCategoryEditor::acceptCreation + Valid the creation of the category +*/ void ElementsCategoryEditor::acceptCreation() { if (!m_location.isWritable()) { @@ -176,9 +176,9 @@ void ElementsCategoryEditor::acceptCreation() } /** - * @brief ElementsCategoryEditor::acceptUpdate - * Valid the update of the category - */ + @brief ElementsCategoryEditor::acceptUpdate + Valid the update of the category +*/ void ElementsCategoryEditor::acceptUpdate() { if (!m_location.isWritable()) { diff --git a/sources/elementscategoryeditor.h b/sources/elementscategoryeditor.h index ae620bea7..aab809c66 100644 --- a/sources/elementscategoryeditor.h +++ b/sources/elementscategoryeditor.h @@ -27,9 +27,9 @@ class QDialogButtonBox; class QLabel; /** - * @brief The ElementsCategoryEditor class - * This class provides a dialog to edit an existing category or create a new one. - */ + @brief The ElementsCategoryEditor class + This class provides a dialog to edit an existing category or create a new one. +*/ class ElementsCategoryEditor : public QDialog { Q_OBJECT diff --git a/sources/elementscollectioncache.cpp b/sources/elementscollectioncache.cpp index 0b293d426..3c8189dfc 100644 --- a/sources/elementscollectioncache.cpp +++ b/sources/elementscollectioncache.cpp @@ -150,14 +150,14 @@ QString ElementsCollectionCache::pixmapStorageFormat() const { } /** - * @brief ElementsCollectionCache::fetchElement - * Retrieve the data for a given element, using the cache if available, - * filling it otherwise. Data are then available through pixmap() and name() methods. - * @param location The definition of an element. - * @see pixmap() - * @see name() - * @return True if the retrieval succeeded, false otherwise. - */ + @brief ElementsCollectionCache::fetchElement + Retrieve the data for a given element, using the cache if available, + filling it otherwise. Data are then available through pixmap() and name() methods. + @param location The definition of an element. + @see pixmap() + @see name() + @return True if the retrieval succeeded, false otherwise. +*/ bool ElementsCollectionCache::fetchElement(ElementsLocation &location) { // can we use the cache with this element? @@ -222,13 +222,13 @@ bool ElementsCollectionCache::fetchData(const ElementsLocation &location) { } /** - * @brief ElementsCollectionCache::fetchNameFromCache - * Retrieve the name for an element, given its path and uuid - * The value is then available through the name() method. - * @param path : Element path (as obtained using ElementsLocation::toString()) - * @param uuid : Element uuid - * @return True if the retrieval succeeded, false otherwise. - */ + @brief ElementsCollectionCache::fetchNameFromCache + Retrieve the name for an element, given its path and uuid + The value is then available through the name() method. + @param path : Element path (as obtained using ElementsLocation::toString()) + @param uuid : Element uuid + @return True if the retrieval succeeded, false otherwise. +*/ bool ElementsCollectionCache::fetchNameFromCache(const QString &path, const QUuid &uuid) { select_name_ -> bindValue(":path", path); @@ -250,13 +250,13 @@ bool ElementsCollectionCache::fetchNameFromCache(const QString &path, const QUui } /** - * @brief ElementsCollectionCache::fetchPixmapFromCache - * Retrieve the pixmap for an element, given its path and uuid. - * It is then available through the pixmap() method. - * @param path : Element path (as obtained using ElementsLocation::toString()) - * @param uuid : Element uuid - * @return True if the retrieval succeeded, false otherwise. - */ + @brief ElementsCollectionCache::fetchPixmapFromCache + Retrieve the pixmap for an element, given its path and uuid. + It is then available through the pixmap() method. + @param path : Element path (as obtained using ElementsLocation::toString()) + @param uuid : Element uuid + @return True if the retrieval succeeded, false otherwise. +*/ bool ElementsCollectionCache::fetchPixmapFromCache(const QString &path, const QUuid &uuid) { select_pixmap_ -> bindValue(":path", path); @@ -280,13 +280,13 @@ bool ElementsCollectionCache::fetchPixmapFromCache(const QString &path, const QU } /** - * @brief ElementsCollectionCache::cacheName - * Cache the current (i.e. last retrieved) name The cache entry will use the locale set via setLocale(). - * @param path : Element path (as obtained using ElementsLocation::toString()) - * @param uuid :Element uuid - * @return True if the caching succeeded, false otherwise. - * @see name() - */ + @brief ElementsCollectionCache::cacheName + Cache the current (i.e. last retrieved) name The cache entry will use the locale set via setLocale(). + @param path : Element path (as obtained using ElementsLocation::toString()) + @param uuid :Element uuid + @return True if the caching succeeded, false otherwise. + @see name() +*/ bool ElementsCollectionCache::cacheName(const QString &path, const QUuid &uuid) { insert_name_ -> bindValue(":path", path); @@ -302,13 +302,13 @@ bool ElementsCollectionCache::cacheName(const QString &path, const QUuid &uuid) } /** - * @brief ElementsCollectionCache::cachePixmap - * Cache the current (i.e. last retrieved) pixmap - * @param path : Element path (as obtained using ElementsLocation::toString()) - * @param uuid : Element uuid - * @return True if the caching succeeded, false otherwise. - * @see pixmap() - */ + @brief ElementsCollectionCache::cachePixmap + Cache the current (i.e. last retrieved) pixmap + @param path : Element path (as obtained using ElementsLocation::toString()) + @param uuid : Element uuid + @return True if the caching succeeded, false otherwise. + @see pixmap() +*/ bool ElementsCollectionCache::cachePixmap(const QString &path, const QUuid &uuid) { QByteArray ba; diff --git a/sources/elementsmover.cpp b/sources/elementsmover.cpp index 3452f427f..0ddd63ff1 100644 --- a/sources/elementsmover.cpp +++ b/sources/elementsmover.cpp @@ -28,8 +28,8 @@ #include "elementtextitemgroup.h" /** - * @brief ElementsMover::ElementsMover Constructor - */ + @brief ElementsMover::ElementsMover Constructor +*/ ElementsMover::ElementsMover() : movement_running_(false), current_movement_(), @@ -41,27 +41,27 @@ ElementsMover::ElementsMover() : } /** - * @brief ElementsMover::~ElementsMover Destructor - */ + @brief ElementsMover::~ElementsMover Destructor +*/ ElementsMover::~ElementsMover() { } /** - * @brief ElementsMover::isReady - * @return True if this element mover is ready to be used. - * A element mover is ready when the previous managed movement is finish. - */ + @brief ElementsMover::isReady + @return True if this element mover is ready to be used. + A element mover is ready when the previous managed movement is finish. +*/ bool ElementsMover::isReady() const { return(!movement_running_); } /** - * @brief ElementsMover::beginMovement - * Start a new movement - * @param diagram diagram where the movement is applied - * @param driver_item item moved by mouse and don't be moved by Element mover - * @return the numbers of items to be moved or -1 if movement can't be init. - */ + @brief ElementsMover::beginMovement + Start a new movement + @param diagram diagram where the movement is applied + @param driver_item item moved by mouse and don't be moved by Element mover + @return the numbers of items to be moved or -1 if movement can't be init. +*/ int ElementsMover::beginMovement(Diagram *diagram, QGraphicsItem *driver_item) { // They must be no movement in progress @@ -105,10 +105,10 @@ int ElementsMover::beginMovement(Diagram *diagram, QGraphicsItem *driver_item) } /** - * @brief ElementsMover::continueMovement - * Add a move to the current movement. - * @param movement movement to applied - */ + @brief ElementsMover::continueMovement + Add a move to the current movement. + @param movement movement to applied +*/ void ElementsMover::continueMovement(const QPointF &movement) { if (!movement_running_ || movement.isNull()) return; @@ -142,11 +142,11 @@ void ElementsMover::continueMovement(const QPointF &movement) } /** - * @brief ElementsMover::endMovement - * Ended the current movement by creating an undo added to the undostack of the diagram. - * If there is only one element moved, we try to auto-connect new conductor from this element - * and other possible element. - */ + @brief ElementsMover::endMovement + Ended the current movement by creating an undo added to the undostack of the diagram. + If there is only one element moved, we try to auto-connect new conductor from this element + and other possible element. +*/ void ElementsMover::endMovement() { // A movement must be inited diff --git a/sources/elementspanel.cpp b/sources/elementspanel.cpp index 6b66b740c..f855ccc08 100644 --- a/sources/elementspanel.cpp +++ b/sources/elementspanel.cpp @@ -186,10 +186,10 @@ bool ElementsPanel::matchesFilter(const QTreeWidgetItem *item, const QString& fi } /** - * @brief ElementsPanel::reload - * Reload the elements tree - * @param reload_collections true for read all collections since their sources (files, projects ...) - */ + @brief ElementsPanel::reload + Reload the elements tree + @param reload_collections true for read all collections since their sources (files, projects ...) +*/ void ElementsPanel::reload(bool reload_collections) { Q_UNUSED(reload_collections); diff --git a/sources/elementspanelwidget.cpp b/sources/elementspanelwidget.cpp index e3a7a3ed4..8282be4f0 100644 --- a/sources/elementspanelwidget.cpp +++ b/sources/elementspanelwidget.cpp @@ -215,7 +215,7 @@ void ElementsPanelWidget::deleteDiagram() { /** Emet le signal requestForDiagramMoveUpTop avec le schema selectionne -+ */ ++*/ void ElementsPanelWidget::moveDiagramUpTop() { if (Diagram *selected_diagram = elements_panel -> selectedDiagram()) { emit(requestForDiagramMoveUpTop(selected_diagram)); diff --git a/sources/elementtextpattern.cpp b/sources/elementtextpattern.cpp index b1253f948..22d2da5ae 100644 --- a/sources/elementtextpattern.cpp +++ b/sources/elementtextpattern.cpp @@ -35,10 +35,10 @@ #include /** - * @brief ExportElementTextPattern::ExportElementTextPattern - * Constructor - * @param elmt - */ + @brief ExportElementTextPattern::ExportElementTextPattern + Constructor + @param elmt +*/ ExportElementTextPattern::ExportElementTextPattern(Element *elmt) : m_element(elmt) { @@ -74,10 +74,10 @@ ExportElementTextPattern::ExportElementTextPattern(Element *elmt) : } /** - * @brief ExportElementTextConf::getName - * Open a dialog to let user set the name of the conf and return it - * @return - */ + @brief ExportElementTextConf::getName + Open a dialog to let user set the name of the conf and return it + @return +*/ QString ExportElementTextPattern::getName(bool &ok) const { QString text = QInputDialog::getText(parentWidget(), @@ -159,11 +159,11 @@ ImportElementTextPattern::ImportElementTextPattern(Element *elmt): } /** - * @brief ImportElementTextPattern::getName - * Open a dialog to let user select a conf - * @param ok - * @return - */ + @brief ImportElementTextPattern::getName + Open a dialog to let user select a conf + @param ok + @return +*/ QString ImportElementTextPattern::getName(const QStringList& list, bool *ok, bool *erase) const { return ImportElementTextPatternDialog::getItem(parentWidget(), @@ -185,11 +185,11 @@ QWidget *ImportElementTextPattern::parentWidget() const /** - * @brief ImportElementTextPattern::apply - * Apply the user choice - * @param name : the name of the selected pattern - * @param erase : erase the existing texts and groups of element. - */ + @brief ImportElementTextPattern::apply + Apply the user choice + @param name : the name of the selected pattern + @param erase : erase the existing texts and groups of element. +*/ void ImportElementTextPattern::apply(QString name, bool erase) const { if(!name.endsWith(".xml")) diff --git a/sources/elementtextsmover.cpp b/sources/elementtextsmover.cpp index 878255199..cb3cca76f 100644 --- a/sources/elementtextsmover.cpp +++ b/sources/elementtextsmover.cpp @@ -23,26 +23,26 @@ #include /** - * @brief ElementTextsMover::ElementTextsMover - */ + @brief ElementTextsMover::ElementTextsMover +*/ ElementTextsMover::ElementTextsMover() {} /** - * @brief ElementTextsMover::isReady - * @return true if this ElementTextsMover is ready to process a new movement. - * False if this ElementTextsMover is actually process a movement - */ + @brief ElementTextsMover::isReady + @return true if this ElementTextsMover is ready to process a new movement. + False if this ElementTextsMover is actually process a movement +*/ bool ElementTextsMover::isReady() const { return(!m_movement_running); } /** - * @brief ElementTextsMover::beginMovement - * Begin a movement - * @param diagram : diagram where the movement is apply - * @param driver_item : item moved by the mouse - * @return : the number of moved text (driver_item include), or -1 if this ElementTextsMover can't begin a movement - */ + @brief ElementTextsMover::beginMovement + Begin a movement + @param diagram : diagram where the movement is apply + @param driver_item : item moved by the mouse + @return : the number of moved text (driver_item include), or -1 if this ElementTextsMover can't begin a movement +*/ int ElementTextsMover::beginMovement(Diagram *diagram, QGraphicsItem *driver_item) { if (m_movement_running || !diagram) @@ -101,9 +101,9 @@ void ElementTextsMover::continueMovement(QGraphicsSceneMouseEvent *event) } /** - * @brief ElementTextsMover::endMovement - * Finish the movement by pushing an undo command to the parent diagram of text item - */ + @brief ElementTextsMover::endMovement + Finish the movement by pushing an undo command to the parent diagram of text item +*/ void ElementTextsMover::endMovement() { //No movement or no items to move diff --git a/sources/exportproperties.cpp b/sources/exportproperties.cpp index 45265cf52..2dadaa24d 100644 --- a/sources/exportproperties.cpp +++ b/sources/exportproperties.cpp @@ -83,9 +83,9 @@ void ExportProperties::fromSettings(QSettings &settings, const QString &prefix) } /** - * @brief ExportProperties::defaultProperties - * @return the default properties stored in the setting file - */ + @brief ExportProperties::defaultProperties + @return the default properties stored in the setting file +*/ ExportProperties ExportProperties::defaultExportProperties() { QSettings settings; @@ -97,9 +97,9 @@ ExportProperties ExportProperties::defaultExportProperties() } /** - * @brief ExportProperties::defaultPrintProperties - * @return the default properties stored in the setting file - */ + @brief ExportProperties::defaultPrintProperties + @return the default properties stored in the setting file +*/ ExportProperties ExportProperties::defaultPrintProperties() { QSettings settings; diff --git a/sources/factory/elementfactory.cpp b/sources/factory/elementfactory.cpp index 6246b6ac6..c41c4e097 100644 --- a/sources/factory/elementfactory.cpp +++ b/sources/factory/elementfactory.cpp @@ -25,12 +25,12 @@ ElementFactory* ElementFactory::factory_ = nullptr; /** - * @brief ElementFactory::createElement - * @param location create element at this location - * @param qgi parent item for this elemnt - * @param state state of the creation - * @return the element or 0 - */ + @brief ElementFactory::createElement + @param location create element at this location + @param qgi parent item for this elemnt + @param state state of the creation + @return the element or 0 +*/ Element * ElementFactory::createElement(const ElementsLocation &location, QGraphicsItem *qgi, int *state) { if (Q_UNLIKELY( !(location.isElement() && location.exist()) )) diff --git a/sources/factory/elementfactory.h b/sources/factory/elementfactory.h index 9dc4a36df..9d5d71889 100644 --- a/sources/factory/elementfactory.h +++ b/sources/factory/elementfactory.h @@ -25,12 +25,11 @@ class ElementsLocation; class QGraphicsItem; /** - * @brief The ElementFactory class - *this class is a pattern factory and also a singleton factory. - *this class create new instance of herited class element like - *simple element or report element. - * - */ + @brief The ElementFactory class + this class is a pattern factory and also a singleton factory. + this class create new instance of herited class element like + simple element or report element. +*/ class ElementFactory { //methods for singleton pattern diff --git a/sources/factory/elementpicturefactory.cpp b/sources/factory/elementpicturefactory.cpp index 2cb0b11bc..2529cbe96 100644 --- a/sources/factory/elementpicturefactory.cpp +++ b/sources/factory/elementpicturefactory.cpp @@ -32,13 +32,13 @@ ElementPictureFactory* ElementPictureFactory::m_factory = nullptr; /** - * @brief ElementPictureFactory::getPictures - * Set the picture of the element at location. - * Note, picture can be null - * @param location - * @param picture - * @param low_picture - */ + @brief ElementPictureFactory::getPictures + Set the picture of the element at location. + Note, picture can be null + @param location + @param picture + @param low_picture +*/ void ElementPictureFactory::getPictures(const ElementsLocation &location, QPicture &picture, QPicture &low_picture) { if(!location.exist()) { @@ -68,11 +68,11 @@ void ElementPictureFactory::getPictures(const ElementsLocation &location, QPictu } /** - * @brief ElementPictureFactory::pixmap - * @param location - * @return the pixmap of the element at @location - * Note pixmap can be null - */ + @brief ElementPictureFactory::pixmap + @param location + @return the pixmap of the element at @location + Note pixmap can be null +*/ QPixmap ElementPictureFactory::pixmap(const ElementsLocation &location) { QUuid uuid = location.uuid(); @@ -113,10 +113,10 @@ QPixmap ElementPictureFactory::pixmap(const ElementsLocation &location) /** - * @brief ElementPictureFactory::getPrimitives - * @param location - * @return The primtive used to draw the element at @location - */ + @brief ElementPictureFactory::getPrimitives + @param location + @return The primtive used to draw the element at @location +*/ ElementPictureFactory::primitives ElementPictureFactory::getPrimitives(const ElementsLocation &location) { if(!m_primitives_H.contains(location.uuid())) @@ -132,15 +132,15 @@ ElementPictureFactory::~ElementPictureFactory() { } /** - * @brief ElementPictureFactory::build - * Build the picture from location. - * @param location - * @param picture - * @param low_picture - * if @picture and/or @low_picture are not null this function draw on it and don't store it. - * if null, this function create a QPicture for normal and low zoom, draw on it and store it in m_pictures_H and m_low_pictures_H - * @return - */ + @brief ElementPictureFactory::build + Build the picture from location. + @param location + @param picture + @param low_picture + if @picture and/or @low_picture are not null this function draw on it and don't store it. + if null, this function create a QPicture for normal and low zoom, draw on it and store it in m_pictures_H and m_low_pictures_H + @return +*/ bool ElementPictureFactory::build(const ElementsLocation &location, QPicture *picture, QPicture *low_picture) { QDomElement dom = location.xml(); @@ -542,11 +542,11 @@ void ElementPictureFactory::parseText(const QDomElement &dom, QPainter &painter, } /** - * @brief ElementPictureFactory::setPainterStyle - * apply the style store in dom to painter. - * @param dom - * @param painter - */ + @brief ElementPictureFactory::setPainterStyle + apply the style store in dom to painter. + @param dom + @param painter +*/ void ElementPictureFactory::setPainterStyle(const QDomElement &dom, QPainter &painter) const { QPen pen = painter.pen(); diff --git a/sources/factory/elementpicturefactory.h b/sources/factory/elementpicturefactory.h index 811cf99fb..03b80417b 100644 --- a/sources/factory/elementpicturefactory.h +++ b/sources/factory/elementpicturefactory.h @@ -30,10 +30,10 @@ class QPainter; class QGraphicsSimpleTextItem; /** - * @brief The ElementPictureFactory class - * This class is singleton factory, use - * to create and get the picture use by elements - */ + @brief The ElementPictureFactory class + This class is singleton factory, use + to create and get the picture use by elements +*/ class ElementPictureFactory { public : @@ -49,9 +49,9 @@ class ElementPictureFactory /** - * @brief instance - * @return The instance of the factory - */ + @brief instance + @return The instance of the factory + */ static ElementPictureFactory* instance() { static QMutex mutex; @@ -67,9 +67,9 @@ class ElementPictureFactory } /** - * @brief dropInstance - * Drop the instance of factory - */ + @brief dropInstance + Drop the instance of factory + */ static void dropInstance() { static QMutex mutex; diff --git a/sources/factory/propertieseditorfactory.cpp b/sources/factory/propertieseditorfactory.cpp index 6966fec09..cf4f7c36f 100644 --- a/sources/factory/propertieseditorfactory.cpp +++ b/sources/factory/propertieseditorfactory.cpp @@ -36,12 +36,12 @@ #include "projectdbmodel.h" /** - * @brief PropertiesEditorFactory::propertiesEditor - * @param model : the model to be edited - * @param editor : if the properties editor to be created is the same class as @editor, the this function set @item as edited item of @editor and return editor - * @param parent : parent widget of the returned editor - * @return an editor or nullptr - */ + @brief PropertiesEditorFactory::propertiesEditor + @param model : the model to be edited + @param editor : if the properties editor to be created is the same class as @editor, the this function set @item as edited item of @editor and return editor + @param parent : parent widget of the returned editor + @return an editor or nullptr +*/ PropertiesEditorWidget *PropertiesEditorFactory::propertiesEditor(QAbstractItemModel *model, PropertiesEditorWidget *editor, QWidget *parent) { Q_UNUSED(model) diff --git a/sources/factory/qetgraphicstablefactory.cpp b/sources/factory/qetgraphicstablefactory.cpp index e120e1621..9a85d1e2f 100644 --- a/sources/factory/qetgraphicstablefactory.cpp +++ b/sources/factory/qetgraphicstablefactory.cpp @@ -34,11 +34,11 @@ QetGraphicsTableFactory::QetGraphicsTableFactory() } /** - * @brief QetGraphicsTableFactory::createAndAddNomenclature - * Open a dialog for ask user the config of the table ,create a nomenclature table - * and add it to diagram @diagram; - * @param diagram - */ + @brief QetGraphicsTableFactory::createAndAddNomenclature + Open a dialog for ask user the config of the table ,create a nomenclature table + and add it to diagram @diagram; + @param diagram +*/ void QetGraphicsTableFactory::createAndAddNomenclature(Diagram *diagram) { QScopedPointer d(new AddTableDialog(new ElementQueryWidget(), diagram->views().first())); @@ -50,11 +50,11 @@ void QetGraphicsTableFactory::createAndAddNomenclature(Diagram *diagram) } /** - * @brief QetGraphicsTableFactory::createAndAddSummary - * Open a dialog for ask user the config of the table ,create a summary table - * and add it to diagram @diagram; - * @param diagram - */ + @brief QetGraphicsTableFactory::createAndAddSummary + Open a dialog for ask user the config of the table ,create a summary table + and add it to diagram @diagram; + @param diagram +*/ void QetGraphicsTableFactory::createAndAddSummary(Diagram *diagram) { QScopedPointer d(new AddTableDialog(new SummaryQueryWidget(), diagram->views().first())); @@ -104,14 +104,14 @@ void QetGraphicsTableFactory::create(Diagram *diagram, AddTableDialog *dialog) } /** - * @brief QetGraphicsTableFactory::newTable - * Create a new table . - * @param diagram : Diagram where we must add the new table. - * @param dialog : dialog conf, it's used to setup the model. - * @param previous_table : If you know that the new table will have a previous table and you already now the previous table, - * set it now they will improve time needed for creating the new table by avoiding to create a new model. - * @return the new table - */ + @brief QetGraphicsTableFactory::newTable + Create a new table . + @param diagram : Diagram where we must add the new table. + @param dialog : dialog conf, it's used to setup the model. + @param previous_table : If you know that the new table will have a previous table and you already now the previous table, + set it now they will improve time needed for creating the new table by avoiding to create a new model. + @return the new table +*/ QetGraphicsTableItem *QetGraphicsTableFactory::newTable(Diagram *diagram, AddTableDialog *dialog, QetGraphicsTableItem *previous_table) { auto table = new QetGraphicsTableItem(); diff --git a/sources/factory/qetgraphicstablefactory.h b/sources/factory/qetgraphicstablefactory.h index 868467623..c245d26c2 100644 --- a/sources/factory/qetgraphicstablefactory.h +++ b/sources/factory/qetgraphicstablefactory.h @@ -23,8 +23,8 @@ class QetGraphicsTableItem; class AddTableDialog; /** - * @brief The QetGraphicsTableFactory class - */ + @brief The QetGraphicsTableFactory class +*/ class QetGraphicsTableFactory { public: diff --git a/sources/factory/ui/addtabledialog.cpp b/sources/factory/ui/addtabledialog.cpp index b50eba5a9..3201471f2 100644 --- a/sources/factory/ui/addtabledialog.cpp +++ b/sources/factory/ui/addtabledialog.cpp @@ -24,11 +24,11 @@ #include /** - * @brief AddTableDialog::AddTableDialog - * @param content_widget : the widget to display in the "content" tab. - * This dialog take ownership of @content_widget. - * @param parent : parent widget. - */ + @brief AddTableDialog::AddTableDialog + @param content_widget : the widget to display in the "content" tab. + This dialog take ownership of @content_widget. + @param parent : parent widget. +*/ AddTableDialog::AddTableDialog(QWidget *content_widget, QWidget *parent) : QDialog(parent), ui(new Ui::AddTableDialog) @@ -46,57 +46,57 @@ AddTableDialog::AddTableDialog(QWidget *content_widget, QWidget *parent) : } /** - * @brief AddTableDialog::~AddNomenclatureDialog - */ + @brief AddTableDialog::~AddNomenclatureDialog +*/ AddTableDialog::~AddTableDialog() { delete ui; } /** - * @brief AddTableDialog::setQueryWidget - * Not implemented yet - * @param widget - */ + @brief AddTableDialog::setQueryWidget + Not implemented yet + @param widget +*/ void AddTableDialog::setQueryWidget(QWidget *widget) { Q_UNUSED(widget) } /** - * @brief AddTableDialog::adjustTableToFolio - * @return - */ + @brief AddTableDialog::adjustTableToFolio + @return +*/ bool AddTableDialog::adjustTableToFolio() const { return ui->m_adjust_table_size_cb->isChecked(); } /** - * @brief AddTableDialog::addNewTableToNewDiagram - * @return - */ + @brief AddTableDialog::addNewTableToNewDiagram + @return +*/ bool AddTableDialog::addNewTableToNewDiagram() const { return ui->m_add_table_and_folio->isChecked(); } /** - * @brief AddTableDialog::tableName - * @return - */ + @brief AddTableDialog::tableName + @return +*/ QString AddTableDialog::tableName() const { return ui->m_table_name_le->text(); } /** - * @brief AddTableDialog::headerMargins - * @return - */ + @brief AddTableDialog::headerMargins + @return +*/ QMargins AddTableDialog::headerMargins() const { return m_header_margins; } /** - * @brief AddTableDialog::headerAlignment - * @return - */ + @brief AddTableDialog::headerAlignment + @return +*/ Qt::Alignment AddTableDialog::headerAlignment() const { switch (ui->m_header_alignment_cb->currentIndex()) { @@ -110,25 +110,25 @@ Qt::Alignment AddTableDialog::headerAlignment() const } /** - * @brief AddTableDialog::headerFont - * @return - */ + @brief AddTableDialog::headerFont + @return +*/ QFont AddTableDialog::headerFont() const { return m_header_font; } /** - * @brief AddTableDialog::tableMargins - * @return - */ + @brief AddTableDialog::tableMargins + @return +*/ QMargins AddTableDialog::tableMargins() const { return m_table_margins; } /** - * @brief AddTableDialog::tableAlignment - * @return - */ + @brief AddTableDialog::tableAlignment + @return +*/ Qt::Alignment AddTableDialog::tableAlignment() const { switch (ui->m_table_alignment_cb->currentIndex()) { @@ -142,9 +142,9 @@ Qt::Alignment AddTableDialog::tableAlignment() const } /** - * @brief AddTableDialog::tableFont - * @return - */ + @brief AddTableDialog::tableFont + @return +*/ QFont AddTableDialog::tableFont() const { return m_table_font; } diff --git a/sources/factory/ui/addtabledialog.h b/sources/factory/ui/addtabledialog.h index 484e44d84..0aca20e8e 100644 --- a/sources/factory/ui/addtabledialog.h +++ b/sources/factory/ui/addtabledialog.h @@ -27,13 +27,13 @@ class AddTableDialog; } /** - * @brief The AddTableDialog class - * Provide a dialog used to edit the properties of table befor adding to a diagram. - * The main difference betwen this dialog and the widget used to edit the properties of table - * is that the dialog have two extra check box. - * One for adjust the size of the table to diagram - * Second for add new tables on new folios if the table can't fit into diagram - */ + @brief The AddTableDialog class + Provide a dialog used to edit the properties of table befor adding to a diagram. + The main difference betwen this dialog and the widget used to edit the properties of table + is that the dialog have two extra check box. + One for adjust the size of the table to diagram + Second for add new tables on new folios if the table can't fit into diagram +*/ class AddTableDialog : public QDialog { Q_OBJECT diff --git a/sources/machine_info.cpp b/sources/machine_info.cpp index 37ec10778..77fa4de1f 100644 --- a/sources/machine_info.cpp +++ b/sources/machine_info.cpp @@ -258,7 +258,7 @@ void Machine_info::init_get_cpu_info_macos() /** @brief Machine_info::i_max_screen_width @return max screen width - */ +*/ int32_t Machine_info::i_max_screen_width() { return pc.screen.Max_width; diff --git a/sources/newelementwizard.cpp b/sources/newelementwizard.cpp index a9cf648f0..65113e8a5 100644 --- a/sources/newelementwizard.cpp +++ b/sources/newelementwizard.cpp @@ -55,10 +55,10 @@ NewElementWizard::~NewElementWizard() { } /** - * @brief NewElementWizard::preselectedLocation - * Select item in the tree view represented by location, - * @param location - */ + @brief NewElementWizard::preselectedLocation + Select item in the tree view represented by location, + @param location +*/ void NewElementWizard::preselectedLocation(const ElementsLocation &location) { QModelIndex index = m_model->indexFromLocation(location); @@ -69,9 +69,9 @@ void NewElementWizard::preselectedLocation(const ElementsLocation &location) } /** - * @brief NewElementWizard::buildStep1 - * @return - */ + @brief NewElementWizard::buildStep1 + @return +*/ QWizardPage *NewElementWizard::buildStep1() { QWizardPage *page = new QWizardPage(); @@ -96,9 +96,9 @@ QWizardPage *NewElementWizard::buildStep1() } /** - * @brief NewElementWizard::buildStep2 - * @return - */ + @brief NewElementWizard::buildStep2 + @return +*/ QWizardPage *NewElementWizard::buildStep2() { QWizardPage *page = new QWizardPage(); page -> setProperty("WizardState", Filename); @@ -120,9 +120,9 @@ QWizardPage *NewElementWizard::buildStep2() { } /** - * @brief NewElementWizard::buildStep3 - * @return - */ + @brief NewElementWizard::buildStep3 + @return +*/ QWizardPage *NewElementWizard::buildStep3() { QWizardPage *page = new QWizardPage(); page -> setProperty("WizardState", Names); @@ -141,9 +141,9 @@ QWizardPage *NewElementWizard::buildStep3() { } /** - * @brief NewElementWizard::validateCurrentPage - * @return true if the current step is valid - */ + @brief NewElementWizard::validateCurrentPage + @return true if the current step is valid +*/ bool NewElementWizard::validateCurrentPage() { WizardState wizard_state = static_cast(currentPage() -> property("WizardState").toInt()); @@ -166,10 +166,10 @@ bool NewElementWizard::validateCurrentPage() } /** - * @brief NewElementWizard::validStep1 - * Valid the setp 1 - * @return trie if the step is valid. - */ + @brief NewElementWizard::validStep1 + Valid the setp 1 + @return trie if the step is valid. +*/ bool NewElementWizard::validStep1() { //They must be one directory selected @@ -198,10 +198,10 @@ bool NewElementWizard::validStep1() } /** - * @brief NewElementWizard::validStep2 - * Valid the step 2 - * @return true if step is valid - */ + @brief NewElementWizard::validStep2 + Valid the step 2 + @return true if step is valid +*/ bool NewElementWizard::validStep2() { QString file_name = m_qle_filename -> text(); @@ -230,9 +230,9 @@ bool NewElementWizard::validStep2() { } /** - * @brief NewElementWizard::createNewElement - * Lauch an element editor for create the new element - */ + @brief NewElementWizard::createNewElement + Lauch an element editor for create the new element +*/ void NewElementWizard::createNewElement() { QETElementEditor *edit_new_element = new QETElementEditor(parentWidget()); edit_new_element -> setNames(m_names_list -> names()); diff --git a/sources/nomenclature.cpp b/sources/nomenclature.cpp index 97b315b17..761d9aece 100644 --- a/sources/nomenclature.cpp +++ b/sources/nomenclature.cpp @@ -81,10 +81,10 @@ bool nomenclature::saveToCSVFile() } /** - * @brief nomenclature::getNomenclature - * Create and formated a nomenclature to csv file. - * @return The QString of nomenclature - */ + @brief nomenclature::getNomenclature + Create and formated a nomenclature to csv file. + @return The QString of nomenclature +*/ QString nomenclature::getNomenclature() { //Process... @@ -161,10 +161,10 @@ QString nomenclature::getNomenclature() } /** - * @brief nomenclature::getElementInfo - * @param elmt : the element to getinfo - * @return : QString with information about element formated to csv file - */ + @brief nomenclature::getElementInfo + @param elmt : the element to getinfo + @return : QString with information about element formated to csv file +*/ QString nomenclature::getElementInfo(Element *elmt) { QString info; diff --git a/sources/projectconfigpages.cpp b/sources/projectconfigpages.cpp index a106209ae..0c769ff20 100644 --- a/sources/projectconfigpages.cpp +++ b/sources/projectconfigpages.cpp @@ -204,7 +204,7 @@ void ProjectMainConfigPage::readValuesFromProject() { /** Set the content of this page read only if the project is read only, editable if the project is editable. - */ +*/ void ProjectMainConfigPage::adjustReadOnly() { bool is_read_only = m_project -> isReadOnly(); title_value_ -> setReadOnly(is_read_only); @@ -213,11 +213,11 @@ void ProjectMainConfigPage::adjustReadOnly() { //######################################################################################// /** - * @brief ProjectAutoNumConfigPage::ProjectAutoNumConfigPage - * Default constructor - * @param project, project to edit - * @param parent, parent widget - */ + @brief ProjectAutoNumConfigPage::ProjectAutoNumConfigPage + Default constructor + @param project, project to edit + @param parent, parent widget +*/ ProjectAutoNumConfigPage::ProjectAutoNumConfigPage (QETProject *project, QWidget *parent) : ProjectConfigPage(project, parent) { @@ -227,32 +227,32 @@ ProjectAutoNumConfigPage::ProjectAutoNumConfigPage (QETProject *project, QWidget } /** - * @brief ProjectAutoNumConfigPage::title - * Title of this config page - * @return - */ + @brief ProjectAutoNumConfigPage::title + Title of this config page + @return +*/ QString ProjectAutoNumConfigPage::title() const { return tr("Numérotation auto"); } /** - * @brief ProjectAutoNumConfigPage::icon - * Icon of this config pafe - * @return - */ + @brief ProjectAutoNumConfigPage::icon + Icon of this config pafe + @return +*/ QIcon ProjectAutoNumConfigPage::icon() const { return QIcon (QET::Icons::AutoNum); } /** - * @brief ProjectAutoNumConfigPage::applyProjectConf - */ + @brief ProjectAutoNumConfigPage::applyProjectConf +*/ void ProjectAutoNumConfigPage::applyProjectConf() {} /** - * @brief ProjectAutoNumConfigPage::initWidgets - * Init some widget of this page - */ + @brief ProjectAutoNumConfigPage::initWidgets + Init some widget of this page +*/ void ProjectAutoNumConfigPage::initWidgets() { QTabWidget *tab_widget = new QTabWidget(this); @@ -283,9 +283,9 @@ void ProjectAutoNumConfigPage::initWidgets() } /** - * @brief ProjectAutoNumConfigPage::readValuesFromProject - * Read value stored on project, and update display - */ + @brief ProjectAutoNumConfigPage::readValuesFromProject + Read value stored on project, and update display +*/ void ProjectAutoNumConfigPage::readValuesFromProject() { //Conductor Tab @@ -305,16 +305,16 @@ void ProjectAutoNumConfigPage::readValuesFromProject() } /** - * @brief ProjectAutoNumConfigPage::adjustReadOnly - * set this config page disable if project is read only - */ + @brief ProjectAutoNumConfigPage::adjustReadOnly + set this config page disable if project is read only +*/ void ProjectAutoNumConfigPage::adjustReadOnly() { } /** - * @brief ProjectAutoNumConfigPage::buildConnections - * setup some connections - */ + @brief ProjectAutoNumConfigPage::buildConnections + setup some connections +*/ void ProjectAutoNumConfigPage::buildConnections() { //Management Tab @@ -340,30 +340,30 @@ void ProjectAutoNumConfigPage::buildConnections() } /** - * @brief ProjectAutoNumConfigPage::updateContext_conductor - * Display the current selected context for conductor - * @param str, key of context stored in project - */ + @brief ProjectAutoNumConfigPage::updateContext_conductor + Display the current selected context for conductor + @param str, key of context stored in project +*/ void ProjectAutoNumConfigPage::updateContextConductor(const QString& str) { if (str == tr("Nom de la nouvelle numérotation")) m_saw_conductor -> setContext(NumerotationContext()); else m_saw_conductor ->setContext(m_project->conductorAutoNum(str)); } /** - * @brief ProjectAutoNumConfigPage::updateContext_folio - * Display the current selected context for folio - * @param str, key of context stored in project - */ + @brief ProjectAutoNumConfigPage::updateContext_folio + Display the current selected context for folio + @param str, key of context stored in project +*/ void ProjectAutoNumConfigPage::updateContextFolio(const QString& str) { if (str == tr("Nom de la nouvelle numérotation")) m_saw_folio -> setContext(NumerotationContext()); else m_saw_folio ->setContext(m_project->folioAutoNum(str)); } /** - * @brief ProjectAutoNumConfigPage::updateContextElement - * Display the current selected context for element - * @param str, key of context stored in project - */ + @brief ProjectAutoNumConfigPage::updateContextElement + Display the current selected context for element + @param str, key of context stored in project +*/ void ProjectAutoNumConfigPage::updateContextElement(const QString& str) { if (str == tr("Nom de la nouvelle numérotation")) @@ -377,9 +377,9 @@ void ProjectAutoNumConfigPage::updateContextElement(const QString& str) } /** - * @brief ProjectAutoNumConfigPage::saveContextElement - * Save the current displayed Element formula in project - */ + @brief ProjectAutoNumConfigPage::saveContextElement + Save the current displayed Element formula in project +*/ void ProjectAutoNumConfigPage::saveContextElement() { // If the text is the default text "Name of new numerotation" save the edited context @@ -408,9 +408,9 @@ void ProjectAutoNumConfigPage::saveContextElement() } /** - * @brief ProjectAutoNumConfigPage::removeContextElement - * Remove from project the current element numerotation context - */ + @brief ProjectAutoNumConfigPage::removeContextElement + Remove from project the current element numerotation context +*/ void ProjectAutoNumConfigPage::removeContextElement() { //if default text, return @@ -421,9 +421,9 @@ void ProjectAutoNumConfigPage::removeContextElement() } /** - * @brief ProjectAutoNumConfigPage::saveContext_conductor - * Save the current displayed conductor context in project - */ + @brief ProjectAutoNumConfigPage::saveContext_conductor + Save the current displayed conductor context in project +*/ void ProjectAutoNumConfigPage::saveContextConductor() { // If the text is the default text "Name of new numerotation" save the edited context @@ -451,9 +451,9 @@ void ProjectAutoNumConfigPage::saveContextConductor() } /** - * @brief ProjectAutoNumConfigPage::saveContext_folio - * Save the current displayed folio context in project - */ + @brief ProjectAutoNumConfigPage::saveContext_folio + Save the current displayed folio context in project +*/ void ProjectAutoNumConfigPage::saveContextFolio() { // If the text is the default text "Name of new numerotation" save the edited context // With the the name "No name" @@ -474,9 +474,9 @@ void ProjectAutoNumConfigPage::saveContextFolio() { } /** - * @brief ProjectAutoNumConfigPage::applyAutoNum - * Apply auto folio numbering, New Folios or Selected Folios - */ + @brief ProjectAutoNumConfigPage::applyAutoNum + Apply auto folio numbering, New Folios or Selected Folios +*/ void ProjectAutoNumConfigPage::applyAutoNum() { if (m_faw->newFolios){ @@ -498,9 +498,9 @@ void ProjectAutoNumConfigPage::applyAutoNum() { } /** - * @brief ProjectAutoNumConfigPage::applyAutoManagement - * Apply Management Options in Selected Folios - */ + @brief ProjectAutoNumConfigPage::applyAutoManagement + Apply Management Options in Selected Folios +*/ void ProjectAutoNumConfigPage::applyManagement() { int from; int to; @@ -592,9 +592,9 @@ void ProjectAutoNumConfigPage::applyManagement() { } /** - * @brief ProjectAutoNumConfigPage::removeContext - * Remove from project the current conductor numerotation context - */ + @brief ProjectAutoNumConfigPage::removeContext + Remove from project the current conductor numerotation context +*/ void ProjectAutoNumConfigPage::removeContextConductor() { //if default text, return if ( m_saw_conductor->contextComboBox()-> currentText() == tr("Nom de la nouvelle numérotation") ) return; @@ -604,9 +604,9 @@ void ProjectAutoNumConfigPage::removeContextConductor() { } /** - * @brief ProjectAutoNumConfigPage::removeContext_folio - * Remove from project the current folio numerotation context - */ + @brief ProjectAutoNumConfigPage::removeContext_folio + Remove from project the current folio numerotation context +*/ void ProjectAutoNumConfigPage::removeContextFolio() { //if default text, return if ( m_saw_folio->contextComboBox() -> currentText() == tr("Nom de la nouvelle numérotation") ) return; @@ -616,10 +616,10 @@ void ProjectAutoNumConfigPage::removeContextFolio() { } /** - * @brief ProjectAutoNumConfigPage::changeToTab - * @param tab index - * Change to Selected Tab - */ + @brief ProjectAutoNumConfigPage::changeToTab + @param tab index + Change to Selected Tab +*/ void ProjectAutoNumConfigPage::changeToTab(int i) { Q_UNUSED(i); diff --git a/sources/projectview.cpp b/sources/projectview.cpp index 434c570ab..7b54ddc1b 100644 --- a/sources/projectview.cpp +++ b/sources/projectview.cpp @@ -67,10 +67,10 @@ QETProject *ProjectView::project() { } /** - * @brief ProjectView::setProject - * Set the project display by the project view - * @param project - */ + @brief ProjectView::setProject + Set the project display by the project view + @param project +*/ void ProjectView::setProject(QETProject *project) { if (!m_project) @@ -99,9 +99,9 @@ QList ProjectView::diagram_views() const { } /** - * @brief ProjectView::currentDiagram - * @return The current active diagram view or nullptr if there isn't diagramView in this project view. - */ + @brief ProjectView::currentDiagram + @return The current active diagram view or nullptr if there isn't diagramView in this project view. +*/ DiagramView *ProjectView::currentDiagram() const { int current_tab_index = m_tab -> currentIndex(); if (current_tab_index == -1) @@ -276,11 +276,11 @@ bool ProjectView::tryClosingElementEditors() { } /** - * @brief ProjectView::tryClosingDiagrams - * try to close this project, if diagram or project option are changed - * a dialog ask if user want to save the modification. - * @return the answer of dialog or discard if no change. - */ + @brief ProjectView::tryClosingDiagrams + try to close this project, if diagram or project option are changed + a dialog ask if user want to save the modification. + @return the answer of dialog or discard if no change. +*/ int ProjectView::tryClosingDiagrams() { if (!m_project) return(QMessageBox::Discard); @@ -345,10 +345,10 @@ QETResult ProjectView::noProjectResult() const { } /** - * @brief ProjectView::removeDiagram - * Remove a diagram (folio) of the project - * @param diagram_view : diagram view to remove - */ + @brief ProjectView::removeDiagram + Remove a diagram (folio) of the project + @param diagram_view : diagram view to remove +*/ void ProjectView::removeDiagram(DiagramView *diagram_view) { if (!diagram_view) @@ -493,8 +493,8 @@ void ProjectView::moveDiagramDown(Diagram *diagram) { } /* - * Deplace le schema diagram_view vers le haut / la gauche en position 0 - */ + Deplace le schema diagram_view vers le haut / la gauche en position 0 +*/ void ProjectView::moveDiagramUpTop(DiagramView *diagram_view) { if (!diagram_view) return; @@ -508,8 +508,8 @@ void ProjectView::moveDiagramUpTop(DiagramView *diagram_view) } /* - * Deplace le schema diagram vers le haut / la gauche en position 0 - */ + Deplace le schema diagram vers le haut / la gauche en position 0 +*/ void ProjectView::moveDiagramUpTop(Diagram *diagram) { moveDiagramUpTop(findDiagram(diagram)); @@ -782,11 +782,11 @@ void ProjectView::initLayout() { /** - * @brief ProjectView::loadDiagrams - * Load diagrams of project. - * We create a diagram view for each diagram, - * and add it to the project view. - */ + @brief ProjectView::loadDiagrams + Load diagrams of project. + We create a diagram view for each diagram, + and add it to the project view. +*/ void ProjectView::loadDiagrams() { if (!m_project) return; @@ -822,9 +822,9 @@ void ProjectView::loadDiagrams() } /** - * @brief ProjectView::updateWindowTitle - * Update the project view title - */ + @brief ProjectView::updateWindowTitle + Update the project view title +*/ void ProjectView::updateWindowTitle() { QString title; if (m_project) { @@ -852,10 +852,10 @@ void ProjectView::adjustReadOnlyState() { } /** - * @brief ProjectView::diagramAdded - * Slot called when qetproject emit diagramAdded - * @param diagram - */ + @brief ProjectView::diagramAdded + Slot called when qetproject emit diagramAdded + @param diagram +*/ void ProjectView::diagramAdded(Diagram *diagram) { auto dv = new DiagramView(diagram); @@ -881,10 +881,10 @@ void ProjectView::diagramAdded(Diagram *diagram) } /** - * @brief ProjectView::updateTabTitle - * Update the title of the tab which display the diagram view @diagram_view. - * @param diagram : The diagram view. - */ + @brief ProjectView::updateTabTitle + Update the title of the tab which display the diagram view @diagram_view. + @param diagram : The diagram view. +*/ void ProjectView::updateTabTitle(DiagramView *diagram_view) { int diagram_tab_id = m_diagram_ids.key(diagram_view, -1); @@ -911,9 +911,9 @@ void ProjectView::updateTabTitle(DiagramView *diagram_view) } /** - * @brief ProjectView::updateAllTabsTitle - * Update all tabs title - */ + @brief ProjectView::updateAllTabsTitle + Update all tabs title +*/ void ProjectView::updateAllTabsTitle() { for (DiagramView *dv : m_diagram_ids.values()) @@ -969,12 +969,12 @@ void ProjectView::rebuildDiagramsMap() { } /** - * @brief ProjectView::tabChanged - * Manage the tab change. - * If tab_id == -1 (there is no diagram opened), - * we display the fallback widget. - * @param tab_id - */ + @brief ProjectView::tabChanged + Manage the tab change. + If tab_id == -1 (there is no diagram opened), + we display the fallback widget. + @param tab_id +*/ void ProjectView::tabChanged(int tab_id) { if (tab_id == -1) diff --git a/sources/properties/reportproperties.cpp b/sources/properties/reportproperties.cpp index 61b913570..973e1857a 100644 --- a/sources/properties/reportproperties.cpp +++ b/sources/properties/reportproperties.cpp @@ -22,9 +22,9 @@ ReportProperties::ReportProperties() {} /** - * @brief ReportProperties::defaultProperties - * @return the default properties stored in the setting file - */ + @brief ReportProperties::defaultProperties + @return the default properties stored in the setting file +*/ QString ReportProperties::defaultProperties() { QSettings settings; diff --git a/sources/properties/xrefproperties.cpp b/sources/properties/xrefproperties.cpp index 538549761..f4116abe7 100644 --- a/sources/properties/xrefproperties.cpp +++ b/sources/properties/xrefproperties.cpp @@ -20,9 +20,9 @@ #include /** - * @brief XRefProperties::XRefProperties - * Default Constructor - */ + @brief XRefProperties::XRefProperties + Default Constructor +*/ XRefProperties::XRefProperties() { m_show_power_ctc = true; @@ -36,11 +36,11 @@ XRefProperties::XRefProperties() } /** - * @brief XRefProperties::toSettings - * Save to settings - * @param settings: QSettings to use - * @param prefix: prefix before properties name - */ + @brief XRefProperties::toSettings + Save to settings + @param settings: QSettings to use + @param prefix: prefix before properties name +*/ void XRefProperties::toSettings(QSettings &settings, const QString prefix) const { settings.setValue(prefix + "showpowerctc", m_show_power_ctc); QString display = m_display == Cross? "cross" : "contacts"; @@ -64,11 +64,11 @@ void XRefProperties::toSettings(QSettings &settings, const QString prefix) const } /** - * @brief XRefProperties::fromSettings - * load from settings - * @param settings: QSettings to use - * @param prefix: prefix before properties name - */ + @brief XRefProperties::fromSettings + load from settings + @param settings: QSettings to use + @param prefix: prefix before properties name +*/ void XRefProperties::fromSettings(const QSettings &settings, const QString prefix) { m_show_power_ctc = settings.value(prefix + "showpowerctc", true).toBool(); @@ -89,10 +89,10 @@ void XRefProperties::fromSettings(const QSettings &settings, const QString prefi } /** - * @brief XRefProperties::toXml - * Save to xml - * @param xml_element: QDomElement to use for saving - */ + @brief XRefProperties::toXml + Save to xml + @param xml_element: QDomElement to use for saving +*/ QDomElement XRefProperties::toXml(QDomDocument &xml_document) const { QDomElement xml_element = xml_document.createElement("xref"); @@ -123,10 +123,10 @@ QDomElement XRefProperties::toXml(QDomDocument &xml_document) const { } /** - * @brief XRefProperties::fromXml - * Load from xml - * @param xml_element: QDomElement to use for load - */ + @brief XRefProperties::fromXml + Load from xml + @param xml_element: QDomElement to use for load +*/ bool XRefProperties::fromXml(const QDomElement &xml_element) { m_show_power_ctc = xml_element.attribute("showpowerctc") == "true"; QString display = xml_element.attribute("displayhas", "cross"); @@ -153,12 +153,12 @@ bool XRefProperties::fromXml(const QDomElement &xml_element) { } /** - * @brief XRefProperties::defaultProperties - * @return the default properties stored in the setting file - * For the xref, there is 2 propreties. - * For coil, stored with the string "coil" in the returned QHash. - * For protection, stored with the string "protection" in the returned QHash. - */ + @brief XRefProperties::defaultProperties + @return the default properties stored in the setting file + For the xref, there is 2 propreties. + For coil, stored with the string "coil" in the returned QHash. + For protection, stored with the string "protection" in the returned QHash. +*/ QHash XRefProperties::defaultProperties() { QHash hash; diff --git a/sources/properties/xrefproperties.h b/sources/properties/xrefproperties.h index dc03196cf..9a292c3ec 100644 --- a/sources/properties/xrefproperties.h +++ b/sources/properties/xrefproperties.h @@ -22,9 +22,9 @@ #include /** - * @brief The XRefProperties class - * this class store properties used by XrefItem - */ + @brief The XRefProperties class + this class store properties used by XrefItem +*/ class XRefProperties : public PropertiesInterface { public: diff --git a/sources/qet.cpp b/sources/qet.cpp index 9a83f9e98..725db3424 100644 --- a/sources/qet.cpp +++ b/sources/qet.cpp @@ -69,11 +69,11 @@ bool Qet::surLeMemeAxe(Qet::Orientation a, Qet::Orientation b) { } /** - * @brief Qet::isOpposed - * @param a - * @param b - * @return true if a and b is opposed, else false; - */ + @brief Qet::isOpposed + @param a + @param b + @return true if a and b is opposed, else false; +*/ bool Qet::isOpposed(Qet::Orientation a, Qet::Orientation b) { bool result = false; @@ -100,19 +100,19 @@ bool Qet::isOpposed(Qet::Orientation a, Qet::Orientation b) } /** - * @brief Qet::isHorizontal - * @param a - * @return true if @a is horizontal, else false. - */ + @brief Qet::isHorizontal + @param a + @return true if @a is horizontal, else false. +*/ bool Qet::isHorizontal(Qet::Orientation a) { return(a == Qet::East || a == Qet::West); } /** - * @brief Qet::isVertical - * @param a - * @return true if @a is vertical, else false. - */ + @brief Qet::isVertical + @param a + @return true if @a is vertical, else false. +*/ bool Qet::isVertical(Qet::Orientation a) { return(a == Qet::North || a == Qet::South); } @@ -595,12 +595,12 @@ bool QET::writeXmlFile(QDomDocument &xml_doc, const QString &filepath, QString * } /** - * @brief QET::eachStrIsEqual - * @param qsl list of string to compare - * @return true if every string is identical, else false; - * The list must not be empty - * If the list can be empty, call isEmpty() before calling this function - */ + @brief QET::eachStrIsEqual + @param qsl list of string to compare + @return true if every string is identical, else false; + The list must not be empty + If the list can be empty, call isEmpty() before calling this function +*/ bool QET::eachStrIsEqual(const QStringList &qsl) { if (qsl.size() == 1) return true; foreach (const QString t, qsl) { @@ -610,10 +610,10 @@ bool QET::eachStrIsEqual(const QStringList &qsl) { } /** - * @brief QET::qetCollectionToString - * @param c QetCollection value to convert - * @return The QetCollection enum value converted to a QString - */ + @brief QET::qetCollectionToString + @param c QetCollection value to convert + @return The QetCollection enum value converted to a QString +*/ QString QET::qetCollectionToString(const QET::QetCollection &c) { switch (c) @@ -630,11 +630,11 @@ QString QET::qetCollectionToString(const QET::QetCollection &c) } /** - * @brief QET::qetCollectionFromString - * @param str string to convert - * @return The corresponding QetCollection value from a string. - * If the string don't match anything, we return the failsafe value QetCollection::Common - */ + @brief QET::qetCollectionFromString + @param str string to convert + @return The corresponding QetCollection value from a string. + If the string don't match anything, we return the failsafe value QetCollection::Common +*/ QET::QetCollection QET::qetCollectionFromString(const QString &str) { if (str == "common") @@ -648,11 +648,11 @@ QET::QetCollection QET::qetCollectionFromString(const QString &str) } /** - * @brief QET::depthActionGroup - * @param parent - * @return an action group which contain 4 actions (forward, raise, lower, backward) - * already made with icon, shortcut and data (see QET::DepthOption) - */ + @brief QET::depthActionGroup + @param parent + @return an action group which contain 4 actions (forward, raise, lower, backward) + already made with icon, shortcut and data (see QET::DepthOption) +*/ QActionGroup *QET::depthActionGroup(QObject *parent) { QActionGroup *action_group = new QActionGroup(parent); diff --git a/sources/qetapp.cpp b/sources/qetapp.cpp index 5f68287cf..495fba82e 100644 --- a/sources/qetapp.cpp +++ b/sources/qetapp.cpp @@ -284,7 +284,7 @@ void QETApp::restoreEveryEditor() { @brief QETApp::reduceDiagramEditors Minimize all schema editors in the systray \~French Reduit tous les editeurs de schemas dans le systray - */ +*/ void QETApp::reduceDiagramEditors() { setMainWindowsVisible(false); } @@ -312,7 +312,7 @@ void QETApp::reduceElementEditors() { @brief QETApp::restoreElementEditors Restore all element editors in the systray \~French Restaure tous les editeurs d'element dans le systray - */ +*/ void QETApp::restoreElementEditors() { setMainWindowsVisible(true); } @@ -870,7 +870,7 @@ QString QETApp::realPath(const QString &sym_path) { or the path symbolic designating the element. \~French Une chaine de caracteres vide en cas d'erreur ou le chemin symbolique designant l'element. - */ +*/ QString QETApp::symbolicPath(const QString &real_path) { // get the common and custom folders // recupere les dossier common et custom @@ -895,7 +895,7 @@ QString QETApp::symbolicPath(const QString &real_path) { @brief QETApp::handledFileExtensions @return the list of file extensions QElectroTech is able to open and supposed to handle. Note they are provided with no leading point. - */ +*/ QStringList QETApp::handledFileExtensions() { static QStringList ext; if (!ext.count()) { @@ -936,7 +936,7 @@ QStringList QETApp::handledFiles(const QList &urls) { or 0 if this file is not edited by the application. \~French le QETDiagramEditor editant le fichier filepath, ou 0 si ce fichier n'est pas edite par l'application. - */ +*/ QETDiagramEditor *QETApp::diagramEditorForFile(const QString &filepath) { if (filepath.isEmpty()) return(nullptr); @@ -1043,7 +1043,7 @@ void QETApp::overrideLangDir(const QString &new_ld) { @brief QETApp::languagesPath @return The path of the folder containing the language files \~French Le chemin du dossier contenant les fichiers de langue - */ +*/ QString QETApp::languagesPath() { if (!lang_dir.isEmpty()) { return(lang_dir); @@ -2259,7 +2259,7 @@ void QETApp::checkBackupFiles() \~ @param diagrams : QList \~ @param elements : QList \~ @param tbtemplates : QList - */ +*/ void QETApp::fetchWindowStats( const QList &diagrams, const QList &elements, diff --git a/sources/qetdiagrameditor.cpp b/sources/qetdiagrameditor.cpp index 93ce710da..4cc1ab2d9 100644 --- a/sources/qetdiagrameditor.cpp +++ b/sources/qetdiagrameditor.cpp @@ -44,11 +44,11 @@ /** - * @brief QETDiagramEditor::QETDiagramEditor - * Constructor - * @param files, list of files to open - * @param parent, parent widget - */ + @brief QETDiagramEditor::QETDiagramEditor + Constructor + @param files, list of files to open + @param parent, parent widget +*/ QETDiagramEditor::QETDiagramEditor(const QStringList &files, QWidget *parent) : QETMainWindow(parent), m_row_column_actions_group (this), @@ -132,9 +132,9 @@ QETDiagramEditor::~QETDiagramEditor() { } /** - * @brief QETDiagramEditor::setUpElementsPanel - * Setup the element panel and element panel widget - */ + @brief QETDiagramEditor::setUpElementsPanel + Setup the element panel and element panel widget +*/ void QETDiagramEditor::setUpElementsPanel() { //Add the element panel as a QDockWidget qdw_pa = new QDockWidget(tr("Projets", "dock title"), this); @@ -163,9 +163,9 @@ void QETDiagramEditor::setUpElementsPanel() { } /** - * @brief QETDiagramEditor::setUpElementsCollectionWidget - * Set up the dock widget of element collection - */ + @brief QETDiagramEditor::setUpElementsCollectionWidget + Set up the dock widget of element collection +*/ void QETDiagramEditor::setUpElementsCollectionWidget() { m_qdw_elmt_collection = new QDockWidget(tr("Collections"), this); @@ -181,9 +181,9 @@ void QETDiagramEditor::setUpElementsCollectionWidget() } /** - * @brief QETDiagramEditor::setUpUndoStack - * Setup the undostack and undo stack widget - */ + @brief QETDiagramEditor::setUpUndoStack + Setup the undostack and undo stack widget +*/ void QETDiagramEditor::setUpUndoStack() { QUndoView *undo_view = new QUndoView(&undo_group, this); @@ -204,9 +204,9 @@ void QETDiagramEditor::setUpUndoStack() { } /** - * @brief QETDiagramEditor::setUpSelectionPropertiesEditor - * Setup the dock for edit the current selection - */ + @brief QETDiagramEditor::setUpSelectionPropertiesEditor + Setup the dock for edit the current selection +*/ void QETDiagramEditor::setUpSelectionPropertiesEditor() { m_selection_properties_editor = new DiagramPropertiesEditorDockWidget(this); @@ -215,9 +215,9 @@ void QETDiagramEditor::setUpSelectionPropertiesEditor() } /** - * @brief QETDiagramEditor::setUpAutonumberingWidget - * Setup the dock for AutoNumbering Selection - */ + @brief QETDiagramEditor::setUpAutonumberingWidget + Setup the dock for AutoNumbering Selection +*/ void QETDiagramEditor::setUpAutonumberingWidget() { m_autonumbering_dock = new AutoNumberingDockWidget(this); @@ -227,9 +227,9 @@ void QETDiagramEditor::setUpAutonumberingWidget() } /** - * @brief QETDiagramEditor::setUpActions - * Set up all Qaction - */ + @brief QETDiagramEditor::setUpActions + Set up all Qaction +*/ void QETDiagramEditor::setUpActions() { //Export to another file type (jpeg, dxf etc...) @@ -654,8 +654,8 @@ void QETDiagramEditor::setUpActions() } /** - * @brief QETDiagramEditor::setUpToolBar - */ + @brief QETDiagramEditor::setUpToolBar +*/ void QETDiagramEditor::setUpToolBar() { main_tool_bar = new QToolBar(tr("Outils"), this); @@ -709,8 +709,8 @@ void QETDiagramEditor::setUpToolBar() } /** - * @brief QETDiagramEditor::setUpMenu - */ + @brief QETDiagramEditor::setUpMenu +*/ void QETDiagramEditor::setUpMenu() { QMenu *menu_fichier = new QMenu(tr("&Fichier")); @@ -830,12 +830,12 @@ void QETDiagramEditor::closeEvent(QCloseEvent *qce) { } /** - * @brief QETDiagramEditor::event - * Reimplemented to : - * -Load elements collection when WindowActivate. - * @param e - * @return - */ + @brief QETDiagramEditor::event + Reimplemented to : + -Load elements collection when WindowActivate. + @param e + @return +*/ bool QETDiagramEditor::event(QEvent *e) { if (m_first_show && e->type() == QEvent::WindowActivate) @@ -847,9 +847,9 @@ bool QETDiagramEditor::event(QEvent *e) } /** - * @brief QETDiagramEditor::save - * Ask the current active project to save - */ + @brief QETDiagramEditor::save + Ask the current active project to save +*/ void QETDiagramEditor::save() { if (ProjectView *project_view = currentProjectView()) { QETResult saved = project_view -> save(); @@ -871,9 +871,9 @@ void QETDiagramEditor::save() { } /** - * @brief QETDiagramEditor::saveAs - * Ask the current active project to save as - */ + @brief QETDiagramEditor::saveAs + Ask the current active project to save as +*/ void QETDiagramEditor::saveAs() { if (ProjectView *project_view = currentProjectView()) { QETResult save_file = project_view -> saveAs(); @@ -893,10 +893,10 @@ void QETDiagramEditor::saveAs() { } /** - * @brief QETDiagramEditor::newProject - * Create a new project with an empty diagram - * @return - */ + @brief QETDiagramEditor::newProject + Create a new project with an empty diagram + @return +*/ bool QETDiagramEditor::newProject() { auto new_project = new QETProject(this); @@ -1140,10 +1140,10 @@ ProjectView *QETDiagramEditor::currentProjectView() const { } /** - * @brief QETDiagramEditor::currentProject - * @return the current edited project. - * This function can return nullptr. - */ + @brief QETDiagramEditor::currentProject + @return the current edited project. + This function can return nullptr. +*/ QETProject *QETDiagramEditor::currentProject() const { ProjectView *view = currentProjectView(); @@ -1288,10 +1288,10 @@ void QETDiagramEditor::zoomGroupTriggered(QAction *action) } /** - * @brief QETDiagramEditor::selectGroupTriggered - * This slot is called when selection need to change. - * @param action : Action that describes what to do. - */ + @brief QETDiagramEditor::selectGroupTriggered + This slot is called when selection need to change. + @param action : Action that describes what to do. +*/ void QETDiagramEditor::selectGroupTriggered(QAction *action) { QString value = action->data().toString(); @@ -1308,11 +1308,11 @@ void QETDiagramEditor::selectGroupTriggered(QAction *action) } /** - * @brief QETDiagramEditor::addItemGroupTriggered - * This slot is called when an item must be added to the curent diagram, - * this slot use the DVEventInterface to add item - * @param action : Action that describe the item to add. - */ + @brief QETDiagramEditor::addItemGroupTriggered + This slot is called when an item must be added to the curent diagram, + this slot use the DVEventInterface to add item + @param action : Action that describe the item to add. +*/ void QETDiagramEditor::addItemGroupTriggered(QAction *action) { QString value = action->data().toString(); @@ -1359,10 +1359,10 @@ void QETDiagramEditor::addItemGroupTriggered(QAction *action) } /** - * @brief QETDiagramEditor::selectionGroupTriggered - * This slot is called when an action should be made on the current selection - * @param action : Action that describe the action to do. - */ + @brief QETDiagramEditor::selectionGroupTriggered + This slot is called when an action should be made on the current selection + @param action : Action that describe the action to do. +*/ void QETDiagramEditor::selectionGroupTriggered(QAction *action) { QString value = action->data().toString(); @@ -1424,9 +1424,9 @@ void QETDiagramEditor::rowColumnGroupTriggered(QAction *action) } /** - * @brief QETDiagramEditor::slot_updateActions - * Manage actions - */ + @brief QETDiagramEditor::slot_updateActions + Manage actions +*/ void QETDiagramEditor::slot_updateActions() { DiagramView *dv = currentDiagramView(); @@ -1467,9 +1467,9 @@ void QETDiagramEditor::slot_updateActions() } /** - * @brief QETDiagramEditor::slot_updateAutoNumDock - * Update Auto Num Dock Widget when changing Project - */ + @brief QETDiagramEditor::slot_updateAutoNumDock + Update Auto Num Dock Widget when changing Project +*/ void QETDiagramEditor::slot_updateAutoNumDock() { if ( m_workspace.subWindowList().indexOf(m_workspace.activeSubWindow()) != activeSubWindowIndex) { activeSubWindowIndex = m_workspace.subWindowList().indexOf(m_workspace.activeSubWindow()); @@ -1480,9 +1480,9 @@ void QETDiagramEditor::slot_updateAutoNumDock() { } /** - * @brief QETDiagramEditor::slot_updateUndoStack - * Update the undo stack view - */ + @brief QETDiagramEditor::slot_updateUndoStack + Update the undo stack view +*/ void QETDiagramEditor::slot_updateUndoStack() { if(currentProjectView()) @@ -1490,10 +1490,10 @@ void QETDiagramEditor::slot_updateUndoStack() } /** - * @brief QETDiagramEditor::slot_updateComplexActions - * Manage the actions who need some conditions to be enable or not. - * This method does nothing if there is no project opened - */ + @brief QETDiagramEditor::slot_updateComplexActions + Manage the actions who need some conditions to be enable or not. + This method does nothing if there is no project opened +*/ void QETDiagramEditor::slot_updateComplexActions() { DiagramView *dv = currentDiagramView(); @@ -1607,9 +1607,9 @@ void QETDiagramEditor::slot_updateComplexActions() } /** - * @brief QETDiagramEditor::slot_updateModeActions - * Manage action who need an opened diagram or project to be updated - */ + @brief QETDiagramEditor::slot_updateModeActions + Manage action who need an opened diagram or project to be updated +*/ void QETDiagramEditor::slot_updateModeActions() { DiagramView *dv = currentDiagramView(); @@ -1655,11 +1655,11 @@ void QETDiagramEditor::slot_updatePasteAction() { } /** - * @brief QETDiagramEditor::addProjectView - * Add a new project view to workspace and - * build the connection between the projectview / project and this QETDiagramEditor. - * @param project_view, project view to add - */ + @brief QETDiagramEditor::addProjectView + Add a new project view to workspace and + build the connection between the projectview / project and this QETDiagramEditor. + @param project_view, project view to add +*/ void QETDiagramEditor::addProjectView(ProjectView *project_view) { if (!project_view) return; @@ -1743,17 +1743,17 @@ ProjectView *QETDiagramEditor::viewForFile(const QString &filepath) const { } /** - * @brief QETDiagramEditor::drawGrid - * @return true if the grid of folio must be displayed - */ + @brief QETDiagramEditor::drawGrid + @return true if the grid of folio must be displayed +*/ bool QETDiagramEditor::drawGrid() const { return m_draw_grid->isChecked(); } /** - * @brief QETDiagramEditor::openBackupFiles - * @param backup_files - */ + @brief QETDiagramEditor::openBackupFiles + @param backup_files +*/ void QETDiagramEditor::openBackupFiles(QList backup_files) { for (KAutoSaveFile *file : backup_files) @@ -1862,9 +1862,9 @@ void QETDiagramEditor::setTabbedMode() { } /** - * @brief QETDiagramEditor::readSettings - * Read the settings - */ + @brief QETDiagramEditor::readSettings + Read the settings +*/ void QETDiagramEditor::readSettings() { QSettings settings; @@ -1887,9 +1887,9 @@ void QETDiagramEditor::readSettings() } /** - * @brief QETDiagramEditor::writeSettings - * Write the settings - */ + @brief QETDiagramEditor::writeSettings + Write the settings +*/ void QETDiagramEditor::writeSettings() { QSettings settings; @@ -1930,9 +1930,9 @@ void QETDiagramEditor::activateProject(ProjectView *project_view) { } /*** @brief QETDiagramEditor::projectWasClosed - * Manage the close of a project. - * @param project_view - */ + Manage the close of a project. + @param project_view +*/ void QETDiagramEditor::projectWasClosed(ProjectView *project_view) { QETProject *project = project_view -> project(); @@ -1971,10 +1971,10 @@ void QETDiagramEditor::editProjectProperties(QETProject *project) { } /** - * @brief QETDiagramEditor::addDiagramToProject - * Add a diagram to project - * @param project - */ + @brief QETDiagramEditor::addDiagramToProject + Add a diagram to project + @param project +*/ void QETDiagramEditor::addDiagramToProject(QETProject *project) { if (!project) { @@ -2051,7 +2051,7 @@ void QETDiagramEditor::moveDiagramDown(Diagram *diagram) { Change l'ordre des schemas d'un projet, en decalant le schema vers le haut / la gauche en position 0 @param diagram Schema a decaler vers le haut / la gauche en position 0 - */ +*/ void QETDiagramEditor::moveDiagramUpTop(Diagram *diagram) { if (!diagram) return; @@ -2122,10 +2122,10 @@ void QETDiagramEditor::removeDiagramFromProject() } /** - * @brief QETDiagramEditor::diagramWasAdded - * Manage the adding of diagram view in a project - * @param dv, added diagram view - */ + @brief QETDiagramEditor::diagramWasAdded + Manage the adding of diagram view in a project + @param dv, added diagram view +*/ void QETDiagramEditor::diagramWasAdded(DiagramView *dv) { connect(dv->diagram(), &QGraphicsScene::selectionChanged, this, &QETDiagramEditor::selectionChanged, Qt::DirectConnection); @@ -2133,10 +2133,10 @@ void QETDiagramEditor::diagramWasAdded(DiagramView *dv) } /** - * @brief QETDiagramEditor::findElementInPanel - * Find the item for @location in the element panel - * @param location - */ + @brief QETDiagramEditor::findElementInPanel + Find the item for @location in the element panel + @param location +*/ void QETDiagramEditor::findElementInPanel(const ElementsLocation &location) { m_element_collection_widget->setCurrentLocation(location); @@ -2177,10 +2177,10 @@ void QETDiagramEditor::showError(const QString &error) { } /** - * @brief QETDiagramEditor::subWindowActivated - * Slot used to update menu and undo stack when subwindows of MDIarea was activated - * @param subWindows - */ + @brief QETDiagramEditor::subWindowActivated + Slot used to update menu and undo stack when subwindows of MDIarea was activated + @param subWindows +*/ void QETDiagramEditor::subWindowActivated(QMdiSubWindow *subWindows) { Q_UNUSED(subWindows); @@ -2190,9 +2190,9 @@ void QETDiagramEditor::subWindowActivated(QMdiSubWindow *subWindows) } /** - * @brief QETDiagramEditor::selectionChanged - * This slot is called when a diagram selection was changed. - */ + @brief QETDiagramEditor::selectionChanged + This slot is called when a diagram selection was changed. +*/ void QETDiagramEditor::selectionChanged() { slot_updateComplexActions(); @@ -2204,8 +2204,8 @@ void QETDiagramEditor::selectionChanged() /** - * @brief QETDiagramEditor::generateTerminalBlock - */ + @brief QETDiagramEditor::generateTerminalBlock +*/ void QETDiagramEditor::generateTerminalBlock() { bool success; diff --git a/sources/qetgraphicsitem/ViewItem/projectdbmodel.cpp b/sources/qetgraphicsitem/ViewItem/projectdbmodel.cpp index 7e4897f1d..29a72cb27 100644 --- a/sources/qetgraphicsitem/ViewItem/projectdbmodel.cpp +++ b/sources/qetgraphicsitem/ViewItem/projectdbmodel.cpp @@ -25,10 +25,10 @@ #include /** - * @brief ProjectDBModel::ProjectDBModel - * @param project :project of this nomenclature - * @param parent : parent QObject - */ + @brief ProjectDBModel::ProjectDBModel + @param project :project of this nomenclature + @param parent : parent QObject +*/ ProjectDBModel::ProjectDBModel(QETProject *project, QObject *parent) : QAbstractTableModel(parent), m_project(project) @@ -37,9 +37,9 @@ ProjectDBModel::ProjectDBModel(QETProject *project, QObject *parent) : } /** - * @brief ProjectDBModel::ProjectDBModel - * @param other_model - */ + @brief ProjectDBModel::ProjectDBModel + @param other_model +*/ ProjectDBModel::ProjectDBModel(const ProjectDBModel &other_model) : QAbstractTableModel(other_model.parent()) { @@ -51,11 +51,11 @@ ProjectDBModel::ProjectDBModel(const ProjectDBModel &other_model) : } /** - * @brief ProjectDBModel::rowCount - * Reimplemented for QAbstractTableModel - * @param parent - * @return - */ + @brief ProjectDBModel::rowCount + Reimplemented for QAbstractTableModel + @param parent + @return +*/ int ProjectDBModel::rowCount(const QModelIndex &parent) const { if (parent.isValid()) @@ -65,11 +65,11 @@ int ProjectDBModel::rowCount(const QModelIndex &parent) const } /** - * @brief ProjectDBModel::columnCount - * Reimplemented for QAbstractTableModel - * @param parent - * @return - */ + @brief ProjectDBModel::columnCount + Reimplemented for QAbstractTableModel + @param parent + @return +*/ int ProjectDBModel::columnCount(const QModelIndex &parent) const { if (parent.isValid()) @@ -83,15 +83,15 @@ int ProjectDBModel::columnCount(const QModelIndex &parent) const } /** - * @brief ProjectDBModel::setHeaderData - * Reimplemented from QAbstractTableModel. - * Only horizontal orientation is accepted. - * @param section - * @param orientation - * @param value - * @param role - * @return - */ + @brief ProjectDBModel::setHeaderData + Reimplemented from QAbstractTableModel. + Only horizontal orientation is accepted. + @param section + @param orientation + @param value + @param role + @return +*/ bool ProjectDBModel::setHeaderData(int section, Qt::Orientation orientation, const QVariant &value, int role) { if (orientation == Qt::Vertical) { @@ -105,13 +105,13 @@ bool ProjectDBModel::setHeaderData(int section, Qt::Orientation orientation, con } /** - * @brief ProjectDBModel::headerData - * Reimplemented from QAbstractTableModel. - * @param section - * @param orientation - * @param role - * @return - */ + @brief ProjectDBModel::headerData + Reimplemented from QAbstractTableModel. + @param section + @param orientation + @param role + @return +*/ QVariant ProjectDBModel::headerData(int section, Qt::Orientation orientation, int role) const { if (orientation == Qt::Vertical) { @@ -130,13 +130,13 @@ QVariant ProjectDBModel::headerData(int section, Qt::Orientation orientation, in } /** - * @brief ProjectDBModel::setData - * Only store the data for the index 0.0 - * @param index - * @param value - * @param role - * @return - */ + @brief ProjectDBModel::setData + Only store the data for the index 0.0 + @param index + @param value + @param role + @return +*/ bool ProjectDBModel::setData(const QModelIndex &index, const QVariant &value, int role) { if (!index.isValid() || index.row() != 0 || index.column() != 0) { @@ -148,12 +148,12 @@ bool ProjectDBModel::setData(const QModelIndex &index, const QVariant &value, in } /** - * @brief ProjectDBModel::data - * Reimplemented for QAbstractTableModel - * @param index - * @param role - * @return - */ + @brief ProjectDBModel::data + Reimplemented for QAbstractTableModel + @param index + @param role + @return +*/ QVariant ProjectDBModel::data(const QModelIndex &index, int role) const { if (!index.isValid()) @@ -174,10 +174,10 @@ QVariant ProjectDBModel::data(const QModelIndex &index, int role) const } /** - * @brief ProjectDBModel::setQuery - * Query the internall bd with @query. - * @param query - */ + @brief ProjectDBModel::setQuery + Query the internall bd with @query. + @param query +*/ void ProjectDBModel::setQuery(const QString &query) { auto rm_ = m_query != query; @@ -206,9 +206,9 @@ void ProjectDBModel::setQuery(const QString &query) } /** - * @brief ProjectDBModel::queryString - * @return the current query used by this model - */ + @brief ProjectDBModel::queryString + @return the current query used by this model +*/ QString ProjectDBModel::queryString() const { return m_query; } @@ -218,12 +218,12 @@ QETProject *ProjectDBModel::project() const { } /** - * @brief ProjectDBModel::toXml - * Save the model to xml,since model can have unlimited data we only save few data (only these used by qelectrotech). - * The query, all header data. and some data of index::(0,0). All other data are not saved. - * @param document - * @return - */ + @brief ProjectDBModel::toXml + Save the model to xml,since model can have unlimited data we only save few data (only these used by qelectrotech). + The query, all header data. and some data of index::(0,0). All other data are not saved. + @param document + @return +*/ QDomElement ProjectDBModel::toXml(QDomDocument &document) const { auto dom_element = document.createElement(xmlTagName()); @@ -265,10 +265,10 @@ QDomElement ProjectDBModel::toXml(QDomDocument &document) const } /** - * @brief ProjectDBModel::fromXml - * Restore the model from xml - * @param element - */ + @brief ProjectDBModel::fromXml + Restore the model from xml + @param element +*/ void ProjectDBModel::fromXml(const QDomElement &element) { if (element.tagName() != xmlTagName()) @@ -290,18 +290,18 @@ void ProjectDBModel::fromXml(const QDomElement &element) } /** - * @brief ProjectDBModel::setIdentifier - * Set the identifier of this model to @identifier - * @param identifier - */ + @brief ProjectDBModel::setIdentifier + Set the identifier of this model to @identifier + @param identifier +*/ void ProjectDBModel::setIdentifier(const QString &identifier) { m_identifier = identifier; } /** - * @brief ProjectDBModel::dataBaseUpdated - * slot called when the project database is updated - */ + @brief ProjectDBModel::dataBaseUpdated + slot called when the project database is updated +*/ void ProjectDBModel::dataBaseUpdated() { auto original_record = m_record; diff --git a/sources/qetgraphicsitem/ViewItem/projectdbmodel.h b/sources/qetgraphicsitem/ViewItem/projectdbmodel.h index f04271e38..7d351f89b 100644 --- a/sources/qetgraphicsitem/ViewItem/projectdbmodel.h +++ b/sources/qetgraphicsitem/ViewItem/projectdbmodel.h @@ -25,16 +25,16 @@ class QETProject; /** - * @brief The ProjectDBModel class - * This model is intended to be use with the @class projectDataBase - * and is designed to be displayed by the @class QetGraphicsTableItem (but can be use by other view class since it inherit from QAbstractTableModel). - * This class should be sufficient to display the content of the project data base from a query set by the method void ProjectDBModel::setQuery(const QString &query). - * The indentifier method is used by widget editor to retrieve the good widget for edit the query. By defaut identifer return the string 'unknow'. - * You should use setIdentfier method to set your custom identifier. - * At the time this sentence is written, there is two identifier : - * nomenclature - * summary - */ + @brief The ProjectDBModel class + This model is intended to be use with the @class projectDataBase + and is designed to be displayed by the @class QetGraphicsTableItem (but can be use by other view class since it inherit from QAbstractTableModel). + This class should be sufficient to display the content of the project data base from a query set by the method void ProjectDBModel::setQuery(const QString &query). + The indentifier method is used by widget editor to retrieve the good widget for edit the query. By defaut identifer return the string 'unknow'. + You should use setIdentfier method to set your custom identifier. + At the time this sentence is written, there is two identifier : + nomenclature + summary +*/ class ProjectDBModel : public QAbstractTableModel { Q_OBJECT diff --git a/sources/qetgraphicsitem/ViewItem/qetgraphicsheaderitem.cpp b/sources/qetgraphicsitem/ViewItem/qetgraphicsheaderitem.cpp index a6e85c78d..2f598c073 100644 --- a/sources/qetgraphicsitem/ViewItem/qetgraphicsheaderitem.cpp +++ b/sources/qetgraphicsitem/ViewItem/qetgraphicsheaderitem.cpp @@ -26,20 +26,20 @@ static int no_model_height = 20; static int no_model_width = 40; /** - * @brief QetGraphicsHeaderItem::QetGraphicsHeaderItem - * @param parent - */ + @brief QetGraphicsHeaderItem::QetGraphicsHeaderItem + @param parent +*/ QetGraphicsHeaderItem::QetGraphicsHeaderItem(QGraphicsItem *parent) : QGraphicsObject(parent) {} /** - * @brief QetGraphicsHeaderItem::setModel - * Set the model presented by this item - * Since QetGraphicsHeaderItem don't take ownership of model, - * if item already have a model, it's your responsability to delete it. - * @param model - */ + @brief QetGraphicsHeaderItem::setModel + Set the model presented by this item + Since QetGraphicsHeaderItem don't take ownership of model, + if item already have a model, it's your responsability to delete it. + @param model +*/ void QetGraphicsHeaderItem::setModel(QAbstractItemModel *model) { if (m_model) { @@ -65,29 +65,29 @@ void QetGraphicsHeaderItem::setModel(QAbstractItemModel *model) } /** - * @brief QetGraphicsHeaderItem::model - * @return the model that this item is presenting - */ + @brief QetGraphicsHeaderItem::model + @return the model that this item is presenting +*/ QAbstractItemModel *QetGraphicsHeaderItem::model() const { return m_model; } /** - * @brief QetGraphicsHeaderItem::boundingRect - * Reimplemented from QGraphicsObject::boundingRect() const; - * @return - */ + @brief QetGraphicsHeaderItem::boundingRect + Reimplemented from QGraphicsObject::boundingRect() const; + @return +*/ QRectF QetGraphicsHeaderItem::boundingRect() const { return m_bounding_rect; } /** - * @brief QetGraphicsHeaderItem::paint - * Reimplemented from QGraphicsObject::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) const; - * @param painter - * @param option - * @param widget - */ + @brief QetGraphicsHeaderItem::paint + Reimplemented from QGraphicsObject::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) const; + @param painter + @param option + @param widget +*/ void QetGraphicsHeaderItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { Q_UNUSED(option) @@ -141,18 +141,18 @@ void QetGraphicsHeaderItem::paint(QPainter *painter, const QStyleOptionGraphicsI } /** - * @brief QetGraphicsHeaderItem::rect - * @return the current rect of the item aka the size of rectangle painted. - */ + @brief QetGraphicsHeaderItem::rect + @return the current rect of the item aka the size of rectangle painted. +*/ QRect QetGraphicsHeaderItem::rect() const { return m_current_rect; } /** - * @brief QetGraphicsHeaderItem::resizeSection - * @param logicalIndex - * @param size - */ + @brief QetGraphicsHeaderItem::resizeSection + @param logicalIndex + @param size +*/ void QetGraphicsHeaderItem::resizeSection(int logicalIndex, int size) { if (!m_model) @@ -187,10 +187,10 @@ void QetGraphicsHeaderItem::resizeSection(int logicalIndex, int size) } /** - * @brief QetGraphicsHeaderItem::sectionSize - * @param logical_index - * @return the width (or height for vertical headers) of the given logicalIndex. - */ + @brief QetGraphicsHeaderItem::sectionSize + @param logical_index + @return the width (or height for vertical headers) of the given logicalIndex. +*/ int QetGraphicsHeaderItem::sectionSize(int logical_index) const { if (logical_index>=0 && logical_indexdiagram()) { @@ -62,11 +62,11 @@ void QetGraphicsTableItem::adjustTableToFolio(QetGraphicsTableItem *table, QMarg } /** - * @brief QetGraphicsTableItem::checkInsufficientRowsCount - * Check if the number of rows of @table + linked table is enough to display all - * content of the model, if not open a dialog to advise user what to do. - * @param table - */ + @brief QetGraphicsTableItem::checkInsufficientRowsCount + Check if the number of rows of @table + linked table is enough to display all + content of the model, if not open a dialog to advise user what to do. + @param table +*/ void QetGraphicsTableItem::checkInsufficientRowsCount(QetGraphicsTableItem *table) { if (!table->diagram() || !table->model()) { @@ -114,10 +114,10 @@ void QetGraphicsTableItem::checkInsufficientRowsCount(QetGraphicsTableItem *tabl } /** - * @brief QetGraphicsTableItem::QetGraphicsTableItem - * Default constructor - * @param parent - */ + @brief QetGraphicsTableItem::QetGraphicsTableItem + Default constructor + @param parent +*/ QetGraphicsTableItem::QetGraphicsTableItem(QGraphicsItem *parent) : QetGraphicsItem(parent) { @@ -146,12 +146,12 @@ QetGraphicsTableItem::~QetGraphicsTableItem() {} /** - * @brief QetGraphicsTableItem::setModel - * Set the model presented by this item. - * Since QetGraphicsTableItem don't take ownership of model, - * if item already have a model, it's your responsibility to delete it. - * @param model - */ + @brief QetGraphicsTableItem::setModel + Set the model presented by this item. + Since QetGraphicsTableItem don't take ownership of model, + if item already have a model, it's your responsibility to delete it. + @param model +*/ void QetGraphicsTableItem::setModel(QAbstractItemModel *model) { if (m_model) @@ -178,29 +178,29 @@ void QetGraphicsTableItem::setModel(QAbstractItemModel *model) } /** - * @brief QetGraphicsTableItem::model - * @return The model that this item is presenting - */ + @brief QetGraphicsTableItem::model + @return The model that this item is presenting +*/ QAbstractItemModel *QetGraphicsTableItem::model() const { return m_model; } /** - * @brief QetGraphicsTableItem::boundingRect - * Reimplemented from QGraphicsObject - * @return - */ + @brief QetGraphicsTableItem::boundingRect + Reimplemented from QGraphicsObject + @return +*/ QRectF QetGraphicsTableItem::boundingRect() const { return m_bounding_rect; } /** - * @brief QetGraphicsTableItem::paint - * Draw the table - * @param painter - * @param option - * @param widget - */ + @brief QetGraphicsTableItem::paint + Draw the table + @param painter + @param option + @param widget +*/ void QetGraphicsTableItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { Q_UNUSED(option) @@ -285,10 +285,10 @@ void QetGraphicsTableItem::paint(QPainter *painter, const QStyleOptionGraphicsIt } /** - * @brief QetGraphicsTableItem::setSize - * Set the current size of the table to @size - * @param size - */ + @brief QetGraphicsTableItem::setSize + Set the current size of the table to @size + @param size +*/ void QetGraphicsTableItem::setSize(const QSize &size) { auto new_size = size; @@ -309,9 +309,9 @@ void QetGraphicsTableItem::setSize(const QSize &size) } /** - * @brief QetGraphicsTableItem::size - * @return The current size of the table - */ + @brief QetGraphicsTableItem::size + @return The current size of the table +*/ QSize QetGraphicsTableItem::size() const { QSize size_(m_header_item->rect().width(), m_current_size.height()); @@ -319,10 +319,10 @@ QSize QetGraphicsTableItem::size() const } /** - * @brief QetGraphicsTableItem::minimumSize - * @return the minimum size the table can be - * The returned size take care of the table's minimum width, but also the header item's minimum width - */ + @brief QetGraphicsTableItem::minimumSize + @return the minimum size the table can be + The returned size take care of the table's minimum width, but also the header item's minimum width +*/ QSize QetGraphicsTableItem::minimumSize() const { if (!m_model) { @@ -348,10 +348,10 @@ QSize QetGraphicsTableItem::minimumSize() const } /** - * @brief QetGraphicsTableItem::setDisplayNRow - * Limit the number of row to display - * @param number : set to 0 or less to disabled the limit of row to display - */ + @brief QetGraphicsTableItem::setDisplayNRow + Limit the number of row to display + @param number : set to 0 or less to disabled the limit of row to display +*/ void QetGraphicsTableItem::setDisplayNRow(const int &number) { m_number_of_displayed_row = number; setToMinimumHeight(); @@ -360,25 +360,25 @@ void QetGraphicsTableItem::setDisplayNRow(const int &number) { } /** - * @brief QetGraphicsTableItem::displayNRow - * @return the number of row displayed. - * A value of 0 or less mean there is no limit - */ + @brief QetGraphicsTableItem::displayNRow + @return the number of row displayed. + A value of 0 or less mean there is no limit +*/ int QetGraphicsTableItem::displayNRow() const { return m_number_of_displayed_row; } /** - * @brief QetGraphicsTableItem::setPreviousTable - * Set the previous table to @table. - * If this table already have a previous table, the previous table will be replaced. - * Set new table to nullptr to remove an existing previous table. - * The table uses the model of the new previous table. - * Since the table does not take ownership of the model, it is your responsibility to manage the old model. - * Linked tables (table with next and/or previous table) share the same model, a table always take the model of the previous table.. - * When remove a previous table (set to nullptr) from a table, the model is also removed, you need to set a new model - * @param table - */ + @brief QetGraphicsTableItem::setPreviousTable + Set the previous table to @table. + If this table already have a previous table, the previous table will be replaced. + Set new table to nullptr to remove an existing previous table. + The table uses the model of the new previous table. + Since the table does not take ownership of the model, it is your responsibility to manage the old model. + Linked tables (table with next and/or previous table) share the same model, a table always take the model of the previous table.. + When remove a previous table (set to nullptr) from a table, the model is also removed, you need to set a new model + @param table +*/ void QetGraphicsTableItem::setPreviousTable(QetGraphicsTableItem *table) { if (m_previous_table == table || @@ -405,11 +405,11 @@ void QetGraphicsTableItem::setPreviousTable(QetGraphicsTableItem *table) } /** - * @brief QetGraphicsTableItem::setNextTable - * Set the next table to @table - * nullptr will remove an existing next table. - * @param table - */ + @brief QetGraphicsTableItem::setNextTable + Set the next table to @table + nullptr will remove an existing next table. + @param table +*/ void QetGraphicsTableItem::setNextTable(QetGraphicsTableItem *table) { if (m_next_table == table || @@ -440,10 +440,10 @@ QString QetGraphicsTableItem::tableName() const { } /** - * @brief QetGraphicsTableItem::displayNRowOffset - * @return the offset (aka the last displayed row) of displayed row. - * If this item have a previous table, the previous offset is added. - */ + @brief QetGraphicsTableItem::displayNRowOffset + @return the offset (aka the last displayed row) of displayed row. + If this item have a previous table, the previous offset is added. +*/ int QetGraphicsTableItem::displayNRowOffset() const { auto offset_ = m_number_of_displayed_row; @@ -462,10 +462,10 @@ QetGraphicsTableItem *QetGraphicsTableItem::nextTable() const { } /** - * @brief QetGraphicsTableItem::setToMinimumHeight - * Set the height to the the minimum. - * The width stay unchanged. - */ + @brief QetGraphicsTableItem::setToMinimumHeight + Set the height to the the minimum. + The width stay unchanged. +*/ void QetGraphicsTableItem::setToMinimumHeight() { auto size_ = size(); @@ -487,19 +487,19 @@ void QetGraphicsTableItem::initLink() } /** - * @brief QetGraphicsTableItem::minimumRowHeigth - * @return the minimum height of a row - */ + @brief QetGraphicsTableItem::minimumRowHeigth + @return the minimum height of a row +*/ int QetGraphicsTableItem::minimumRowHeigth() const { return m_minimum_row_height; } /** - * @brief QetGraphicsTableItem::toXml - * Save the table to xml - * @param dom_document : parent document - * @return the dom_element that describe the table - */ + @brief QetGraphicsTableItem::toXml + Save the table to xml + @param dom_document : parent document + @return the dom_element that describe the table +*/ QDomElement QetGraphicsTableItem::toXml(QDomDocument &dom_document) const { auto dom_table = dom_document.createElement(xmlTagName()); @@ -535,11 +535,11 @@ QDomElement QetGraphicsTableItem::toXml(QDomDocument &dom_document) const } /** - * @brief QetGraphicsTableItem::fromXml - * Restore the table from xml. - * Make this item is already in a diagram to - * @param dom_element - */ + @brief QetGraphicsTableItem::fromXml + Restore the table from xml. + Make this item is already in a diagram to + @param dom_element +*/ void QetGraphicsTableItem::fromXml(const QDomElement &dom_element) { if (dom_element.tagName() != xmlTagName()) { @@ -573,10 +573,10 @@ void QetGraphicsTableItem::fromXml(const QDomElement &dom_element) } /** - * @brief QetGraphicsTableItem::hoverEnterEvent - * Reimplemented from QetGraphicsItem - * @param event - */ + @brief QetGraphicsTableItem::hoverEnterEvent + Reimplemented from QetGraphicsItem + @param event +*/ void QetGraphicsTableItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { if (m_model) @@ -589,10 +589,10 @@ void QetGraphicsTableItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) } /** - * @brief QetGraphicsTableItem::hoverLeaveEvent - * Reimplemented from QetGraphicsItem - * @param event - */ + @brief QetGraphicsTableItem::hoverLeaveEvent + Reimplemented from QetGraphicsItem + @param event +*/ void QetGraphicsTableItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { if (m_model) { @@ -602,12 +602,12 @@ void QetGraphicsTableItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) } /** - * @brief QetGraphicsTableItem::sceneEventFilter - * Reimplemented from QetGraphicsItem - * @param watched - * @param event - * @return - */ + @brief QetGraphicsTableItem::sceneEventFilter + Reimplemented from QetGraphicsItem + @param watched + @param event + @return +*/ bool QetGraphicsTableItem::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { if (watched == &m_handler_item) @@ -633,11 +633,11 @@ bool QetGraphicsTableItem::sceneEventFilter(QGraphicsItem *watched, QEvent *even } /** - * @brief QetGraphicsTableItem::itemChange - * @param change - * @param value - * @return - */ + @brief QetGraphicsTableItem::itemChange + @param change + @param value + @return +*/ QVariant QetGraphicsTableItem::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { //item was removed from scene, we remove the handler @@ -660,10 +660,10 @@ void QetGraphicsTableItem::modelReseted() { } /** - * @brief QetGraphicsTableItem::setUpColumnAndRowMinimumSize - * Calcule the minimum row height and the minimum column width for each columns - * this function doesn't change the geometry of the table. - */ + @brief QetGraphicsTableItem::setUpColumnAndRowMinimumSize + Calcule the minimum row height and the minimum column width for each columns + this function doesn't change the geometry of the table. +*/ void QetGraphicsTableItem::setUpColumnAndRowMinimumSize() { if (!m_model) @@ -693,8 +693,8 @@ void QetGraphicsTableItem::setUpColumnAndRowMinimumSize() } /** - * @brief QetGraphicsTableItem::setUpBoundingRect - */ + @brief QetGraphicsTableItem::setUpBoundingRect +*/ void QetGraphicsTableItem::setUpBoundingRect() { QSize header_size = m_header_item->rect().size(); @@ -703,16 +703,16 @@ void QetGraphicsTableItem::setUpBoundingRect() } /** - * @brief QetGraphicsTableItem::adjustHandlerPos - * Adjust the pos of the handler item - */ + @brief QetGraphicsTableItem::adjustHandlerPos + Adjust the pos of the handler item +*/ void QetGraphicsTableItem::adjustHandlerPos() { m_handler_item.setPos(mapToScene(QRect(QPoint(0,0), size()).bottomRight())); } /** - * @brief QetGraphicsTableItem::setUpHandler - */ + @brief QetGraphicsTableItem::setUpHandler +*/ void QetGraphicsTableItem::setUpHandler() { m_handler_item.setColor(Qt::blue); @@ -759,9 +759,9 @@ void QetGraphicsTableItem::handlerMouseReleaseEvent(QGraphicsSceneMouseEvent *ev } /** - * @brief QetGraphicsTableItem::adjustColumnsWidth - * Adjust the size of each column according to the current table width by setting the sectionSize of the header item - */ + @brief QetGraphicsTableItem::adjustColumnsWidth + Adjust the size of each column according to the current table width by setting the sectionSize of the header item +*/ void QetGraphicsTableItem::adjustColumnsWidth() { if (!m_model) @@ -819,9 +819,9 @@ void QetGraphicsTableItem::dataChanged(const QModelIndex &topLeft, const QModelI } /** - * @brief QetGraphicsTableItem::headerSectionResized - * Connected to the header signal QetGraphicsTableItem sectionResized - */ + @brief QetGraphicsTableItem::headerSectionResized + Connected to the header signal QetGraphicsTableItem sectionResized +*/ void QetGraphicsTableItem::headerSectionResized() { auto header_size = m_header_item->rect().size(); @@ -834,10 +834,10 @@ void QetGraphicsTableItem::headerSectionResized() } /** - * @brief QetGraphicsTableItem::adjustSize - * If needed, this function resize the current height and width of table and/or the size of columns. - * according to there minimum - */ + @brief QetGraphicsTableItem::adjustSize + If needed, this function resize the current height and width of table and/or the size of columns. + according to there minimum +*/ void QetGraphicsTableItem::adjustSize() { //If there is no model, set the size to minimum diff --git a/sources/qetgraphicsitem/ViewItem/qetgraphicstableitem.h b/sources/qetgraphicsitem/ViewItem/qetgraphicstableitem.h index 90bb22215..35e5e449e 100644 --- a/sources/qetgraphicsitem/ViewItem/qetgraphicstableitem.h +++ b/sources/qetgraphicsitem/ViewItem/qetgraphicstableitem.h @@ -28,17 +28,17 @@ class QAbstractItemModel; class QetGraphicsHeaderItem; /** - * @brief The QetGraphicsTableItem class - * This item display a table destined to represent the content of a QAbstractItemModel - * The table have a few parameters to edit her visual aspect. - * Margins, to edit the margin between the cell and the text. - * Text font. - * Text alignment in the cell - * These three parameters are not settable directly with the table but trough the model to be displayed by the table. - * The table search these parameters only in the index(0,0) for all the table. - * By consequence, set data in other index than 0,0 is useless also these parameter can't be set individually for each cell. - * The margins is stored in the model in index Qt::UserRole+1 and for value a QString. See QETUtils::marginsFromString and QETUtils::marginsToString - */ + @brief The QetGraphicsTableItem class + This item display a table destined to represent the content of a QAbstractItemModel + The table have a few parameters to edit her visual aspect. + Margins, to edit the margin between the cell and the text. + Text font. + Text alignment in the cell + These three parameters are not settable directly with the table but trough the model to be displayed by the table. + The table search these parameters only in the index(0,0) for all the table. + By consequence, set data in other index than 0,0 is useless also these parameter can't be set individually for each cell. + The margins is stored in the model in index Qt::UserRole+1 and for value a QString. See QETUtils::marginsFromString and QETUtils::marginsToString +*/ class QetGraphicsTableItem : public QetGraphicsItem { Q_OBJECT diff --git a/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.cpp b/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.cpp index c1e48344d..44feeca0b 100644 --- a/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.cpp +++ b/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.cpp @@ -30,10 +30,10 @@ #include /** - * @brief GraphicsTablePropertiesEditor::GraphicsTablePropertiesEditor - * @param table - * @param parent - */ + @brief GraphicsTablePropertiesEditor::GraphicsTablePropertiesEditor + @param table + @param parent +*/ GraphicsTablePropertiesEditor::GraphicsTablePropertiesEditor(QetGraphicsTableItem *table, QWidget *parent) : PropertiesEditorWidget(parent), ui(new Ui::GraphicsTablePropertiesEditor) @@ -57,17 +57,17 @@ GraphicsTablePropertiesEditor::GraphicsTablePropertiesEditor(QetGraphicsTableIte } /** - * @brief GraphicsTablePropertiesEditor::~GraphicsTablePropertiesEditor - */ + @brief GraphicsTablePropertiesEditor::~GraphicsTablePropertiesEditor +*/ GraphicsTablePropertiesEditor::~GraphicsTablePropertiesEditor() { delete ui; } /** - * @brief GraphicsTablePropertiesEditor::setTable - * Set the table to be edited - * @param table - */ + @brief GraphicsTablePropertiesEditor::setTable + Set the table to be edited + @param table +*/ void GraphicsTablePropertiesEditor::setTable(QetGraphicsTableItem *table) { if (m_table_item) { @@ -97,9 +97,9 @@ void GraphicsTablePropertiesEditor::setTable(QetGraphicsTableItem *table) } /** - * @brief GraphicsTablePropertiesEditor::apply - * Apply the current edition - */ + @brief GraphicsTablePropertiesEditor::apply + Apply the current edition +*/ void GraphicsTablePropertiesEditor::apply() { if(!m_table_item && m_table_item->diagram()) { @@ -113,9 +113,9 @@ void GraphicsTablePropertiesEditor::apply() } /** - * @brief GraphicsTablePropertiesEditor::associatedUndo - * @return the undo command associated to the edition - */ + @brief GraphicsTablePropertiesEditor::associatedUndo + @return the undo command associated to the edition +*/ QUndoCommand *GraphicsTablePropertiesEditor::associatedUndo() const { if (m_live_edit) @@ -198,8 +198,8 @@ bool GraphicsTablePropertiesEditor::setLiveEdit(bool live_edit) } /** - * @brief GraphicsTablePropertiesEditor::on_m_header_font_pb_clicked - */ + @brief GraphicsTablePropertiesEditor::on_m_header_font_pb_clicked +*/ void GraphicsTablePropertiesEditor::on_m_header_font_pb_clicked() { if (m_table_item && m_table_item->model()) @@ -219,8 +219,8 @@ void GraphicsTablePropertiesEditor::on_m_header_font_pb_clicked() } /** - * @brief GraphicsTablePropertiesEditor::on_m_table_font_pb_clicked - */ + @brief GraphicsTablePropertiesEditor::on_m_table_font_pb_clicked +*/ void GraphicsTablePropertiesEditor::on_m_table_font_pb_clicked() { if (m_table_item && m_table_item->model()) @@ -241,8 +241,8 @@ void GraphicsTablePropertiesEditor::on_m_table_font_pb_clicked() } /** - * @brief GraphicsTablePropertiesEditor::updateUi - */ + @brief GraphicsTablePropertiesEditor::updateUi +*/ void GraphicsTablePropertiesEditor::updateUi() { //Disconnect every connections of editor widgets @@ -343,8 +343,8 @@ void GraphicsTablePropertiesEditor::updateInfoLabel() } /** - * @brief GraphicsTablePropertiesEditor::setUpEditConnection - */ + @brief GraphicsTablePropertiesEditor::setUpEditConnection +*/ void GraphicsTablePropertiesEditor::setUpEditConnection() { for (QMetaObject::Connection c : m_edit_connection) { @@ -410,8 +410,8 @@ void GraphicsTablePropertiesEditor::on_m_next_pb_clicked() } /** - * @brief GraphicsTablePropertiesEditor::on_m_auto_geometry_pb_clicked - */ + @brief GraphicsTablePropertiesEditor::on_m_auto_geometry_pb_clicked +*/ void GraphicsTablePropertiesEditor::on_m_auto_geometry_pb_clicked() { if (m_table_item) { @@ -420,8 +420,8 @@ void GraphicsTablePropertiesEditor::on_m_auto_geometry_pb_clicked() } /** - * @brief GraphicsTablePropertiesEditor::on_m_apply_geometry_to_linked_table_pb_clicked - */ + @brief GraphicsTablePropertiesEditor::on_m_apply_geometry_to_linked_table_pb_clicked +*/ void GraphicsTablePropertiesEditor::on_m_apply_geometry_to_linked_table_pb_clicked() { if (m_table_item.isNull() || !m_table_item->diagram() || (!m_table_item->nextTable() && !m_table_item->previousTable())) { diff --git a/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.h b/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.h index f152727e8..449fb2a42 100644 --- a/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.h +++ b/sources/qetgraphicsitem/ViewItem/ui/graphicstablepropertieseditor.h @@ -32,9 +32,9 @@ class QUndoStack; class QButtonGroup; /** - * @brief The GraphicsTablePropertiesEditor class - * This widget is used to edit the property of both QetGraphicsTableItem and QetGraphicsHeaderItem - */ + @brief The GraphicsTablePropertiesEditor class + This widget is used to edit the property of both QetGraphicsTableItem and QetGraphicsHeaderItem +*/ class GraphicsTablePropertiesEditor : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.cpp b/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.cpp index 2108a1c7c..7f7d5b6bc 100644 --- a/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.cpp +++ b/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.cpp @@ -25,10 +25,10 @@ #include /** - * @brief projectDBModelPropertiesWidget::projectDBModelPropertiesWidget - * @param model - * @param parent - */ + @brief projectDBModelPropertiesWidget::projectDBModelPropertiesWidget + @param model + @param parent +*/ ProjectDBModelPropertiesWidget::ProjectDBModelPropertiesWidget(ProjectDBModel *model, QWidget *parent) : PropertiesEditorWidget(parent), ui(new Ui::ProjectDBModelPropertiesWidget) @@ -38,16 +38,16 @@ ProjectDBModelPropertiesWidget::ProjectDBModelPropertiesWidget(ProjectDBModel *m } /** - * @brief projectDBModelPropertiesWidget::~projectDBModelPropertiesWidget - */ + @brief projectDBModelPropertiesWidget::~projectDBModelPropertiesWidget +*/ ProjectDBModelPropertiesWidget::~ProjectDBModelPropertiesWidget() { delete ui; } /** - * @brief projectDBModelPropertiesWidget::setModel - * @param model - */ + @brief projectDBModelPropertiesWidget::setModel + @param model +*/ void ProjectDBModelPropertiesWidget::setModel(ProjectDBModel *model) { m_model = model; ui->m_edit_query_pb->setEnabled(m_model); @@ -55,8 +55,8 @@ void ProjectDBModelPropertiesWidget::setModel(ProjectDBModel *model) { } /** - * @brief projectDBModelPropertiesWidget::on_m_edit_query_pb_clicked - */ + @brief projectDBModelPropertiesWidget::on_m_edit_query_pb_clicked +*/ void ProjectDBModelPropertiesWidget::on_m_edit_query_pb_clicked() { QDialog d(this); diff --git a/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.h b/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.h index c46ca3f04..ca36ae6dc 100644 --- a/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.h +++ b/sources/qetgraphicsitem/ViewItem/ui/projectdbmodelpropertieswidget.h @@ -27,9 +27,9 @@ class ProjectDBModelPropertiesWidget; } /** - * @brief The projectDBModelPropertiesWidget class - * This class is an editor for a NomenclatureModel - */ + @brief The projectDBModelPropertiesWidget class + This class is an editor for a NomenclatureModel +*/ class ProjectDBModelPropertiesWidget : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/qetgraphicsitem/conductor.cpp b/sources/qetgraphicsitem/conductor.cpp index 9acdf6bd0..618ab9d10 100644 --- a/sources/qetgraphicsitem/conductor.cpp +++ b/sources/qetgraphicsitem/conductor.cpp @@ -69,11 +69,11 @@ class ConductorXmlRetroCompatibility }; /** - * @brief Conductor::Conductor - * Default constructor. - * @param p1 : first terminal of this conductor. - * @param p2 : second terminal of this conductor. - */ + @brief Conductor::Conductor + Default constructor. + @param p1 : first terminal of this conductor. + @param p2 : second terminal of this conductor. +*/ Conductor::Conductor(Terminal *p1, Terminal* p2) : terminal1(p1), terminal2(p2), @@ -131,9 +131,9 @@ Conductor::Conductor(Terminal *p1, Terminal* p2) : } /** - * @brief Conductor::~Conductor - * Destructor. The conductor is removed from is terminal - */ + @brief Conductor::~Conductor + Destructor. The conductor is removed from is terminal +*/ Conductor::~Conductor() { removeHandler(); @@ -143,10 +143,10 @@ Conductor::~Conductor() } /** - * @brief Conductor::isValid - * @return true if conductor is valid else false; - * A non valid conductor, is a conductor without two terminal - */ + @brief Conductor::isValid + @return true if conductor is valid else false; + A non valid conductor, is a conductor without two terminal +*/ bool Conductor::isValid() const { return m_valid; } @@ -171,9 +171,9 @@ void Conductor::updatePath(const QRectF &rect) { } /** - * @brief Conductor::segmentsToPath - * Generate the QPainterPath from the list of points - */ + @brief Conductor::segmentsToPath + Generate the QPainterPath from the list of points +*/ void Conductor::segmentsToPath() { QPainterPath path; @@ -606,20 +606,20 @@ bool Conductor::valideXml(QDomElement &e){ } /** - * @brief Conductor::mouseDoubleClickEvent - * Manage the mouse double click - * @param event - */ + @brief Conductor::mouseDoubleClickEvent + Manage the mouse double click + @param event +*/ void Conductor::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { event->accept(); editProperty(); } /** - * @brief Conductor::mousePressEvent - * Manage the mouse press event - * @param event - */ + @brief Conductor::mousePressEvent + Manage the mouse press event + @param event +*/ void Conductor::mousePressEvent(QGraphicsSceneMouseEvent *event) { QGraphicsObject::mousePressEvent(event); @@ -629,9 +629,9 @@ void Conductor::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief Conductor::mouseReleaseEvent - * @param event - */ + @brief Conductor::mouseReleaseEvent + @param event +*/ void Conductor::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (!(event -> modifiers() & Qt::ControlModifier)) @@ -639,10 +639,10 @@ void Conductor::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief Conductor::hoverEnterEvent - * Manage the hover enter event - * @param event - */ + @brief Conductor::hoverEnterEvent + Manage the hover enter event + @param event +*/ void Conductor::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { Q_UNUSED(event); m_mouse_over = true; @@ -650,10 +650,10 @@ void Conductor::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { } /** - * @brief Conductor::hoverLeaveEvent - * Manage the mouse leave event - * @param event - */ + @brief Conductor::hoverLeaveEvent + Manage the mouse leave event + @param event +*/ void Conductor::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { Q_UNUSED(event); update(); @@ -661,11 +661,11 @@ void Conductor::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { } /** - * @brief Conductor::itemChange - * @param change - * @param value - * @return - */ + @brief Conductor::itemChange + @param change + @param value + @return +*/ QVariant Conductor::itemChange(GraphicsItemChange change, const QVariant &value) { if (change == QGraphicsItem::ItemSelectedChange) @@ -702,11 +702,11 @@ QVariant Conductor::itemChange(GraphicsItemChange change, const QVariant &value) } /** - * @brief Conductor::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief Conductor::sceneEventFilter + @param watched + @param event + @return +*/ bool Conductor::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -747,9 +747,9 @@ bool Conductor::sceneEventFilter(QGraphicsItem *watched, QEvent *event) } /** - * @brief Conductor::adjusteHandlerPos - * Adjust the position of the handler item - */ + @brief Conductor::adjusteHandlerPos + Adjust the position of the handler item +*/ void Conductor::adjusteHandlerPos() { if (m_handler_vector.isEmpty()) @@ -764,10 +764,10 @@ void Conductor::adjusteHandlerPos() } /** - * @brief Conductor::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief Conductor::handlerMousePressEvent + @param qghi + @param event +*/ void Conductor::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(event); @@ -787,10 +787,10 @@ void Conductor::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSc } /** - * @brief Conductor::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief Conductor::handlerMouseMoveEvent + @param qghi + @param event +*/ void Conductor::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { if (m_moving_segment) @@ -815,10 +815,10 @@ void Conductor::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSce } /** - * @brief Conductor::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief Conductor::handlerMouseReleaseEvent + @param qghi + @param event +*/ void Conductor::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(event); @@ -839,9 +839,9 @@ void Conductor::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphics } /** - * @brief Conductor::addHandler - * Add handlers for this item - */ + @brief Conductor::addHandler + Add handlers for this item +*/ void Conductor::addHandler() { if (m_handler_vector.isEmpty() && scene()) @@ -859,9 +859,9 @@ void Conductor::addHandler() } /** - * @brief Conductor::removeHandler - * Remove the handlers of this item - */ + @brief Conductor::removeHandler + Remove the handlers of this item +*/ void Conductor::removeHandler() { if (!m_handler_vector.isEmpty()) @@ -872,9 +872,9 @@ void Conductor::removeHandler() } /** - * @brief Conductor::boundingRect - * @return - */ + @brief Conductor::boundingRect + @return +*/ QRectF Conductor::boundingRect() const { QRectF br = shape().boundingRect(); @@ -882,10 +882,10 @@ QRectF Conductor::boundingRect() const } /** - * @brief Conductor::shape - * @return the shape of conductor. - * The shape thickness is bigger when conductor is hovered - */ + @brief Conductor::shape + @return the shape of conductor. + The shape thickness is bigger when conductor is hovered +*/ QPainterPath Conductor::shape() const { QPainterPathStroker pps; @@ -898,9 +898,9 @@ QPainterPath Conductor::shape() const } /** - * @brief Conductor::nearShape - * @return : An area in which it is considered a point is near this conductor. - */ + @brief Conductor::nearShape + @return : An area in which it is considered a point is near this conductor. +*/ QPainterPath Conductor::nearShape() const { QPainterPathStroker pps; @@ -968,11 +968,11 @@ void Conductor::pointsToSegments(const QList& points_list) { } /** - * @brief Conductor::fromXml - * Load the conductor and her information from xml element - * @param e - * @return true is loading success else return false - */ + @brief Conductor::fromXml + Load the conductor and her information from xml element + @param e + @return true is loading success else return false +*/ bool Conductor::fromXml(QDomElement &dom_element) { setPos(dom_element.attribute("x", nullptr).toDouble(), @@ -1061,12 +1061,12 @@ QDomElement Conductor::toXml(QDomDocument &dom_document, QHash } /** - * @brief Conductor::pathFromXml - * Generate the path (of the line) from xml file by checking the segments in the xml - * file - * @param e - * @return true if generate path success else return false - */ + @brief Conductor::pathFromXml + Generate the path (of the line) from xml file by checking the segments in the xml + file + @param e + @return true if generate path success else return false +*/ bool Conductor::pathFromXml(const QDomElement &e) { // parcourt les elements XML "segment" et en extrait deux listes de longueurs // les segments non valides sont ignores @@ -1139,12 +1139,12 @@ bool Conductor::pathFromXml(const QDomElement &e) { } /** - * @brief Conductor::handlerPoints - * @return The points used to draw the handler square, used to modify - * the path of the conductor. - * The points stored in the QVector are the middle point of each segments that compose the conductor, - * at exception of the first and last segment because there just here to extend the terminal. - */ + @brief Conductor::handlerPoints + @return The points used to draw the handler square, used to modify + the path of the conductor. + The points stored in the QVector are the middle point of each segments that compose the conductor, + at exception of the first and last segment because there just here to extend the terminal. +*/ QVector Conductor::handlerPoints() const { QList sl = segmentsList(); @@ -1178,9 +1178,9 @@ const QList Conductor::segmentsList() const { } /** - * @brief Conductor::length - * @return the length of this conductor - */ + @brief Conductor::length + @return the length of this conductor +*/ qreal Conductor::length() const{ return path().length(); } @@ -1206,11 +1206,11 @@ ConductorSegment *Conductor::middleSegment() { } /** - * @brief Conductor::posForText - * Calculate and return the better pos for text. - * @param flag : flag is used to know if text pos is near of - * a vertical or horizontal conductor segment. - */ + @brief Conductor::posForText + Calculate and return the better pos for text. + @param flag : flag is used to know if text pos is near of + a vertical or horizontal conductor segment. +*/ QPointF Conductor::posForText(Qt::Orientations &flag) { @@ -1277,11 +1277,11 @@ QPointF Conductor::posForText(Qt::Orientations &flag) } /** - * @brief Conductor::calculateTextItemPosition - * Move the text at middle of conductor (if is vertical or horizontal) - * otherwise, move conductor at the middle of the longest segment of conductor. - * If text was moved by user, this function do nothing, except check if text is near conductor. - */ + @brief Conductor::calculateTextItemPosition + Move the text at middle of conductor (if is vertical or horizontal) + otherwise, move conductor at the middle of the longest segment of conductor. + If text was moved by user, this function do nothing, except check if text is near conductor. +*/ void Conductor::calculateTextItemPosition() { if (!m_text_item || !diagram() || m_properties.type != ConductorProperties::Multi) @@ -1440,10 +1440,10 @@ ConductorProfile Conductor::profile(Qt::Corner path_type) const { } /** - * @brief Conductor::refreshText - * Refresh the text of this conductor. - * recalcule and set the text according to the formula. - */ + @brief Conductor::refreshText + Refresh the text of this conductor. + recalcule and set the text according to the formula. +*/ void Conductor::refreshText() { if (m_freeze_label) @@ -1489,13 +1489,13 @@ QPainterPath Conductor::path() const } /** - * @brief Conductor::setPropertiesToPotential - * @param properties - * @param only_text - * Set @propertie to conductor and every conductors in the same potential of @conductor. - * If @only_text is true only formula, text, function and tension/protocol is set - * to other conductor in the same potential, the other values of property stay unmodified - */ + @brief Conductor::setPropertiesToPotential + @param properties + @param only_text + Set @propertie to conductor and every conductors in the same potential of @conductor. + If @only_text is true only formula, text, function and tension/protocol is set + to other conductor in the same potential, the other values of property stay unmodified +*/ void Conductor::setPropertyToPotential(const ConductorProperties &property, bool only_text) { setProperties(property); @@ -1522,10 +1522,10 @@ void Conductor::setPropertyToPotential(const ConductorProperties &property, bool } /** - * @brief Conductor::setProperties - * Set @property as current property of conductor - * @param properties : properties - */ + @brief Conductor::setProperties + Set @property as current property of conductor + @param properties : properties +*/ void Conductor::setProperties(const ConductorProperties &property) { if (m_properties == property) return; @@ -1566,9 +1566,9 @@ void Conductor::setProperties(const ConductorProperties &property) } /** - * @brief Conductor::properties - * @return the properties of this Conductor - */ + @brief Conductor::properties + @return the properties of this Conductor +*/ ConductorProperties Conductor::properties() const { return(m_properties); @@ -1590,10 +1590,10 @@ void Conductor::setHighlighted(Conductor::Highlight hl) { } /** - * @brief Conductor::displayedTextChanged - * Update the properties (text) of this conductor and other conductors - * at the same potential of this conductor. - */ + @brief Conductor::displayedTextChanged + Update the properties (text) of this conductor and other conductors + at the same potential of this conductor. +*/ void Conductor::displayedTextChanged() { QVariant old_value, new_value; @@ -1627,14 +1627,14 @@ void Conductor::displayedTextChanged() /** - * @brief Conductor::relatedPotentialConductors - * Return all conductors at the same potential of this conductor, this conductor isn't - * part of the returned QSet. - * @param all_diagram : if true search in all diagram of the project, - * false search only in the parent diagram of this conductor - * @param t_list, a list of terminal already found for this potential. - * @return a QSet of conductor at the same potential. - */ + @brief Conductor::relatedPotentialConductors + Return all conductors at the same potential of this conductor, this conductor isn't + part of the returned QSet. + @param all_diagram : if true search in all diagram of the project, + false search only in the parent diagram of this conductor + @param t_list, a list of terminal already found for this potential. + @return a QSet of conductor at the same potential. +*/ QSet Conductor::relatedPotentialConductors(const bool all_diagram, QList *t_list) { bool declar_t_list = false; @@ -1688,9 +1688,9 @@ QSet Conductor::relatedPotentialConductors(const bool all_diagram, } /** - * @brief Conductor::diagramEditor - * @return The parent diagram editor or nullptr; - */ + @brief Conductor::diagramEditor + @return The parent diagram editor or nullptr; +*/ QETDiagramEditor* Conductor::diagramEditor() const { if (!diagram()) return nullptr; if (diagram() -> views().isEmpty()) return nullptr; @@ -1703,8 +1703,8 @@ QETDiagramEditor* Conductor::diagramEditor() const { } /** - * @brief Conductor::editProperty - */ + @brief Conductor::editProperty +*/ void Conductor::editProperty() { ConductorPropertiesDialog::PropertiesDialog(this, diagramEditor()); } @@ -1716,11 +1716,11 @@ void Conductor::setSequenceNum(const autonum::sequentialNumbers& sn) } /** - * @brief Conductor::setUpConnectionForFormula - * setup connection according to the variable of formula - * @param old_formula - * @param new_formula - */ + @brief Conductor::setUpConnectionForFormula + setup connection according to the variable of formula + @param old_formula + @param new_formula +*/ void Conductor::setUpConnectionForFormula(QString old_formula, QString new_formula) { if (diagram()) @@ -1909,9 +1909,9 @@ ConductorProfilesGroup Conductor::profiles() const { } /** - * @brief Conductor::setProfiles - * @param cpg : the new profils of conductor - */ + @brief Conductor::setProfiles + @param cpg : the new profils of conductor +*/ void Conductor::setProfiles(const ConductorProfilesGroup &cpg) { conductor_profiles = cpg; if (conductor_profiles[currentPathType()].isNull()) { @@ -1988,11 +1988,11 @@ QPointF Conductor::movePointIntoPolygon(const QPointF &point, const QPainterPath } /** - * @brief longuestConductorInPotential - * @param conductor : a conductor in the potential to search - * @param all_diagram : true -> search in the whole project, false -> search only in the diagram of conductor - * @return the longuest conductor in the same potential of conductor - */ + @brief longuestConductorInPotential + @param conductor : a conductor in the potential to search + @param all_diagram : true -> search in the whole project, false -> search only in the diagram of conductor + @return the longuest conductor in the same potential of conductor +*/ Conductor * longuestConductorInPotential(Conductor *conductor, bool all_diagram) { Conductor *longuest_conductor = conductor; //Search the longuest conductor @@ -2004,11 +2004,11 @@ Conductor * longuestConductorInPotential(Conductor *conductor, bool all_diagram) } /** - * @brief relatedConductors - * @param conductor - * @return return all conductors who share the same terminals of @conductor given as parametre, - * except @conductor himself. - */ + @brief relatedConductors + @param conductor + @return return all conductors who share the same terminals of @conductor given as parametre, + except @conductor himself. +*/ QList relatedConductors(const Conductor *conductor) { QList other_conductors_list = conductor -> terminal1 -> conductors(); other_conductors_list << conductor -> terminal2->conductors(); @@ -2017,11 +2017,11 @@ QList relatedConductors(const Conductor *conductor) { } /** - * @brief Conductor::setFreezeLabel - * Freeze this conductor label if true - * Unfreeze this conductor label if false - * @param freeze - */ + @brief Conductor::setFreezeLabel + Freeze this conductor label if true + Unfreeze this conductor label if false + @param freeze +*/ void Conductor::setFreezeLabel(bool freeze) { m_freeze_label = freeze; diff --git a/sources/qetgraphicsitem/conductor.h b/sources/qetgraphicsitem/conductor.h index 818ba1444..949569de1 100644 --- a/sources/qetgraphicsitem/conductor.h +++ b/sources/qetgraphicsitem/conductor.h @@ -68,10 +68,12 @@ class Conductor : public QGraphicsObject Terminal *terminal2; public: - /** - * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into a conductor. - * @return the QGraphicsItem type - */ + /** + @brief type + Enable the use of qgraphicsitem_cast + to safely cast a QGraphicsItem into a conductor. + @return the QGraphicsItem type + */ int type() const override { return Type; } Diagram *diagram() const; ConductorTextItem *textItem() const; diff --git a/sources/qetgraphicsitem/conductortextitem.cpp b/sources/qetgraphicsitem/conductortextitem.cpp index 012d98a43..2812c85d9 100644 --- a/sources/qetgraphicsitem/conductortextitem.cpp +++ b/sources/qetgraphicsitem/conductortextitem.cpp @@ -62,10 +62,10 @@ Conductor *ConductorTextItem::parentConductor() const { } /** - * @brief ConductorTextItem::fromXml - * Read the properties stored in the xml element given in parameter - * @param e - */ + @brief ConductorTextItem::fromXml + Read the properties stored in the xml element given in parameter + @param e +*/ void ConductorTextItem::fromXml(const QDomElement &e) { if (e.hasAttribute("userx")) { setPos(e.attribute("userx").toDouble(), @@ -87,9 +87,9 @@ bool ConductorTextItem::wasMovedByUser() const { } /** - * @brief ConductorTextItem::wasRotateByUser - * @return true if text was explicit moved by user else false - */ + @brief ConductorTextItem::wasRotateByUser + @return true if text was explicit moved by user else false +*/ bool ConductorTextItem::wasRotateByUser() const { return(rotate_by_user_); } @@ -110,11 +110,11 @@ void ConductorTextItem::forceMovedByUser(bool moved_by_user) { } /** - * @brief ConductorTextItem::forceRotateByUser - * @param rotate_by_user true pour que la rotation du texte soit consideree + @brief ConductorTextItem::forceRotateByUser + @param rotate_by_user true pour que la rotation du texte soit consideree comme ayant ete definie par l'utilisateur (et donc soit sauvegardee), false pour remettre le texte a sont angle originelle - */ +*/ void ConductorTextItem::forceRotateByUser(bool rotate_by_user) { if (rotate_by_user == rotate_by_user_) return; @@ -125,9 +125,9 @@ void ConductorTextItem::forceRotateByUser(bool rotate_by_user) { } /** - * @brief ConductorTextItem::setPos - * @param pos - */ + @brief ConductorTextItem::setPos + @param pos +*/ void ConductorTextItem::setPos(const QPointF &pos) { /* @@ -149,10 +149,10 @@ void ConductorTextItem::setPos(const QPointF &pos) } /** - * @brief ConductorTextItem::setPos - * @param x - * @param y - */ + @brief ConductorTextItem::setPos + @param x + @param y +*/ void ConductorTextItem::setPos(qreal x, qreal y) { QPointF p(x,y); @@ -160,18 +160,18 @@ void ConductorTextItem::setPos(qreal x, qreal y) } /** - * @brief ConductorTextItem::mousePressEvent - * @param event - */ + @brief ConductorTextItem::mousePressEvent + @param event +*/ void ConductorTextItem::mousePressEvent(QGraphicsSceneMouseEvent *event) { before_mov_pos_ = pos(); DiagramTextItem::mousePressEvent(event); } /** - * @brief ConductorTextItem::mouseMoveEvent - * @param event - */ + @brief ConductorTextItem::mouseMoveEvent + @param event +*/ void ConductorTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if (textInteractionFlags() & Qt::TextEditable) QGraphicsTextItem::mouseMoveEvent(event); @@ -194,9 +194,9 @@ void ConductorTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief ConductorTextItem::mouseReleaseEvent - * @param e - */ + @brief ConductorTextItem::mouseReleaseEvent + @param e +*/ void ConductorTextItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *e) { if (flags() & QGraphicsItem::ItemIsMovable) { diff --git a/sources/qetgraphicsitem/diagramimageitem.cpp b/sources/qetgraphicsitem/diagramimageitem.cpp index bf80136c6..812dadf99 100644 --- a/sources/qetgraphicsitem/diagramimageitem.cpp +++ b/sources/qetgraphicsitem/diagramimageitem.cpp @@ -21,10 +21,10 @@ #include "imagepropertieswidget.h" /** - * @brief DiagramImageItem::DiagramImageItem - * Constructor without pixmap - * @param parent_item the parent graphics item - */ + @brief DiagramImageItem::DiagramImageItem + Constructor without pixmap + @param parent_item the parent graphics item +*/ DiagramImageItem::DiagramImageItem(QetGraphicsItem *parent_item): QetGraphicsItem(parent_item) { @@ -32,11 +32,11 @@ DiagramImageItem::DiagramImageItem(QetGraphicsItem *parent_item): } /** - * @brief DiagramImageItem::DiagramImageItem - * Constructor with pixmap - * @param pixmap the pixmap to be draw - * @param parent_item the parent graphic item - */ + @brief DiagramImageItem::DiagramImageItem + Constructor with pixmap + @param pixmap the pixmap to be draw + @param parent_item the parent graphic item +*/ DiagramImageItem::DiagramImageItem(const QPixmap &pixmap, QetGraphicsItem *parent_item): QetGraphicsItem(parent_item), pixmap_(pixmap) @@ -46,19 +46,19 @@ DiagramImageItem::DiagramImageItem(const QPixmap &pixmap, QetGraphicsItem *paren } /** - * @brief DiagramImageItem::~DiagramImageItem - * Destructor - */ + @brief DiagramImageItem::~DiagramImageItem + Destructor +*/ DiagramImageItem::~DiagramImageItem() { } /** - * @brief DiagramImageItem::paint - * Draw the pixmap. - * @param painter the Qpainter to use for draw the pixmap - * @param option the style option - * @param widget the QWidget where we draw the pixmap - */ + @brief DiagramImageItem::paint + Draw the pixmap. + @param painter the Qpainter to use for draw the pixmap + @param option the style option + @param widget the QWidget where we draw the pixmap +*/ void DiagramImageItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { painter -> drawPixmap(pixmap_.rect(),pixmap_); @@ -80,9 +80,9 @@ void DiagramImageItem::paint(QPainter *painter, const QStyleOptionGraphicsItem * } /** - * @brief DiagramImageItem::editProperty - * Open the approriate dialog to edit this image - */ + @brief DiagramImageItem::editProperty + Open the approriate dialog to edit this image +*/ void DiagramImageItem::editProperty() { if (diagram() -> isReadOnly()) return; @@ -91,21 +91,21 @@ void DiagramImageItem::editProperty() } /** - * @brief DiagramImageItem::setPixmap - * Set the new pixmap to be draw - * @param pixmap the new pixmap - */ + @brief DiagramImageItem::setPixmap + Set the new pixmap to be draw + @param pixmap the new pixmap +*/ void DiagramImageItem::setPixmap(const QPixmap &pixmap) { pixmap_ = pixmap; setTransformOriginPoint(boundingRect().center()); } /** - * @brief DiagramImageItem::boundingRect - * the outer bounds of the item as a rectangle, - * if no pixmap are set, return a default QRectF - * @return a QRectF represent the bounding rectangle - */ + @brief DiagramImageItem::boundingRect + the outer bounds of the item as a rectangle, + if no pixmap are set, return a default QRectF + @return a QRectF represent the bounding rectangle +*/ QRectF DiagramImageItem::boundingRect() const { if (!pixmap_.isNull()) { return (QRectF(pixmap_.rect())); @@ -116,19 +116,19 @@ QRectF DiagramImageItem::boundingRect() const { } /** - * @brief DiagramImageItem::name - * @return the generic name of this item (picture) - */ + @brief DiagramImageItem::name + @return the generic name of this item (picture) +*/ QString DiagramImageItem::name() const { return tr("une image"); } /** - * @brief DiagramImageItem::fromXml - * Load this image fro xml elemebt @e - * @param e - * @return true if succesfully load. - */ + @brief DiagramImageItem::fromXml + Load this image fro xml elemebt @e + @param e + @return true if succesfully load. +*/ bool DiagramImageItem::fromXml(const QDomElement &e) { if (e.tagName() != "image") { diff --git a/sources/qetgraphicsitem/diagramtextitem.cpp b/sources/qetgraphicsitem/diagramtextitem.cpp index b9f8d9024..c2687fa06 100644 --- a/sources/qetgraphicsitem/diagramtextitem.cpp +++ b/sources/qetgraphicsitem/diagramtextitem.cpp @@ -22,18 +22,18 @@ #include "diagram.h" /** - * @brief DiagramTextItem::DiagramTextItem - * @param parent : parent item - */ + @brief DiagramTextItem::DiagramTextItem + @param parent : parent item +*/ DiagramTextItem::DiagramTextItem(QGraphicsItem *parent) : QGraphicsTextItem(parent) { build(); } /** - * @brief DiagramTextItem::DiagramTextItem - * @param text : text to display - * @param parent : parent item - */ + @brief DiagramTextItem::DiagramTextItem + @param text : text to display + @param parent : parent item +*/ DiagramTextItem::DiagramTextItem(const QString &text, QGraphicsItem *parent) : QGraphicsTextItem(text, parent), m_mouse_hover(false), @@ -41,9 +41,9 @@ DiagramTextItem::DiagramTextItem(const QString &text, QGraphicsItem *parent) : { build(); } /** - * @brief DiagramTextItem::build - * Build this item with default value - */ + @brief DiagramTextItem::build + Build this item with default value +*/ void DiagramTextItem::build() { //set Zvalue at 10 to be upper than the DiagramImageItem @@ -57,19 +57,19 @@ void DiagramTextItem::build() } /** - * @brief DiagramTextItem::diagram - * @return The diagram of this item or 0 if this text isn't in a diagram - */ + @brief DiagramTextItem::diagram + @return The diagram of this item or 0 if this text isn't in a diagram +*/ Diagram *DiagramTextItem::diagram() const { return(qobject_cast(scene())); } /** - * @brief DiagramTextItem::toXml - * This method do nothing and return an empty DomElement - * This is used to be inherited by child class - * @return - */ + @brief DiagramTextItem::toXml + This method do nothing and return an empty DomElement + This is used to be inherited by child class + @return +*/ QDomElement DiagramTextItem::toXml(QDomDocument &) const { return QDomElement(); } @@ -186,9 +186,9 @@ Qt::Alignment DiagramTextItem::alignment() const } /** - * @brief DiagramTextItem::frameRect - * @return the rect used to draw a frame around this text - */ + @brief DiagramTextItem::frameRect + @return the rect used to draw a frame around this text +*/ QRectF DiagramTextItem::frameRect() const { //Get the bounding rectangle of the text @@ -226,13 +226,13 @@ bool DiagramTextItem::isHtml() const { } /** - * @brief DiagramTextItem::paint - * Draw this text field. This method draw the text by calling QGraphicsTextItem::paint. - * If text is hovered, this method draw the bounding rect in grey - * @param painter : painter to use - * @param option : style option - * @param widget : widget where must to draw - */ + @brief DiagramTextItem::paint + Draw this text field. This method draw the text by calling QGraphicsTextItem::paint. + If text is hovered, this method draw the bounding rect in grey + @param painter : painter to use + @param option : style option + @param widget : widget where must to draw +*/ void DiagramTextItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { painter -> setRenderHint(QPainter::Antialiasing, false); @@ -261,9 +261,9 @@ void DiagramTextItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *o } /** - * @brief DiagramTextItem::focusInEvent - * @param e - */ + @brief DiagramTextItem::focusInEvent + @param e +*/ void DiagramTextItem::focusInEvent(QFocusEvent *event) { QGraphicsTextItem::focusInEvent(event); @@ -275,9 +275,9 @@ void DiagramTextItem::focusInEvent(QFocusEvent *event) } /** - * @brief DiagramTextItem::focusOutEvent - * @param event - */ + @brief DiagramTextItem::focusOutEvent + @param event +*/ void DiagramTextItem::focusOutEvent(QFocusEvent *event) { QGraphicsTextItem::focusOutEvent(event); @@ -313,9 +313,9 @@ void DiagramTextItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief DiagramTextItem::mousePressEvent - * @param event - */ + @brief DiagramTextItem::mousePressEvent + @param event +*/ void DiagramTextItem::mousePressEvent (QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton) @@ -328,9 +328,9 @@ void DiagramTextItem::mousePressEvent (QGraphicsSceneMouseEvent *event) } /** - * @brief DiagramTextItem::mouseMoveEvent - * @param event - */ + @brief DiagramTextItem::mouseMoveEvent + @param event +*/ void DiagramTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if (textInteractionFlags() & Qt::TextEditable) QGraphicsTextItem::mouseMoveEvent(event); @@ -359,9 +359,9 @@ void DiagramTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { } /** - * @brief DiagramTextItem::mouseReleaseEvent - * @param event - */ + @brief DiagramTextItem::mouseReleaseEvent + @param event +*/ void DiagramTextItem::mouseReleaseEvent (QGraphicsSceneMouseEvent *event) { //Signal to diagram movement is finish @@ -394,19 +394,19 @@ void DiagramTextItem::applyRotation(const qreal &angle) { } /** - * @brief DiagramTextItem::prepareAlignment - * Call this function before changing the bounding rect of this text. - */ + @brief DiagramTextItem::prepareAlignment + Call this function before changing the bounding rect of this text. +*/ void DiagramTextItem::prepareAlignment() { m_alignment_rect = boundingRect(); } /** - * @brief DiagramTextItem::finishAlignment - * Call this function after changing the bouding rect of this text - * to set the position of this text according to the alignment property. - */ + @brief DiagramTextItem::finishAlignment + Call this function after changing the bouding rect of this text + to set the position of this text according to the alignment property. +*/ void DiagramTextItem::finishAlignment() { if(m_block_alignment) @@ -448,8 +448,8 @@ void DiagramTextItem::finishAlignment() } /** - * @brief Edit the text with HtmlEditor - */ + @brief Edit the text with HtmlEditor +*/ void DiagramTextItem::edit() { QWidget *parent = nullptr; diff --git a/sources/qetgraphicsitem/dynamicelementtextitem.cpp b/sources/qetgraphicsitem/dynamicelementtextitem.cpp index ba8ea4fcb..3d4cf2257 100644 --- a/sources/qetgraphicsitem/dynamicelementtextitem.cpp +++ b/sources/qetgraphicsitem/dynamicelementtextitem.cpp @@ -31,10 +31,10 @@ #include /** - * @brief DynamicElementTextItem::DynamicElementTextItem - * Constructor - * @param parent_element - */ + @brief DynamicElementTextItem::DynamicElementTextItem + Constructor + @param parent_element +*/ DynamicElementTextItem::DynamicElementTextItem(Element *parent_element) : m_parent_element(parent_element), m_uuid(QUuid::createUuid()) @@ -66,9 +66,9 @@ DynamicElementTextItem::~DynamicElementTextItem() {} /** - * @brief DynamicElementTextItem::textFromMetaEnum - * @return The QMetaEnum of the enum TextFrom - */ + @brief DynamicElementTextItem::textFromMetaEnum + @return The QMetaEnum of the enum TextFrom +*/ QMetaEnum DynamicElementTextItem::textFromMetaEnum() { DynamicElementTextItem deti; @@ -79,11 +79,11 @@ DynamicElementTextItem::DynamicElementTextItem() {} /** - * @brief DynamicElementTextItem::toXml - * Export this text to xml - * @param dom_doc - * @return - */ + @brief DynamicElementTextItem::toXml + Export this text to xml + @param dom_doc + @return +*/ QDomElement DynamicElementTextItem::toXml(QDomDocument &dom_doc) const { QDomElement root_element = dom_doc.createElement(xmlTagName()); @@ -147,10 +147,10 @@ QDomElement DynamicElementTextItem::toXml(QDomDocument &dom_doc) const } /** - * @brief DynamicElementTextItem::fromXml - * Import this text from xml - * @param dom_elmt - */ + @brief DynamicElementTextItem::fromXml + Import this text from xml + @param dom_elmt +*/ void DynamicElementTextItem::fromXml(const QDomElement &dom_elmt) { if (dom_elmt.tagName() != xmlTagName()) { @@ -219,20 +219,20 @@ void DynamicElementTextItem::fromXml(const QDomElement &dom_elmt) } /** - * @brief DynamicElementTextItem::ParentElement - * @return a pointer to the parent element. Note the pointer can be null. - * Note that the text can return a parent element, - * even if the text belong to a group of this same element. - */ + @brief DynamicElementTextItem::ParentElement + @return a pointer to the parent element. Note the pointer can be null. + Note that the text can return a parent element, + even if the text belong to a group of this same element. +*/ Element *DynamicElementTextItem::parentElement() const { return m_parent_element; } /** - * @brief DynamicElementTextItem::parentGroup - * @return The group where this text belong, if this item - * is note in a group, return nullptr. - */ + @brief DynamicElementTextItem::parentGroup + @return The group where this text belong, if this item + is note in a group, return nullptr. +*/ ElementTextItemGroup *DynamicElementTextItem::parentGroup() const { if(parentItem()) @@ -245,16 +245,16 @@ ElementTextItemGroup *DynamicElementTextItem::parentGroup() const } /** - * @brief DynamicElementTextItem::elementUseForInfo - * @return a pointer to the element we must use for the variable information. - * If this text is owned by a simple element, the simple element is returned, this is the same element returned by the function parentElement(). - * If this text is owned by a master element, the master element is returned, this is the same element returned by the function parentElement(). - * If this text is owned by a report element, the report element is returned, this is the same element returned by the function parentElement(). - * If this text is owned by a terminal element, the terminal element is returned, this is the same element returned by the function parentElement(). - * If this text is owned by a slave element, we return the master element set as master of the parent slave element, - * if the parent slave is not linked to a master, this function return a nullptr. - * If this text have no parent element, return nullptr - */ + @brief DynamicElementTextItem::elementUseForInfo + @return a pointer to the element we must use for the variable information. + If this text is owned by a simple element, the simple element is returned, this is the same element returned by the function parentElement(). + If this text is owned by a master element, the master element is returned, this is the same element returned by the function parentElement(). + If this text is owned by a report element, the report element is returned, this is the same element returned by the function parentElement(). + If this text is owned by a terminal element, the terminal element is returned, this is the same element returned by the function parentElement(). + If this text is owned by a slave element, we return the master element set as master of the parent slave element, + if the parent slave is not linked to a master, this function return a nullptr. + If this text have no parent element, return nullptr +*/ Element *DynamicElementTextItem::elementUseForInfo() const { Element *elmt = parentElement(); @@ -286,10 +286,10 @@ Element *DynamicElementTextItem::elementUseForInfo() const } /** - * @brief DynamicElementTextItem::refreshLabelConnection - * Refresh the connection of this text when the source of text is label, - * or composite text, with a variable %{label} - */ + @brief DynamicElementTextItem::refreshLabelConnection + Refresh the connection of this text when the source of text is label, + or composite text, with a variable %{label} +*/ void DynamicElementTextItem::refreshLabelConnection() { if ((m_text_from == ElementInfo && m_info_name == "label") || @@ -309,18 +309,18 @@ void DynamicElementTextItem::refreshLabelConnection() } /** - * @brief DynamicElementTextItem::textFrom - * @return what the final text is created from. - */ + @brief DynamicElementTextItem::textFrom + @return what the final text is created from. +*/ DynamicElementTextItem::TextFrom DynamicElementTextItem::textFrom() const { return m_text_from; } /** - * @brief DynamicElementTextItem::setTextFrom - * Set the final text is created from. - * @param text_from - */ + @brief DynamicElementTextItem::setTextFrom + Set the final text is created from. + @param text_from +*/ void DynamicElementTextItem::setTextFrom(DynamicElementTextItem::TextFrom text_from) { if(m_text_from == text_from) @@ -372,18 +372,18 @@ void DynamicElementTextItem::setTextFrom(DynamicElementTextItem::TextFrom text_f } /** - * @brief DynamicElementTextItem::text - * @return the text of this text - */ + @brief DynamicElementTextItem::text + @return the text of this text +*/ QString DynamicElementTextItem::text() const { return m_text; } /** - * @brief DynamicElementTextItem::setText - * Set the text of this text - * @param formula - */ + @brief DynamicElementTextItem::setText + Set the text of this text + @param formula +*/ void DynamicElementTextItem::setText(const QString &text) { m_text = text; @@ -393,10 +393,10 @@ void DynamicElementTextItem::setText(const QString &text) } /** - * @brief DynamicElementTextItem::setInfoName - * Set the information name of the parent element. - * @param info_name - */ + @brief DynamicElementTextItem::setInfoName + Set the information name of the parent element. + @param info_name +*/ void DynamicElementTextItem::setInfoName(const QString &info_name) { QString old_info_name = m_info_name; @@ -439,18 +439,18 @@ void DynamicElementTextItem::setInfoName(const QString &info_name) } /** - * @brief DynamicElementTextItem::infoName - * @return the info name of this text - */ + @brief DynamicElementTextItem::infoName + @return the info name of this text +*/ QString DynamicElementTextItem::infoName() const { return m_info_name; } /** - * @brief DynamicElementTextItem::setCompositeText - * Set the composite text of this text item to @text - * @param text - */ + @brief DynamicElementTextItem::setCompositeText + Set the composite text of this text item to @text + @param text +*/ void DynamicElementTextItem::setCompositeText(const QString &text) { QString old_composite_text = m_composite_text; @@ -495,9 +495,9 @@ void DynamicElementTextItem::setCompositeText(const QString &text) } /** - * @brief DynamicElementTextItem::compositeText - * @return - */ + @brief DynamicElementTextItem::compositeText + @return +*/ QString DynamicElementTextItem::compositeText() const { return m_composite_text; @@ -521,9 +521,9 @@ QUuid DynamicElementTextItem::uuid() const } /** - * @brief DynamicElementTextItem::mousePressEvent - * @param event - */ + @brief DynamicElementTextItem::mousePressEvent + @param event +*/ void DynamicElementTextItem::mousePressEvent(QGraphicsSceneMouseEvent *event) { //The text become selected, we set the real color, otherwise the editor will display the color of text as blue, @@ -540,9 +540,9 @@ void DynamicElementTextItem::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DynamicElementTextItem::mouseMoveEvent - * @param event - */ + @brief DynamicElementTextItem::mouseMoveEvent + @param event +*/ void DynamicElementTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if((event->buttons() & Qt::LeftButton) && (flags() & ItemIsMovable)) @@ -576,9 +576,9 @@ void DynamicElementTextItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DynamicElementTextItem::mouseReleaseEvent - * @param event - */ + @brief DynamicElementTextItem::mouseReleaseEvent + @param event +*/ void DynamicElementTextItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (m_parent_element) @@ -592,12 +592,12 @@ void DynamicElementTextItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief DynamicElementTextItem::mouseDoubleClickEvent - * Reimplemented functions, for add extra feature when this text is owned by a slave. - * In this case if the parent slave element is linked to a master, and this text display the label of the master - * (both if the 'text from' is 'element info' or 'composite text') the QGraphicsView go to master and select it. - * @param event - */ + @brief DynamicElementTextItem::mouseDoubleClickEvent + Reimplemented functions, for add extra feature when this text is owned by a slave. + In this case if the parent slave element is linked to a master, and this text display the label of the master + (both if the 'text from' is 'element info' or 'composite text') the QGraphicsView go to master and select it. + @param event +*/ void DynamicElementTextItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { DiagramTextItem::mouseDoubleClickEvent(event); @@ -605,12 +605,12 @@ void DynamicElementTextItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *eve } /** - * @brief DynamicElementTextItem::hoverEnterEvent - * If the parent element of this text is a folio report or a slave element, the element is linked - * and the text display the variable "label" we set the text blue for signal the user that the text act like - * a link when we double click on. - * @param event - */ + @brief DynamicElementTextItem::hoverEnterEvent + If the parent element of this text is a folio report or a slave element, the element is linked + and the text display the variable "label" we set the text blue for signal the user that the text act like + a link when we double click on. + @param event +*/ void DynamicElementTextItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { DiagramTextItem::hoverEnterEvent(event); @@ -632,9 +632,9 @@ void DynamicElementTextItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) } /** - * @brief DynamicElementTextItem::hoverLeaveEvent - * @param event - */ + @brief DynamicElementTextItem::hoverLeaveEvent + @param event +*/ void DynamicElementTextItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { DiagramTextItem::hoverLeaveEvent(event); @@ -806,10 +806,10 @@ void DynamicElementTextItem::elementInfoChanged() } /** - * @brief DynamicElementTextItem::masterChanged - * This function is only use when the parent element is a slave. - * Call when the master element linked to the parent slave element of this text change - */ + @brief DynamicElementTextItem::masterChanged + This function is only use when the parent element is a slave. + Call when the master element linked to the parent slave element of this text change +*/ void DynamicElementTextItem::masterChanged() { //First we remove the old connection @@ -834,10 +834,10 @@ void DynamicElementTextItem::masterChanged() } /** - * @brief DynamicElementTextItem::reportChanged - * This function is only use when parent element of this text is a folio report - * The linked report of the parent element was changed - */ + @brief DynamicElementTextItem::reportChanged + This function is only use when parent element of this text is a folio report + The linked report of the parent element was changed +*/ void DynamicElementTextItem::reportChanged() { /* @@ -880,9 +880,9 @@ void DynamicElementTextItem::reportChanged() } /** - * @brief DynamicElementTextItem::reportFormulaChanged - * The report formula use in the project was changed - */ + @brief DynamicElementTextItem::reportFormulaChanged + The report formula use in the project was changed +*/ void DynamicElementTextItem::reportFormulaChanged() { m_report_formula = parentElement()->diagram()->project()->defaultReportProperties(); @@ -947,9 +947,9 @@ void DynamicElementTextItem::removeConnectionForReportFormula(const QString &for } /** - * @brief DynamicElementTextItem::setupFormulaConnection - * Setup the required connection for the formula of the label. - */ + @brief DynamicElementTextItem::setupFormulaConnection + Setup the required connection for the formula of the label. +*/ void DynamicElementTextItem::setupFormulaConnection() { if ((m_text_from == ElementInfo && m_info_name == "label") || @@ -1006,9 +1006,9 @@ void DynamicElementTextItem::updateReportFormulaConnection() } /** - * @brief DynamicElementTextItem::updateReportText - * This function is only use when this text is owned by a report, and this text have for info the Label. - */ + @brief DynamicElementTextItem::updateReportText + This function is only use when this text is owned by a report, and this text have for info the Label. +*/ void DynamicElementTextItem::updateReportText() { if(!(m_parent_element.data()->linkType() & Element::AllReport)) @@ -1034,11 +1034,11 @@ void DynamicElementTextItem::updateReportText() } /** - * @brief DynamicElementTextItem::updateLabel - * Update the displayed text, when this dynamic text is based on the label of the parent element. - * This function is notably use when the label itself is based from a formula. - * If this dynamic text isn't based on label, this function do nothing. - */ + @brief DynamicElementTextItem::updateLabel + Update the displayed text, when this dynamic text is based on the label of the parent element. + This function is notably use when the label itself is based from a formula. + If this dynamic text isn't based on label, this function do nothing. +*/ void DynamicElementTextItem::updateLabel() { if ((m_text_from == ElementInfo && m_info_name == "label") || @@ -1061,10 +1061,10 @@ void DynamicElementTextItem::updateLabel() } /** - * @brief DynamicElementTextItem::conductorWasAdded - * Function only use when parent element is a folio report - * @param conductor - */ + @brief DynamicElementTextItem::conductorWasAdded + Function only use when parent element is a folio report + @param conductor +*/ void DynamicElementTextItem::conductorWasAdded(Conductor *conductor) { Q_UNUSED(conductor) @@ -1072,10 +1072,10 @@ void DynamicElementTextItem::conductorWasAdded(Conductor *conductor) } /** - * @brief DynamicElementTextItem::conductorWasRemoved - * Function only use when parent element is a folio report - * @param conductor - */ + @brief DynamicElementTextItem::conductorWasRemoved + Function only use when parent element is a folio report + @param conductor +*/ void DynamicElementTextItem::conductorWasRemoved(Conductor *conductor) { if(m_watched_conductor.data() == conductor) @@ -1087,10 +1087,10 @@ void DynamicElementTextItem::conductorWasRemoved(Conductor *conductor) } /** - * @brief DynamicElementTextItem::setPotentialConductor - * This function is only used when the parent element of this text is a report element - * Get a conductor in the potential of the parent report - */ + @brief DynamicElementTextItem::setPotentialConductor + This function is only used when the parent element of this text is a report element + Get a conductor in the potential of the parent report +*/ void DynamicElementTextItem::setPotentialConductor() { if(parentElement() && (parentElement()->linkType() & Element::AllReport)) @@ -1137,9 +1137,9 @@ void DynamicElementTextItem::setPotentialConductor() } /** - * @brief DynamicElementTextItem::conductorPropertiesChanged - * This function is only used when the parent element of this text is a report element - */ + @brief DynamicElementTextItem::conductorPropertiesChanged + This function is only used when the parent element of this text is a report element +*/ void DynamicElementTextItem::conductorPropertiesChanged() { if(m_parent_element && (m_parent_element.data()->linkType() & Element::AllReport)) @@ -1162,11 +1162,11 @@ void DynamicElementTextItem::conductorPropertiesChanged() } /** - * @brief DynamicElementTextItem::reportReplacedCompositeText - * This function is only used when the parent element of this text is a report element - * @return the composite text with the variable replaced by the real value. - * If the parent element of this text is not a folio report, return a default QString. - */ + @brief DynamicElementTextItem::reportReplacedCompositeText + This function is only used when the parent element of this text is a report element + @return the composite text with the variable replaced by the real value. + If the parent element of this text is not a folio report, return a default QString. +*/ QString DynamicElementTextItem::reportReplacedCompositeText() const { QString string; @@ -1199,10 +1199,10 @@ QString DynamicElementTextItem::reportReplacedCompositeText() const } /** - * @brief DynamicElementTextItem::zoomToLinkedElement - * If the parent element is a folio report or a slave element, - * and is linked, zoom to the linked element - */ + @brief DynamicElementTextItem::zoomToLinkedElement + If the parent element is a folio report or a slave element, + and is linked, zoom to the linked element +*/ void DynamicElementTextItem::zoomToLinkedElement() { if(!parentElement()) @@ -1245,9 +1245,9 @@ void DynamicElementTextItem::zoomToLinkedElement() } /** - * @brief DynamicElementTextItem::updateXref - * Create or delete the Xref according to the current properties of the project - */ + @brief DynamicElementTextItem::updateXref + Create or delete the Xref according to the current properties of the project +*/ void DynamicElementTextItem::updateXref() { if(diagram()) diff --git a/sources/qetgraphicsitem/dynamicelementtextitem.h b/sources/qetgraphicsitem/dynamicelementtextitem.h index 69e03a94b..a83eaeffe 100644 --- a/sources/qetgraphicsitem/dynamicelementtextitem.h +++ b/sources/qetgraphicsitem/dynamicelementtextitem.h @@ -30,11 +30,11 @@ class ElementTextItemGroup; class CrossRefItem; /** - * @brief The DynamicElementTextItem class - * This class provide a simple text field of element who can be added or removed directly from the diagram editor. - * This text is created to compensate a big lack of the ElementTextItem : ElementTextItem can't be added or removed directly in the diagram editor - * - */ + @brief The DynamicElementTextItem class + This class provide a simple text field of element who can be added or removed directly from the diagram editor. + This text is created to compensate a big lack of the ElementTextItem : ElementTextItem can't be added or removed directly in the diagram editor + +*/ class DynamicElementTextItem : public DiagramTextItem { friend class DynamicTextItemDelegate; diff --git a/sources/qetgraphicsitem/element.cpp b/sources/qetgraphicsitem/element.cpp index 4ec049821..a724e7646 100644 --- a/sources/qetgraphicsitem/element.cpp +++ b/sources/qetgraphicsitem/element.cpp @@ -70,11 +70,11 @@ class ElementXmlRetroCompatibility }; /** - * @brief Element::Element - * @param location, location of this element - * @param parent, parent graphics item - * @param state, state of the instanciation - */ + @brief Element::Element + @param location, location of this element + @param parent, parent graphics item + @param state, state of the instanciation +*/ Element::Element(const ElementsLocation &location, QGraphicsItem *parent, int *state, @@ -120,8 +120,8 @@ Element::Element(const ElementsLocation &location, } /** - * @brief Element::~Element - */ + @brief Element::~Element +*/ Element::~Element() { qDeleteAll (m_dynamic_text_list); @@ -129,19 +129,19 @@ Element::~Element() } /** - * @brief Element::terminals - * @return the list of terminals of this element. - */ + @brief Element::terminals + @return the list of terminals of this element. +*/ QList Element::terminals() const { return m_terminals; } /** - * @brief Element::conductors - * @return The list of conductors docked to this element - * the list is sorted according to the position of the terminal where the conductor is docked - * from top to bottom, and left to right. - */ + @brief Element::conductors + @return The list of conductors docked to this element + the list is sorted according to the position of the terminal where the conductor is docked + from top to bottom, and left to right. +*/ QList Element::conductors() const { QList conductors; @@ -179,10 +179,10 @@ void Element::setHighlighted(bool hl) { } /** - * @brief Element::displayHelpLine - * Display the help line of each terminal if b is true - * @param b - */ + @brief Element::displayHelpLine + Display the help line of each terminal if b is true + @param b +*/ void Element::displayHelpLine(bool b) { foreach (Terminal *t, terminals()) @@ -190,11 +190,11 @@ void Element::displayHelpLine(bool b) } /** - * @brief Element::paint - * @param painter - * @param options - * @param widget - */ + @brief Element::paint + @param painter + @param options + @param widget +*/ void Element::paint(QPainter *painter, const QStyleOptionGraphicsItem *options, QWidget *) @@ -224,13 +224,13 @@ QRectF Element::boundingRect() const { } /** - * @brief Element::setSize - * Define the size of the element. - * The size must be a multiple of 10. - * If not, the dimensions indicated will be arrrondies to higher tens. - * @param wid - * @param hei - */ + @brief Element::setSize + Define the size of the element. + The size must be a multiple of 10. + If not, the dimensions indicated will be arrrondies to higher tens. + @param wid + @param hei +*/ void Element::setSize(int wid, int hei) { prepareGeometryChange(); @@ -273,9 +273,9 @@ QPoint Element::hotspot() const { } /** - * @brief Element::pixmap - * @return the pixmap of this element - */ + @brief Element::pixmap + @return the pixmap of this element +*/ QPixmap Element::pixmap() { return ElementPictureFactory::instance()->pixmap(m_location); } @@ -306,7 +306,7 @@ void Element::drawAxes(QPainter *painter, Dessine le cadre de selection de l'element de maniere systematiquement non antialiasee. @param painter Le QPainter a utiliser pour dessiner les bornes. @param options Les options de style a prendre en compte - */ +*/ void Element::drawSelection(QPainter *painter, const QStyleOptionGraphicsItem *options) { Q_UNUSED(options); @@ -332,7 +332,7 @@ void Element::drawSelection(QPainter *painter, Dessine le cadre de selection de l'element de maniere systematiquement non antialiasee. @param painter Le QPainter a utiliser pour dessiner les bornes. @param options Les options de style a prendre en compte - */ +*/ void Element::drawHighlight(QPainter *painter, const QStyleOptionGraphicsItem *options) { Q_UNUSED(options); @@ -359,19 +359,19 @@ void Element::drawHighlight(QPainter *painter, } /** - * @brief Element::buildFromXml - * Build this element from an xml description - * @param xml_def_elmt - * @param state - * Optional pointer which define the status of build - * 0 - evreything all right - * 4 - xml isn't a "definition" - * 5 - attribute of the definition isn't present or valid - * 6 - the definition is empty - * 7 - parsing of a xml node who describe a graphical part failed. - * 8 - No part of the drawing could be loaded - * @return - */ + @brief Element::buildFromXml + Build this element from an xml description + @param xml_def_elmt + @param state + Optional pointer which define the status of build + 0 - evreything all right + 4 - xml isn't a "definition" + 5 - attribute of the definition isn't present or valid + 6 - the definition is empty + 7 - parsing of a xml node who describe a graphical part failed. + 8 - No part of the drawing could be loaded + @return +*/ bool Element::buildFromXml(const QDomElement &xml_def_elmt, int *state) { m_state = QET::GIBuildingFromXml; @@ -517,11 +517,11 @@ bool Element::buildFromXml(const QDomElement &xml_def_elmt, int *state) } /** - * @brief Element::parseElement - * Parse the element of the xml description of this element - * @param dom - * @return - */ + @brief Element::parseElement + Parse the element of the xml description of this element + @param dom + @return +*/ bool Element::parseElement(const QDomElement &dom) { if (dom.tagName() == "terminal") return(parseTerminal(dom)); @@ -531,13 +531,13 @@ bool Element::parseElement(const QDomElement &dom) } /** - * @brief Element::parseInput - * Parse the input (old text field) - * the parsed input are converted to dynamic text field, this function - * is only here to keep compatibility with old text. - * @param dom_element - * @return - */ + @brief Element::parseInput + Parse the input (old text field) + the parsed input are converted to dynamic text field, this function + is only here to keep compatibility with old text. + @param dom_element + @return +*/ bool Element::parseInput(const QDomElement &dom_element) { qreal pos_x, pos_y; @@ -588,11 +588,11 @@ bool Element::parseInput(const QDomElement &dom_element) } /** - * @brief Element::parseDynamicText - * Create the dynamic text field describ in @dom_element - * @param dom_element - * @return - */ + @brief Element::parseDynamicText + Create the dynamic text field describ in @dom_element + @param dom_element + @return +*/ DynamicElementTextItem *Element::parseDynamicText( const QDomElement &dom_element) { @@ -610,11 +610,11 @@ DynamicElementTextItem *Element::parseDynamicText( } /*! - * \brief Element::parseTerminal - * Parse partTerminal from xml structure - * \param dom_element - * \return - */ + \brief Element::parseTerminal + Parse partTerminal from xml structure + \param dom_element + \return +*/ Terminal *Element::parseTerminal(const QDomElement &dom_element) { @@ -668,18 +668,18 @@ bool Element::valideXml(QDomElement &e) { } /** - * @brief Element::fromXml - * Import the parameters of this element from a xml document. - * When call this function ensure this element is already in a scene, because - * the dynamic text item and element text item group (in the xml file) are created in this function - * and need a diagram for create their Xref, when this element is linked to another. - * If not the Xref can be not displayed, until the next call of update Xref of the group or text item. - * @param e : the dom element where the parameter is stored - * @param table_id_adr : Reference to the mapping table between IDs of the XML file - * and the addresses in memory. If the import succeeds, it must be add the right couples (id, address). - * @param handle_inputs_rotation : apply the rotation of this element to his child text - * @return - */ + @brief Element::fromXml + Import the parameters of this element from a xml document. + When call this function ensure this element is already in a scene, because + the dynamic text item and element text item group (in the xml file) are created in this function + and need a diagram for create their Xref, when this element is linked to another. + If not the Xref can be not displayed, until the next call of update Xref of the group or text item. + @param e : the dom element where the parameter is stored + @param table_id_adr : Reference to the mapping table between IDs of the XML file + and the addresses in memory. If the import succeeds, it must be add the right couples (id, address). + @param handle_inputs_rotation : apply the rotation of this element to his child text + @return +*/ bool Element::fromXml(QDomElement &e, QHash &table_id_adr, @@ -1245,11 +1245,11 @@ QDomElement Element::toXml(QDomDocument &document, } /** - * @brief Element::addDynamiqueTextItem - * Add @deti as a dynamic text item of this element, @deti is reparented to this - * If @deti is null, a new DynamicElementTextItem is created and added to this element. - * @param deti - */ + @brief Element::addDynamiqueTextItem + Add @deti as a dynamic text item of this element, @deti is reparented to this + If @deti is null, a new DynamicElementTextItem is created and added to this element. + @param deti +*/ void Element::addDynamicTextItem(DynamicElementTextItem *deti) { if (deti && !m_dynamic_text_list.contains(deti)) @@ -1267,11 +1267,11 @@ void Element::addDynamicTextItem(DynamicElementTextItem *deti) } /** - * @brief Element::removeDynamicTextItem - * Remove @deti, no matter if is a child of this element or a child of a group of this element. - * Set he parent item of @deti to 0, @deti is not deleted. - * @param deti - */ + @brief Element::removeDynamicTextItem + Remove @deti, no matter if is a child of this element or a child of a group of this element. + Set he parent item of @deti to 0, @deti is not deleted. + @param deti +*/ void Element::removeDynamicTextItem(DynamicElementTextItem *deti) { if (m_dynamic_text_list.contains(deti)) @@ -1296,23 +1296,23 @@ void Element::removeDynamicTextItem(DynamicElementTextItem *deti) } /** - * @brief Element::dynamicTextItems - * @return all dynamic text items of this element directly child of this element. - * Texts in text-groups belonging to this element are not returned by this function. - * @see ElementTextItemGroup::texts - */ + @brief Element::dynamicTextItems + @return all dynamic text items of this element directly child of this element. + Texts in text-groups belonging to this element are not returned by this function. + @see ElementTextItemGroup::texts +*/ QList Element::dynamicTextItems() const { return m_dynamic_text_list; } /** - * @brief Element::addTextGroup - * Create and add an element text item group to this element. - * If this element already have a group with the same name, - * then @name will renamed to name1 or name2 etc.... - * @param name : the name of the group - * @return the created group. - */ + @brief Element::addTextGroup + Create and add an element text item group to this element. + If this element already have a group with the same name, + then @name will renamed to name1 or name2 etc.... + @param name : the name of the group + @return the created group. +*/ ElementTextItemGroup *Element::addTextGroup(const QString &name) { if(m_texts_group.isEmpty()) @@ -1341,10 +1341,10 @@ ElementTextItemGroup *Element::addTextGroup(const QString &name) } /** - * @brief Element::addTextGroup - * @param group add group @group to the group of this element. - * the group must not be owned by an element. - */ + @brief Element::addTextGroup + @param group add group @group to the group of this element. + the group must not be owned by an element. +*/ void Element::addTextGroup(ElementTextItemGroup *group) { if(group->parentElement()) @@ -1356,12 +1356,12 @@ void Element::addTextGroup(ElementTextItemGroup *group) } /** - * @brief Element::removeTextGroup - * Remove the text group @group from this element, and set the parent of group to 0. - * group is not deleted. - * All texts owned by the group will be reparented to this element - * @param name - */ + @brief Element::removeTextGroup + Remove the text group @group from this element, and set the parent of group to 0. + group is not deleted. + All texts owned by the group will be reparented to this element + @param name +*/ void Element::removeTextGroup(ElementTextItemGroup *group) { if(!m_texts_group.contains(group)) @@ -1386,11 +1386,11 @@ void Element::removeTextGroup(ElementTextItemGroup *group) } /** - * @brief Element::textGroup - * @param name - * @return the text group named @name or nullptr if this element - * haven't got a group with this name - */ + @brief Element::textGroup + @param name + @return the text group named @name or nullptr if this element + haven't got a group with this name +*/ ElementTextItemGroup *Element::textGroup(const QString &name) const { for (ElementTextItemGroup *group : m_texts_group) @@ -1401,21 +1401,21 @@ ElementTextItemGroup *Element::textGroup(const QString &name) const } /** - * @brief Element::textGroups - * @return All texts groups of this element - */ + @brief Element::textGroups + @return All texts groups of this element +*/ QList Element::textGroups() const { return m_texts_group; } /** - * @brief Element::addTextToGroup - * Add the text @text to the group @group; - * If @group isn't owned by this element return false. - * The text must be a text of this element. - * @return : true if the text was succesfully added to the group. - */ + @brief Element::addTextToGroup + Add the text @text to the group @group; + If @group isn't owned by this element return false. + The text must be a text of this element. + @return : true if the text was succesfully added to the group. +*/ bool Element::addTextToGroup(DynamicElementTextItem *text, ElementTextItemGroup *group) { @@ -1434,10 +1434,10 @@ bool Element::addTextToGroup(DynamicElementTextItem *text, } /** - * @brief Element::removeTextFromGroup - * Remove the text @text from the group @group, en reparent @text to this element - * @return true if text was succesfully removed - */ + @brief Element::removeTextFromGroup + Remove the text @text from the group @group, en reparent @text to this element + @return true if text was succesfully removed +*/ bool Element::removeTextFromGroup(DynamicElementTextItem *text, ElementTextItemGroup *group) { @@ -1456,13 +1456,13 @@ bool Element::removeTextFromGroup(DynamicElementTextItem *text, } /** - * @brief Element::AlignedFreeTerminals - * @return a list of terminal (owned by this element) aligned to other terminal (from other element) - * The first Terminal of QPair is a Terminal owned by this element, - * this terminal haven't got any conductor docked. - * The second Terminal of QPair is a Terminal owned by an other element, - * which is aligned with the first Terminal. The second Terminal can have or not docked conductors. - */ + @brief Element::AlignedFreeTerminals + @return a list of terminal (owned by this element) aligned to other terminal (from other element) + The first Terminal of QPair is a Terminal owned by this element, + this terminal haven't got any conductor docked. + The second Terminal of QPair is a Terminal owned by an other element, + which is aligned with the first Terminal. The second Terminal can have or not docked conductors. +*/ QList > Element::AlignedFreeTerminals() const { QList > list; @@ -1482,14 +1482,14 @@ QList > Element::AlignedFreeTerminals() const } /** - * @brief Element::initLink - * Initialise the link between this element and other elements. - * This method can be call once because init the link according to - * uuid store in a private list, after link, the list is clear, so - * call another time do nothing. + @brief Element::initLink + Initialise the link between this element and other elements. + This method can be call once because init the link according to + uuid store in a private list, after link, the list is clear, so + call another time do nothing. * - * @param prj, ownership project of this element and other element to be linked - */ + @param prj, ownership project of this element and other element to be linked +*/ void Element::initLink(QETProject *prj) { // if nothing to link return now @@ -1524,11 +1524,11 @@ QString Element::linkTypeToString() const } /** - * @brief Element::setElementInformations - * Set new information for this element. - * If new information is different of current infotmation emit @elementInfoChange - * @param dc - */ + @brief Element::setElementInformations + Set new information for this element. + If new information is different of current infotmation emit @elementInfoChange + @param dc +*/ void Element::setElementInformations(DiagramContext dc) { if (m_element_informations == dc) { @@ -1542,12 +1542,12 @@ void Element::setElementInformations(DiagramContext dc) } /** - * @brief comparPos - * Compare position of the two elements. Compare 3 points: - * 1 folio - 2 row - 3 line - * returns a response when a comparison is found. - * @return true if elmt1 is at lower position than elmt 2, else false - */ + @brief comparPos + Compare position of the two elements. Compare 3 points: + 1 folio - 2 row - 3 line + returns a response when a comparison is found. + @return true if elmt1 is at lower position than elmt 2, else false +*/ bool comparPos(const Element *elmt1, const Element *elmt2) { //Compare folio first if (elmt1->diagram()->folioIndex() != elmt2->diagram()->folioIndex()) @@ -1570,9 +1570,9 @@ bool comparPos(const Element *elmt1, const Element *elmt2) { } /** - * @brief Element::mouseMoveEvent - * @param event - */ + @brief Element::mouseMoveEvent + @param event +*/ void Element::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { QetGraphicsItem::mouseMoveEvent(event); @@ -1583,9 +1583,9 @@ void Element::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief Element::mouseReleaseEvent - * @param event - */ + @brief Element::mouseReleaseEvent + @param event +*/ void Element::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { QetGraphicsItem::mouseReleaseEvent(event); @@ -1596,10 +1596,10 @@ void Element::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) } /** - * When mouse over element - * change m_mouse_over to true (used in paint() function ) - * Also highlight linked elements - * @param e QGraphicsSceneHoverEvent + When mouse over element + change m_mouse_over to true (used in paint() function ) + Also highlight linked elements + @param e QGraphicsSceneHoverEvent */ void Element::hoverEnterEvent(QGraphicsSceneHoverEvent *e) { Q_UNUSED(e) @@ -1613,10 +1613,10 @@ void Element::hoverEnterEvent(QGraphicsSceneHoverEvent *e) { } /** - * When mouse over element leave the position - * change m_mouse_over to false(used in paint() function ) - * Also un-highlight linked elements - * @param e QGraphicsSceneHoverEvent + When mouse over element leave the position + change m_mouse_over to false(used in paint() function ) + Also un-highlight linked elements + @param e QGraphicsSceneHoverEvent */ void Element::hoverLeaveEvent(QGraphicsSceneHoverEvent *e) { Q_UNUSED(e) @@ -1629,11 +1629,11 @@ void Element::hoverLeaveEvent(QGraphicsSceneHoverEvent *e) { } /** - * @brief Element::setUpFormula - * Set up the formula used to create the label of this element - * @param : if true set tagged text to code letter (ex K for coil) with condition : - * formula is empty, text tagged "label" is emptty or "_"; - */ + @brief Element::setUpFormula + Set up the formula used to create the label of this element + @param : if true set tagged text to code letter (ex K for coil) with condition : + formula is empty, text tagged "label" is emptty or "_"; +*/ void Element::setUpFormula(bool code_letter) { Q_UNUSED(code_letter) @@ -1676,34 +1676,34 @@ void Element::setUpFormula(bool code_letter) } /** - * @brief Element::getPrefix - * get Element Prefix - */ + @brief Element::getPrefix + get Element Prefix +*/ QString Element::getPrefix() const{ return m_prefix; } /** - * @brief Element::setPrefix - * set Element Prefix - */ + @brief Element::setPrefix + set Element Prefix +*/ void Element::setPrefix(QString prefix) { m_prefix = std::move(prefix); } /** - * @brief Element::freezeLabel - * Freeze this element label - */ + @brief Element::freezeLabel + Freeze this element label +*/ void Element::freezeLabel(bool freeze) { m_freeze_label = freeze; } /** - * @brief Element::freezeNewAddedElement - * Freeze this label if needed - */ + @brief Element::freezeNewAddedElement + Freeze this label if needed +*/ void Element::freezeNewAddedElement() { if (this->diagram()->freezeNewElements() || this->diagram()->project()->isFreezeNewElements()) { @@ -1713,11 +1713,11 @@ void Element::freezeNewAddedElement() { } /** - * @brief Element::actualLabel - * Always return the current label to be displayed. - * This function is usefull when label is based on formula, because label can change at any time. - * @return - */ + @brief Element::actualLabel + Always return the current label to be displayed. + This function is usefull when label is based on formula, because label can change at any time. + @return +*/ QString Element::actualLabel() { if (m_element_informations.value("formula").toString().isEmpty()) { @@ -1733,9 +1733,9 @@ QString Element::actualLabel() } /** - * @brief Element::name - * @return the human name of this element - */ + @brief Element::name + @return the human name of this element +*/ QString Element::name() const { return m_names.name(m_location.baseName()); } diff --git a/sources/qetgraphicsitem/element.h b/sources/qetgraphicsitem/element.h index ee4c68bfa..7a3448a74 100644 --- a/sources/qetgraphicsitem/element.h +++ b/sources/qetgraphicsitem/element.h @@ -46,7 +46,7 @@ class Element : public QetGraphicsItem /** * @brief The kind enum * Used to know the kind of this element (master, slave, report ect...) - */ + */ enum kind {Simple = 1, NextReport = 2, PreviousReport = 4, @@ -68,7 +68,7 @@ class Element : public QetGraphicsItem /** * Enable the use of qgraphicsitem_cast to safely cast a QGraphicsItem into an Element. * @return the QGraphicsItem type - */ + */ enum { Type = UserType + 1000 }; int type() const override { return Type; } @@ -243,7 +243,7 @@ inline int Element::orientation() const { /** * @brief Element::uuid * @return the uuid of this element - */ +*/ inline QUuid Element::uuid() const { return m_uuid; } @@ -251,7 +251,7 @@ inline QUuid Element::uuid() const { /** * @brief Element::linkedElements * @return the list of linked elements, the list is sorted by position - */ +*/ inline QList Element::linkedElements() { std::sort(connected_elements.begin(), connected_elements.end(), diff --git a/sources/qetgraphicsitem/elementtextitemgroup.cpp b/sources/qetgraphicsitem/elementtextitemgroup.cpp index cb2207ed4..fb4d15201 100644 --- a/sources/qetgraphicsitem/elementtextitemgroup.cpp +++ b/sources/qetgraphicsitem/elementtextitemgroup.cpp @@ -36,9 +36,9 @@ bool sorting(QGraphicsItem *qgia, QGraphicsItem *qgib) } /** - * @brief ElementTextItemGroup::ElementTextItemGroup - * @param parent - */ + @brief ElementTextItemGroup::ElementTextItemGroup + @param parent +*/ ElementTextItemGroup::ElementTextItemGroup(const QString &name, Element *parent) : QGraphicsItemGroup(parent), m_name(name), @@ -52,9 +52,9 @@ ElementTextItemGroup::~ElementTextItemGroup() {} /** - * @brief ElementTextItemGroup::addToGroup - * @param item - */ + @brief ElementTextItemGroup::addToGroup + @param item +*/ void ElementTextItemGroup::addToGroup(QGraphicsItem *item) { if(item->type() == DynamicElementTextItem::Type) @@ -83,9 +83,9 @@ void ElementTextItemGroup::addToGroup(QGraphicsItem *item) } /** - * @brief ElementTextItemGroup::removeFromGroup - * @param item - */ + @brief ElementTextItemGroup::removeFromGroup + @param item +*/ void ElementTextItemGroup::removeFromGroup(QGraphicsItem *item) { QGraphicsItemGroup::removeFromGroup(item); @@ -114,21 +114,21 @@ void ElementTextItemGroup::removeFromGroup(QGraphicsItem *item) } /** - * @brief ElementTextItemGroup::blockAlignmentUpdate - * If true, the texts in this group are never aligned, moved, rotated etc... - * the texts stay as it was, until blockAlignmentUpdate is set to false. - * @param block - */ + @brief ElementTextItemGroup::blockAlignmentUpdate + If true, the texts in this group are never aligned, moved, rotated etc... + the texts stay as it was, until blockAlignmentUpdate is set to false. + @param block +*/ void ElementTextItemGroup::blockAlignmentUpdate(bool block) { m_block_alignment_update = block; } /** - * @brief ElementTextItemGroup::setAlignement - * Set the alignement of this group - * @param alignement - */ + @brief ElementTextItemGroup::setAlignement + Set the alignement of this group + @param alignement +*/ void ElementTextItemGroup::setAlignment(Qt::Alignment alignement) { m_alignment = alignement; @@ -142,11 +142,11 @@ Qt::Alignment ElementTextItemGroup::alignment() const } /** - * @brief ElementTextItemGroup::setAlignment - * Update the alignement of the items in this group, according - * to the current alignement. - * @param alignement - */ + @brief ElementTextItemGroup::setAlignment + Update the alignement of the items in this group, according + to the current alignement. + @param alignement +*/ void ElementTextItemGroup::updateAlignment() { if(m_block_alignment_update) @@ -235,11 +235,11 @@ void ElementTextItemGroup::updateAlignment() } /** - * @brief ElementTextItemGroup::setVerticalAdjustment - * Set the value of the vertical adjustment to @v. - * The vertical adjutment is use to adjust the space between the texts of this group. - * @param v - */ + @brief ElementTextItemGroup::setVerticalAdjustment + Set the value of the vertical adjustment to @v. + The vertical adjutment is use to adjust the space between the texts of this group. + @param v +*/ void ElementTextItemGroup::setVerticalAdjustment(int v) { prepareGeometryChange(); @@ -249,9 +249,9 @@ void ElementTextItemGroup::setVerticalAdjustment(int v) } /** - * @brief ElementTextItemGroup::setName - * @param name Set the name of this group - */ + @brief ElementTextItemGroup::setName + @param name Set the name of this group +*/ void ElementTextItemGroup::setName(QString name) { m_name = std::move(name); @@ -311,9 +311,9 @@ bool ElementTextItemGroup::frame() const { } /** - * @brief ElementTextItemGroup::texts - * @return Every texts in this group - */ + @brief ElementTextItemGroup::texts + @return Every texts in this group +*/ QList ElementTextItemGroup::texts() const { QList list; @@ -326,9 +326,9 @@ QList ElementTextItemGroup::texts() const } /** - * @brief ElementTextItemGroup::diagram - * @return The diagram of this group, or nullptr if this group is not in a diagram - */ + @brief ElementTextItemGroup::diagram + @return The diagram of this group, or nullptr if this group is not in a diagram +*/ Diagram *ElementTextItemGroup::diagram() const { if(scene()) @@ -338,9 +338,9 @@ Diagram *ElementTextItemGroup::diagram() const } /** - * @brief ElementTextItemGroup::parentElement - * @return The parent element of this group or nullptr - */ + @brief ElementTextItemGroup::parentElement + @return The parent element of this group or nullptr +*/ Element *ElementTextItemGroup::parentElement() const { if(parentItem() && parentItem()->type() == Element::Type) @@ -350,11 +350,11 @@ Element *ElementTextItemGroup::parentElement() const } /** - * @brief ElementTextItemGroup::toXml - * Export data of this group to xml - * @param dom_document - * @return - */ + @brief ElementTextItemGroup::toXml + Export data of this group to xml + @param dom_document + @return +*/ QDomElement ElementTextItemGroup::toXml(QDomDocument &dom_document) const { QDomElement dom_element = dom_document.createElement(this->xmlTaggName()); @@ -385,10 +385,10 @@ QDomElement ElementTextItemGroup::toXml(QDomDocument &dom_document) const } /** - * @brief ElementTextItemGroup::fromXml - * Import data of this group from xml - * @param dom_element - */ + @brief ElementTextItemGroup::fromXml + Import data of this group from xml + @param dom_element +*/ void ElementTextItemGroup::fromXml(QDomElement &dom_element) { if (dom_element.tagName() != xmlTaggName()) { @@ -430,11 +430,11 @@ void ElementTextItemGroup::fromXml(QDomElement &dom_element) } /** - * @brief ElementTextItemGroup::paint - * @param painter - * @param option - * @param widget - */ + @brief ElementTextItemGroup::paint + @param painter + @param option + @param widget +*/ void ElementTextItemGroup::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { Q_UNUSED(option); @@ -484,9 +484,9 @@ void ElementTextItemGroup::paint(QPainter *painter, const QStyleOptionGraphicsIt } /** - * @brief ElementTextItemGroup::boundingRect - * @return - */ + @brief ElementTextItemGroup::boundingRect + @return +*/ QRectF ElementTextItemGroup::boundingRect() const { //If we refer to the Qt doc, the bounding rect of a QGraphicsItemGroup, @@ -530,9 +530,9 @@ void ElementTextItemGroup::setPos(qreal x, qreal y) } /** - * @brief ElementTextItemGroup::mousePressEvent - * @param event - */ + @brief ElementTextItemGroup::mousePressEvent + @param event +*/ void ElementTextItemGroup::mousePressEvent(QGraphicsSceneMouseEvent *event) { if(event->button() == Qt::LeftButton) @@ -546,9 +546,9 @@ void ElementTextItemGroup::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ElementTextItemGroup::mouseMoveEvent - * @param event - */ + @brief ElementTextItemGroup::mouseMoveEvent + @param event +*/ void ElementTextItemGroup::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if((event->buttons() & Qt::LeftButton) && (flags() & ItemIsMovable)) @@ -582,9 +582,9 @@ void ElementTextItemGroup::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief ElementTextItemGroup::mouseReleaseEvent - * @param event - */ + @brief ElementTextItemGroup::mouseReleaseEvent + @param event +*/ void ElementTextItemGroup::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if(diagram()) @@ -631,9 +631,9 @@ void ElementTextItemGroup::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event } /** - * @brief ElementTextItemGroup::keyPressEvent - * @param event - */ + @brief ElementTextItemGroup::keyPressEvent + @param event +*/ void ElementTextItemGroup::keyPressEvent(QKeyEvent *event) { if(event->modifiers() == Qt::ControlModifier) diff --git a/sources/qetgraphicsitem/elementtextitemgroup.h b/sources/qetgraphicsitem/elementtextitemgroup.h index 9623abb31..09dbc9d73 100644 --- a/sources/qetgraphicsitem/elementtextitemgroup.h +++ b/sources/qetgraphicsitem/elementtextitemgroup.h @@ -28,10 +28,10 @@ class Diagram; class CrossRefItem; /** - * @brief The ElementTextItemGroup class - * This class represent a group of element text - * Texts in the group can be aligned left / center /right - */ + @brief The ElementTextItemGroup class + This class represent a group of element text + Texts in the group can be aligned left / center /right +*/ class ElementTextItemGroup : public QObject, public QGraphicsItemGroup { Q_OBJECT diff --git a/sources/qetgraphicsitem/masterelement.cpp b/sources/qetgraphicsitem/masterelement.cpp index 331728eef..302d092ae 100644 --- a/sources/qetgraphicsitem/masterelement.cpp +++ b/sources/qetgraphicsitem/masterelement.cpp @@ -22,31 +22,31 @@ #include /** - * @brief MasterElement::MasterElement - * Default constructor - * @param location location of xml definition - * @param qgi parent QGraphicItem - * @param s parent diagram - * @param state int used to know if the creation of element have error - */ + @brief MasterElement::MasterElement + Default constructor + @param location location of xml definition + @param qgi parent QGraphicItem + @param s parent diagram + @param state int used to know if the creation of element have error +*/ MasterElement::MasterElement(const ElementsLocation &location, QGraphicsItem *qgi, int *state) : Element(location, qgi, state, Element::Master) {} /** - * @brief MasterElement::~MasterElement - * default destructor - */ + @brief MasterElement::~MasterElement + default destructor +*/ MasterElement::~MasterElement() { unlinkAllElements(); } /** - * @brief MasterElement::linkToElement - * Link this master to another element - * For this class element must be a slave - * @param elmt - */ + @brief MasterElement::linkToElement + Link this master to another element + For this class element must be a slave + @param elmt +*/ void MasterElement::linkToElement(Element *elmt) { // check if element is slave and if isn't already linked @@ -65,9 +65,9 @@ void MasterElement::linkToElement(Element *elmt) } /** - * @brief MasterElement::unlinkAllElements - * Unlink all of the element in the QList connected_elements - */ + @brief MasterElement::unlinkAllElements + Unlink all of the element in the QList connected_elements +*/ void MasterElement::unlinkAllElements() { // if this element is free no need to do something @@ -80,10 +80,10 @@ void MasterElement::unlinkAllElements() } /** - * @brief MasterElement::unlinkElement - * Unlink the given elmt in parametre - * @param elmt element to unlink from this - */ + @brief MasterElement::unlinkElement + Unlink the given elmt in parametre + @param elmt element to unlink from this +*/ void MasterElement::unlinkElement(Element *elmt) { //Ensure elmt is linked to this element @@ -99,21 +99,21 @@ void MasterElement::unlinkElement(Element *elmt) } /** - * @brief MasterElement::initLink - * @param project - * Call init Link from custom element and after - * call update label for setup it. - */ + @brief MasterElement::initLink + @param project + Call init Link from custom element and after + call update label for setup it. +*/ void MasterElement::initLink(QETProject *project) { //Create the link with other element if needed Element::initLink(project); } /** - * @brief MasterElement::XrefBoundingRect - * @return The bounding rect of the Xref, if this element - * haven't got a xref, return a default QRectF - */ + @brief MasterElement::XrefBoundingRect + @return The bounding rect of the Xref, if this element + haven't got a xref, return a default QRectF +*/ QRectF MasterElement::XrefBoundingRect() const { if(m_Xref_item) @@ -149,15 +149,15 @@ void MasterElement::xrefPropertiesChanged() } /** - * @brief MasterElement::aboutDeleteXref - * Check if Xref item must be displayed, if not, delete it. - * If Xref item is deleted or already not used (nullptr) return true; - * Else return false if Xref item is used - * NOTICE : Xref can display nothing but not be deleted so far. - * For exemple, if Xref is display has cross, only power contact are linked and - * option show power contact is disable, the cross isn't draw. - * @return - */ + @brief MasterElement::aboutDeleteXref + Check if Xref item must be displayed, if not, delete it. + If Xref item is deleted or already not used (nullptr) return true; + Else return false if Xref item is used + NOTICE : Xref can display nothing but not be deleted so far. + For exemple, if Xref is display has cross, only power contact are linked and + option show power contact is disable, the cross isn't draw. + @return +*/ void MasterElement::aboutDeleteXref() { if(!m_Xref_item) diff --git a/sources/qetgraphicsitem/masterelement.h b/sources/qetgraphicsitem/masterelement.h index fdd5ee28c..451ed1f43 100644 --- a/sources/qetgraphicsitem/masterelement.h +++ b/sources/qetgraphicsitem/masterelement.h @@ -23,11 +23,11 @@ class CrossRefItem; /** - * @brief The MasterElement class - * This class is a custom element, with extended behavior - * to be a master element. Master element can be linked with slave element - * and display a cross ref item for know with what other element he is linked - */ + @brief The MasterElement class + This class is a custom element, with extended behavior + to be a master element. Master element can be linked with slave element + and display a cross ref item for know with what other element he is linked +*/ class MasterElement : public Element { Q_OBJECT diff --git a/sources/qetgraphicsitem/qetgraphicsitem.cpp b/sources/qetgraphicsitem/qetgraphicsitem.cpp index 51e6736d8..2768d0c84 100644 --- a/sources/qetgraphicsitem/qetgraphicsitem.cpp +++ b/sources/qetgraphicsitem/qetgraphicsitem.cpp @@ -19,11 +19,11 @@ #include "diagram.h" /** - * @brief QetGraphicsItem::QetGraphicsItem Default constructor - * @param uuid, uuid of the item - * @param diagram, diagram aka QGraphicsScene of the item - * @param parent, Parent Item - */ + @brief QetGraphicsItem::QetGraphicsItem Default constructor + @param uuid, uuid of the item + @param diagram, diagram aka QGraphicsScene of the item + @param parent, Parent Item +*/ QetGraphicsItem::QetGraphicsItem(QGraphicsItem *parent): QGraphicsObject(parent), is_movable_(true), @@ -35,18 +35,18 @@ QetGraphicsItem::~QetGraphicsItem() {} /** - * @brief QetGraphicsItem::diagram + @brief QetGraphicsItem::diagram *return the diagram of this item - */ +*/ Diagram* QetGraphicsItem::diagram() const{ return(qobject_cast(scene())); } /** - * @brief QetGraphicsItem::setPos + @brief QetGraphicsItem::setPos *set the position of the item to p - * @param p the new position of item - */ + @param p the new position of item +*/ void QetGraphicsItem::setPos(const QPointF &p) { QPointF pp = Diagram::snapToGrid(p); if (pp == pos() || !is_movable_) @@ -55,28 +55,28 @@ void QetGraphicsItem::setPos(const QPointF &p) { } /** - * @brief QetGraphicsItem::setPos + @brief QetGraphicsItem::setPos *set the position of the item - * @param x new abscisse of item - * @param y new ordonne of item - */ + @param x new abscisse of item + @param y new ordonne of item +*/ void QetGraphicsItem::setPos(qreal x, qreal y) { setPos(QPointF(x, y)); } /** - * @brief QetGraphicsItem::state - * @return the current state of this item - */ + @brief QetGraphicsItem::state + @return the current state of this item +*/ QET::GraphicsItemState QetGraphicsItem::state() const { return m_state; } /** - * @brief QetGraphicsItem::mousePressEvent + @brief QetGraphicsItem::mousePressEvent *handle the mouse click - * @param event - */ + @param event +*/ void QetGraphicsItem::mousePressEvent(QGraphicsSceneMouseEvent *event) { if (event->button() == Qt::LeftButton) @@ -91,10 +91,10 @@ void QetGraphicsItem::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief QetGraphicsItem::mouseDoubleClickEvent + @brief QetGraphicsItem::mouseDoubleClickEvent *handle the mouse double click - * @param event - */ + @param event +*/ void QetGraphicsItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { editProperty(); @@ -102,10 +102,10 @@ void QetGraphicsItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief QetGraphicsItem::mouseMoveEvent + @brief QetGraphicsItem::mouseMoveEvent *handle mouse movement - * @param event - */ + @param event +*/ void QetGraphicsItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if (isSelected() && event->buttons() & Qt::LeftButton) @@ -143,10 +143,10 @@ void QetGraphicsItem::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief QetGraphicsItem::mouseReleaseEvent + @brief QetGraphicsItem::mouseReleaseEvent *handle mouse release click - * @param e - */ + @param e +*/ void QetGraphicsItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (diagram()) { diff --git a/sources/qetgraphicsitem/qetshapeitem.cpp b/sources/qetgraphicsitem/qetshapeitem.cpp index 20208a32c..a00203906 100644 --- a/sources/qetgraphicsitem/qetshapeitem.cpp +++ b/sources/qetgraphicsitem/qetshapeitem.cpp @@ -28,13 +28,13 @@ #include "qeticons.h" /** - * @brief QetShapeItem::QetShapeItem - * Constructor of shape item. point 1 and 2 must be in scene coordinate - * @param p1 first point - * @param p2 second point - * @param type type of item (line, rectangle, ellipse) - * @param parent parent item - */ + @brief QetShapeItem::QetShapeItem + Constructor of shape item. point 1 and 2 must be in scene coordinate + @param p1 first point + @param p2 second point + @param type type of item (line, rectangle, ellipse) + @param parent parent item +*/ QetShapeItem::QetShapeItem(QPointF p1, QPointF p2, ShapeType type, QGraphicsItem *parent) : QetGraphicsItem(parent), m_shapeType(type), @@ -69,10 +69,10 @@ QetShapeItem::~QetShapeItem() } /** - * @brief QetShapeItem::setPen - * Set the pen to use for draw the shape - * @param pen - */ + @brief QetShapeItem::setPen + Set the pen to use for draw the shape + @param pen +*/ void QetShapeItem::setPen(const QPen &pen) { if (m_pen == pen) return; @@ -82,10 +82,10 @@ void QetShapeItem::setPen(const QPen &pen) } /** - * @brief QetShapeItem::setBrush - * Set the brush to use for the fill the shape - * @param brush - */ + @brief QetShapeItem::setBrush + Set the brush to use for the fill the shape + @param brush +*/ void QetShapeItem::setBrush(const QBrush &brush) { if (m_brush == brush) return; @@ -95,12 +95,12 @@ void QetShapeItem::setBrush(const QBrush &brush) } /** - * @brief QetShapeItem::setP2 - * Set the second point of this item. - * If this item is a polyline, - * the last point of the polyline is replaced by P2. - * @param P2 - */ + @brief QetShapeItem::setP2 + Set the second point of this item. + If this item is a polyline, + the last point of the polyline is replaced by P2. + @param P2 +*/ void QetShapeItem::setP2(const QPointF &P2) { if (m_shapeType == Polygon && m_polygon.last() != P2) @@ -116,11 +116,11 @@ void QetShapeItem::setP2(const QPointF &P2) } /** - * @brief QetShapeItem::setLine - * Set item geometry to line (only available for line shape) - * @param line - * @return : true when shape is a Line, else false - */ + @brief QetShapeItem::setLine + Set item geometry to line (only available for line shape) + @param line + @return : true when shape is a Line, else false +*/ bool QetShapeItem::setLine(const QLineF &line) { if (Q_UNLIKELY(m_shapeType != Line)) return false; @@ -132,11 +132,11 @@ bool QetShapeItem::setLine(const QLineF &line) } /** - * @brief QetShapeItem::setRect - * Set this item geometry to rect (only available if shape is a rectangle or an ellipse) - * @param rect : new rect - * @return : true when shape is rectangle or ellipse, else false - */ + @brief QetShapeItem::setRect + Set this item geometry to rect (only available if shape is a rectangle or an ellipse) + @param rect : new rect + @return : true when shape is rectangle or ellipse, else false +*/ bool QetShapeItem::setRect(const QRectF &rect) { if (Q_LIKELY(m_shapeType == Rectangle || m_shapeType == Ellipse)) @@ -152,11 +152,11 @@ bool QetShapeItem::setRect(const QRectF &rect) } /** - * @brief QetShapeItem::setPolygon - * Set this item geometry to polygon (only available if shape is a polyline) - * @param polygon : new polygon - * @return true if item is polygon, else false - */ + @brief QetShapeItem::setPolygon + Set this item geometry to polygon (only available if shape is a polyline) + @param polygon : new polygon + @return true if item is polygon, else false +*/ bool QetShapeItem::setPolygon(const QPolygonF &polygon) { if (Q_UNLIKELY(m_shapeType != Polygon)) { @@ -169,10 +169,10 @@ bool QetShapeItem::setPolygon(const QPolygonF &polygon) } /** - * @brief QetShapeItem::setClosed - * Close this item, have effect only if this item is a polygon. - * @param close - */ + @brief QetShapeItem::setClosed + Close this item, have effect only if this item is a polygon. + @param close +*/ void QetShapeItem::setClosed(bool close) { if (m_shapeType == Polygon && close != m_closed) @@ -200,18 +200,18 @@ void QetShapeItem::setYRadius(qreal Y) } /** - * @brief QetShapeItem::pointCount - * @return the number of point in the polygon - */ + @brief QetShapeItem::pointCount + @return the number of point in the polygon +*/ int QetShapeItem::pointsCount() const { return m_polygon.size(); } /** - * @brief QetShapeItem::setNextPoint - * Add a new point to the curent polygon - * @param P the new point. - */ + @brief QetShapeItem::setNextPoint + Add a new point to the curent polygon + @param P the new point. +*/ void QetShapeItem::setNextPoint(QPointF P) { prepareGeometryChange(); @@ -219,11 +219,11 @@ void QetShapeItem::setNextPoint(QPointF P) } /** - * @brief QetShapeItem::removePoints - * Number of point to remove on the polygon - * If @number is superior to number of polygon points-2, - * all points of polygon will be removed except the first two (minimum point for the polygon); - */ + @brief QetShapeItem::removePoints + Number of point to remove on the polygon + If @number is superior to number of polygon points-2, + all points of polygon will be removed except the first two (minimum point for the polygon); +*/ void QetShapeItem::removePoints(int number) { if (pointsCount() == 2 || number < 1) return; @@ -242,17 +242,17 @@ void QetShapeItem::removePoints(int number) } /** - * @brief QetShapeItem::boundingRect - * @return the bounding rect of this item - */ + @brief QetShapeItem::boundingRect + @return the bounding rect of this item +*/ QRectF QetShapeItem::boundingRect() const { return shape().boundingRect().adjusted(-6, -6, 6, 6); } /** - * @brief QetShapeItem::shape - * @return the shape of this item - */ + @brief QetShapeItem::shape + @return the shape of this item +*/ QPainterPath QetShapeItem::shape() const { QPainterPath path; @@ -286,12 +286,12 @@ QPainterPath QetShapeItem::shape() const } /** - * @brief QetShapeItem::paint - * Paint this item - * @param painter - * @param option - * @param widget - */ + @brief QetShapeItem::paint + Paint this item + @param painter + @param option + @param widget +*/ void QetShapeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { Q_UNUSED(option) @@ -326,10 +326,10 @@ void QetShapeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *opti } /** - * @brief QetShapeItem::hoverEnterEvent - * Handle hover enter event - * @param event - */ + @brief QetShapeItem::hoverEnterEvent + Handle hover enter event + @param event +*/ void QetShapeItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { m_hovered = true; @@ -337,10 +337,10 @@ void QetShapeItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event) } /** - * @brief QetShapeItem::hoverLeaveEvent - * Handle hover leave event - * @param event - */ + @brief QetShapeItem::hoverLeaveEvent + Handle hover leave event + @param event +*/ void QetShapeItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { m_hovered = false; @@ -359,11 +359,11 @@ void QetShapeItem::mousePressEvent(QGraphicsSceneMouseEvent *event) } /** - * @brief QetShapeItem::itemChange - * @param change - * @param value - * @return - */ + @brief QetShapeItem::itemChange + @param change + @param value + @return +*/ QVariant QetShapeItem::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant &value) { if (change == ItemSelectedHasChanged) @@ -396,11 +396,11 @@ QVariant QetShapeItem::itemChange(QGraphicsItem::GraphicsItemChange change, cons } /** - * @brief QetShapeItem::sceneEventFilter - * @param watched - * @param event - * @return - */ + @brief QetShapeItem::sceneEventFilter + @param watched + @param event + @return +*/ bool QetShapeItem::sceneEventFilter(QGraphicsItem *watched, QEvent *event) { //Watched must be an handler @@ -436,9 +436,9 @@ bool QetShapeItem::sceneEventFilter(QGraphicsItem *watched, QEvent *event) } /** - * @brief QetShapeItem::contextMenuEvent - * @param event - */ + @brief QetShapeItem::contextMenuEvent + @param event +*/ void QetShapeItem::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) { m_context_menu_pos = event->pos(); @@ -495,8 +495,8 @@ void QetShapeItem::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) } /** - * @brief QetShapeItem::switchResizeMode - */ + @brief QetShapeItem::switchResizeMode +*/ void QetShapeItem::switchResizeMode() { if (m_shapeType == Ellipse) @@ -590,9 +590,9 @@ void QetShapeItem::addHandler() } /** - * @brief QetShapeItem::adjusteHandlerPos - * Adjust the position of the handler item - */ + @brief QetShapeItem::adjusteHandlerPos + Adjust the position of the handler item +*/ void QetShapeItem::adjusteHandlerPos() { if (m_handler_vector.isEmpty()) { @@ -689,10 +689,10 @@ void QetShapeItem::removePoint() } /** - * @brief QetShapeItem::handlerMousePressEvent - * @param qghi - * @param event - */ + @brief QetShapeItem::handlerMousePressEvent + @param qghi + @param event +*/ void QetShapeItem::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi) @@ -709,10 +709,10 @@ void QetShapeItem::handlerMousePressEvent(QetGraphicsHandlerItem *qghi, QGraphic } /** - * @brief QetShapeItem::handlerMouseMoveEvent - * @param qghi - * @param event - */ + @brief QetShapeItem::handlerMouseMoveEvent + @param qghi + @param event +*/ void QetShapeItem::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi) @@ -773,10 +773,10 @@ void QetShapeItem::handlerMouseMoveEvent(QetGraphicsHandlerItem *qghi, QGraphics } /** - * @brief QetShapeItem::handlerMouseReleaseEvent - * @param qghi - * @param event - */ + @brief QetShapeItem::handlerMouseReleaseEvent + @param qghi + @param event +*/ void QetShapeItem::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraphicsSceneMouseEvent *event) { Q_UNUSED(qghi); @@ -831,11 +831,11 @@ void QetShapeItem::handlerMouseReleaseEvent(QetGraphicsHandlerItem *qghi, QGraph } /** - * @brief QetShapeItem::fromXml - * Build this item from the xml description - * @param e element where is stored this item - * @return true if load success - */ + @brief QetShapeItem::fromXml + Build this item from the xml description + @param e element where is stored this item + @return true if load success +*/ bool QetShapeItem::fromXml(const QDomElement &e) { if (e.tagName() != "shape") return (false); @@ -888,11 +888,11 @@ bool QetShapeItem::fromXml(const QDomElement &e) } /** - * @brief QetShapeItem::toXml - * Save this item to xml element - * @param document parent document xml - * @return element xml where is write this item - */ + @brief QetShapeItem::toXml + Save this item to xml element + @param document parent document xml + @return element xml where is write this item +*/ QDomElement QetShapeItem::toXml(QDomDocument &document) const { QDomElement result = document.createElement("shape"); @@ -948,11 +948,11 @@ QDomElement QetShapeItem::toXml(QDomDocument &document) const } /** - * @brief QetShapeItem::toDXF - * Draw this element to the dxf document - * @param filepath file path of the the dxf document - * @return true if draw success - */ + @brief QetShapeItem::toDXF + Draw this element to the dxf document + @param filepath file path of the the dxf document + @return true if draw success +*/ bool QetShapeItem::toDXF(const QString &filepath,const QPen &pen) { @@ -966,9 +966,9 @@ bool QetShapeItem::toDXF(const QString &filepath,const QPen &pen) } /** - * @brief QetShapeItem::editProperty - * Edit the property of this item - */ + @brief QetShapeItem::editProperty + Edit the property of this item +*/ void QetShapeItem::editProperty() { if (diagram() -> isReadOnly()) return; @@ -978,9 +978,9 @@ void QetShapeItem::editProperty() } /** - * @brief QetShapeItem::name - * @return the name of the curent shape. - */ + @brief QetShapeItem::name + @return the name of the curent shape. +*/ QString QetShapeItem::name() const { switch (m_shapeType) { case Line: return tr("une ligne"); diff --git a/sources/qetgraphicsitem/qetshapeitem.h b/sources/qetgraphicsitem/qetshapeitem.h index 2474ec85d..565d6a56c 100644 --- a/sources/qetgraphicsitem/qetshapeitem.h +++ b/sources/qetgraphicsitem/qetshapeitem.h @@ -28,10 +28,10 @@ class QetGraphicsHandlerItem; class QAction; /** - * @brief The QetShapeItem class - * this class is used to draw a basic shape (line, rectangle, ellipse) - * into a diagram, that can be saved to .qet file. - */ + @brief The QetShapeItem class + this class is used to draw a basic shape (line, rectangle, ellipse) + into a diagram, that can be saved to .qet file. +*/ class QetShapeItem : public QetGraphicsItem { Q_OBJECT diff --git a/sources/qetgraphicsitem/qgraphicsitemutility.cpp b/sources/qetgraphicsitem/qgraphicsitemutility.cpp index c105fd6b4..88c8b90cc 100644 --- a/sources/qetgraphicsitem/qgraphicsitemutility.cpp +++ b/sources/qetgraphicsitem/qgraphicsitemutility.cpp @@ -22,11 +22,11 @@ #include /** - * @brief centerToParentBottom - * Center the item at the bottom of is parent. - * @param item item to center - * @return true if centered else false (item have not parent) - */ + @brief centerToParentBottom + Center the item at the bottom of is parent. + @param item item to center + @return true if centered else false (item have not parent) +*/ bool centerToParentBottom(QGraphicsItem *item) { if (! item->parentItem()) { qDebug() << "Qet::centerToParentBottom : item have not parent"; @@ -42,13 +42,13 @@ bool centerToParentBottom(QGraphicsItem *item) { } /** - * @brief centerToBottomDiagram - * Set item pos to the bottom of diagram and centered vertically to element_to_follow, and add offset. - * @param item_to_center - * @param element_to_follow - * @param offset - * @return true if element is centered else false (element_to_follow have not diagram) - */ + @brief centerToBottomDiagram + Set item pos to the bottom of diagram and centered vertically to element_to_follow, and add offset. + @param item_to_center + @param element_to_follow + @param offset + @return true if element is centered else false (element_to_follow have not diagram) +*/ #include "elementtextitemgroup.h" #include "crossrefitem.h" bool centerToBottomDiagram (QGraphicsItem *item_to_center, Element *element_to_follow, qreal offset) { diff --git a/sources/qetgraphicsitem/reportelement.cpp b/sources/qetgraphicsitem/reportelement.cpp index a5fdc513d..90c76928d 100644 --- a/sources/qetgraphicsitem/reportelement.cpp +++ b/sources/qetgraphicsitem/reportelement.cpp @@ -30,9 +30,9 @@ ReportElement::ReportElement(const ElementsLocation &location, const QString& li {} /** - * @brief ReportElement::~ReportElement - * Destructor - */ + @brief ReportElement::~ReportElement + Destructor +*/ ReportElement::~ReportElement() { unlinkAllElements(); @@ -41,11 +41,11 @@ ReportElement::~ReportElement() } /** - * @brief ReportElement::linkToElement - * Link this element to the other element - * @param elmt - * element to be linked with this - */ + @brief ReportElement::linkToElement + Link this element to the other element + @param elmt + element to be linked with this +*/ void ReportElement::linkToElement(Element * elmt) { if (!diagram() && !elmt -> diagram()) @@ -70,9 +70,9 @@ void ReportElement::linkToElement(Element * elmt) } /** - * @brief ReportElement::unLinkAllElements - * Unlink all of the element in the QList connected_elements - */ + @brief ReportElement::unLinkAllElements + Unlink all of the element in the QList connected_elements +*/ void ReportElement::unlinkAllElements() { if (isFree()) @@ -92,12 +92,12 @@ void ReportElement::unlinkAllElements() emit linkedElementChanged(); } /** - * @brief ReportElement::unlinkElement + @brief ReportElement::unlinkElement *unlink the specified element. *for reportelement, they must be only one linked element, so we call *unlinkAllElements for clear the connected_elements list. - * @param elmt - */ + @param elmt +*/ void ReportElement::unlinkElement(Element *elmt) { Q_UNUSED (elmt); unlinkAllElements(); diff --git a/sources/qetgraphicsitem/reportelement.h b/sources/qetgraphicsitem/reportelement.h index 84f03266e..361fe0194 100644 --- a/sources/qetgraphicsitem/reportelement.h +++ b/sources/qetgraphicsitem/reportelement.h @@ -21,10 +21,10 @@ #include "element.h" /** - * @brief The ReportElement class + @brief The ReportElement class *this class represent an element that can be linked to an other ReportElement - * a folio report in a diagram is a element that show a wire go on an other folio - */ + a folio report in a diagram is a element that show a wire go on an other folio +*/ class ReportElement : public Element { Q_OBJECT diff --git a/sources/qetgraphicsitem/simpleelement.cpp b/sources/qetgraphicsitem/simpleelement.cpp index e8715b437..04da9f802 100644 --- a/sources/qetgraphicsitem/simpleelement.cpp +++ b/sources/qetgraphicsitem/simpleelement.cpp @@ -19,27 +19,27 @@ #include "diagram.h" /** - * @brief SimpleElement::SimpleElement - * @param location - * @param qgi - * @param s - * @param state - */ + @brief SimpleElement::SimpleElement + @param location + @param qgi + @param s + @param state +*/ SimpleElement::SimpleElement(const ElementsLocation &location, QGraphicsItem *qgi, int *state) : Element(location, qgi, state, Element::Simple) {} /** - * @brief SimpleElement::~SimpleElement - */ + @brief SimpleElement::~SimpleElement +*/ SimpleElement::~SimpleElement() {} /** - * @brief SimpleElement::initLink - * @param project - * Call init Link from custom element and after - * call update label for setup it. - */ + @brief SimpleElement::initLink + @param project + Call init Link from custom element and after + call update label for setup it. +*/ void SimpleElement::initLink(QETProject *project) { Element::initLink(project); } diff --git a/sources/qetgraphicsitem/simpleelement.h b/sources/qetgraphicsitem/simpleelement.h index d042b926f..50705bddb 100644 --- a/sources/qetgraphicsitem/simpleelement.h +++ b/sources/qetgraphicsitem/simpleelement.h @@ -23,9 +23,9 @@ class QETProject; /** - * @brief The SimpleElement class - *this class represente a simple element with no specific attribute - */ + @brief The SimpleElement class + this class represente a simple element with no specific attribute +*/ class SimpleElement : public Element { Q_OBJECT diff --git a/sources/qetgraphicsitem/slaveelement.cpp b/sources/qetgraphicsitem/slaveelement.cpp index 2a2f4fb08..c4e81c6a2 100644 --- a/sources/qetgraphicsitem/slaveelement.cpp +++ b/sources/qetgraphicsitem/slaveelement.cpp @@ -22,13 +22,13 @@ #include "dynamicelementtextitem.h" /** - * @brief SlaveElement::SlaveElement - * Default constructor - * @param location location of xml definition - * @param qgi parent QGraphicItem - * @param s parent diagram - * @param state int used to know if the creation of element have error - */ + @brief SlaveElement::SlaveElement + Default constructor + @param location location of xml definition + @param qgi parent QGraphicItem + @param s parent diagram + @param state int used to know if the creation of element have error +*/ SlaveElement::SlaveElement(const ElementsLocation &location, QGraphicsItem *qgi, int *state) : Element(location, qgi, state, Element::Slave) { @@ -36,19 +36,19 @@ SlaveElement::SlaveElement(const ElementsLocation &location, QGraphicsItem *qgi, } /** - * @brief SlaveElement::~SlaveElement - * default destructor - */ + @brief SlaveElement::~SlaveElement + default destructor +*/ SlaveElement::~SlaveElement() { unlinkAllElements(); } /** - * @brief SlaveElement::linkToElement - * Link this slave to another element - * For this class element must be a master - * @param elmt - */ + @brief SlaveElement::linkToElement + Link this slave to another element + For this class element must be a master + @param elmt +*/ void SlaveElement::linkToElement(Element *elmt) { // check if element is master and if isn't already linked @@ -65,9 +65,9 @@ void SlaveElement::linkToElement(Element *elmt) } /** - * @brief SlaveElement::unlinkAllElements - * Unlink all of the element in the QList connected_elements - */ + @brief SlaveElement::unlinkAllElements + Unlink all of the element in the QList connected_elements +*/ void SlaveElement::unlinkAllElements() { // if this element is free no need to do something @@ -80,10 +80,10 @@ void SlaveElement::unlinkAllElements() } /** - * @brief SlaveElement::unlinkElement - * Unlink the given elmt in parametre - * @param elmt - */ + @brief SlaveElement::unlinkElement + Unlink the given elmt in parametre + @param elmt +*/ void SlaveElement::unlinkElement(Element *elmt) { //Ensure elmt is linked to this element diff --git a/sources/qetgraphicsitem/terminal.cpp b/sources/qetgraphicsitem/terminal.cpp index 4412d527c..0789e1ccb 100644 --- a/sources/qetgraphicsitem/terminal.cpp +++ b/sources/qetgraphicsitem/terminal.cpp @@ -72,14 +72,14 @@ void Terminal::init(QString number, QString name, bool hiddenName) { } /*! - * \brief Terminal::init - * Additionaly to the init above, this method stores position and orientation into the data class - * \param pf - * \param o - * \param number - * \param name - * \param hiddenName - */ + \brief Terminal::init + Additionaly to the init above, this method stores position and orientation into the data class + \param pf + \param o + \param number + \param name + \param hiddenName +*/ void Terminal::init(QPointF pf, Qet::Orientation o, QString number, QString name, bool hiddenName) { // definition du pount d'amarrage pour un conducteur diff --git a/sources/qetinformation.cpp b/sources/qetinformation.cpp index 80af19a67..30ad34d77 100644 --- a/sources/qetinformation.cpp +++ b/sources/qetinformation.cpp @@ -21,9 +21,9 @@ #include /** - * @brief QETInformation::titleblockInfoKeys - * @return all available key for use with a titleblock - */ + @brief QETInformation::titleblockInfoKeys + @return all available key for use with a titleblock +*/ QStringList QETInformation::titleblockInfoKeys() { QStringList info_list; @@ -52,11 +52,11 @@ QStringList QETInformation::titleblockInfoKeys() } /** - * @brief QETInformation::titleblockTranslatedInfoKey - * @param info : info key to be translated - * @return the translated information given by @info - * If @info don't match, return an empty string - */ + @brief QETInformation::titleblockTranslatedInfoKey + @param info : info key to be translated + @return the translated information given by @info + If @info don't match, return an empty string +*/ QString QETInformation::titleblockTranslatedInfoKey(const QString &info) { if (info == "author") return QObject::tr("Auteur"); @@ -83,11 +83,11 @@ QString QETInformation::titleblockTranslatedInfoKey(const QString &info) } /** - * @brief QETInformation::titleblockInfoKeysToVar - * @param info - * @return var in form %{my-var} corresponding to the info. - * if there is not available var for the given info, the returned var is %{void} - */ + @brief QETInformation::titleblockInfoKeysToVar + @param info + @return var in form %{my-var} corresponding to the info. + if there is not available var for the given info, the returned var is %{void} +*/ QString QETInformation::titleblockInfoKeysToVar(const QString &info) { if (info == "author") return QString("%{author}"); @@ -114,10 +114,10 @@ QString QETInformation::titleblockInfoKeysToVar(const QString &info) } /** - * @brief QETInformation::titleblockTranslatedKeyHashVar - * @return a QHash with for key, the translated information key of title block, - * and for value the corresponding var. - */ + @brief QETInformation::titleblockTranslatedKeyHashVar + @return a QHash with for key, the translated information key of title block, + and for value the corresponding var. +*/ QHash QETInformation::titleblockTranslatedKeyHashVar() { QHash hash_; diff --git a/sources/qetproject.cpp b/sources/qetproject.cpp index b8fe7e9d6..baba579c7 100644 --- a/sources/qetproject.cpp +++ b/sources/qetproject.cpp @@ -38,10 +38,10 @@ static int BACKUP_INTERVAL = 120000; //interval in ms of backup = 2min /** - * @brief QETProject::QETProject - * Create a empty project - * @param parent - */ + @brief QETProject::QETProject + Create a empty project + @param parent +*/ QETProject::QETProject(QObject *parent) : QObject (parent), m_titleblocks_collection(this), @@ -54,11 +54,11 @@ QETProject::QETProject(QObject *parent) : } /** - * @brief QETProject::QETProject - * Construct a project from a .qet file - * @param path : path of the file - * @param parent : parent QObject - */ + @brief QETProject::QETProject + Construct a project from a .qet file + @param path : path of the file + @param parent : parent QObject +*/ QETProject::QETProject(const QString &path, QObject *parent) : QObject (parent), m_titleblocks_collection(this), @@ -74,10 +74,10 @@ QETProject::QETProject(const QString &path, QObject *parent) : } /** - * @brief QETProject::QETProject - * @param backup : backup file to open, QETProject take ownership of backup. - * @param parent : parent QObject - */ + @brief QETProject::QETProject + @param backup : backup file to open, QETProject take ownership of backup. + @param parent : parent QObject +*/ QETProject::QETProject(KAutoSaveFile *backup, QObject *parent) : QObject (parent), m_titleblocks_collection(this), @@ -108,9 +108,9 @@ QETProject::QETProject(KAutoSaveFile *backup, QObject *parent) : } /** - * @brief QETProject::~QETProject - * Destructor - */ + @brief QETProject::~QETProject + Destructor +*/ QETProject::~QETProject() { for (auto diagram : m_diagrams_list) @@ -118,24 +118,24 @@ QETProject::~QETProject() } /** - * @brief QETProject::dataBase - * @return The data base of this project - */ + @brief QETProject::dataBase + @return The data base of this project +*/ projectDataBase *QETProject::dataBase() { return &m_data_base; } /** - * @brief QETProject::uuid - * @return the uuid of this project - */ + @brief QETProject::uuid + @return the uuid of this project +*/ QUuid QETProject::uuid() const { return m_uuid; } /** - * @brief QETProject::init - */ + @brief QETProject::init +*/ void QETProject::init() { connect(&m_titleblocks_collection, &TitleBlockTemplatesCollection::changed, this, &QETProject::updateDiagramsTitleBlockTemplate); @@ -165,10 +165,10 @@ void QETProject::init() } /** - * @brief QETProject::openFile - * @param file - * @return - */ + @brief QETProject::openFile + @param file + @return +*/ QETProject::ProjectState QETProject::openFile(QFile *file) { bool opened_here = file->isOpen() ? false : true; @@ -228,9 +228,9 @@ int QETProject::folioIndex(const Diagram *diagram) const { } /** - * @brief QETProject::embeddedCollection - * @return The embedded collection - */ + @brief QETProject::embeddedCollection + @return The embedded collection +*/ XmlElementCollection *QETProject::embeddedElementCollection() const { return m_elements_collection; } @@ -250,13 +250,13 @@ QString QETProject::filePath() { } /** - * @brief QETProject::setFilePath - * Set the filepath of this project file - * Set a file path also create a backup file according to the path. - * If a previous path was set, the previous backup file is deleted and a new one - * is created according to the path. - * @param filepath - */ + @brief QETProject::setFilePath + Set the filepath of this project file + Set a file path also create a backup file according to the path. + If a previous path was set, the previous backup file is deleted and a new one + is created according to the path. + @param filepath +*/ void QETProject::setFilePath(const QString &filepath) { if (filepath == m_file_path) { @@ -416,10 +416,10 @@ TitleBlockProperties QETProject::defaultTitleBlockProperties() const { } /** - * @brief QETProject::setDefaultTitleBlockProperties - * Specify the title block to be used at the creation of a new diagram for this project - * @param titleblock - */ + @brief QETProject::setDefaultTitleBlockProperties + Specify the title block to be used at the creation of a new diagram for this project + @param titleblock +*/ void QETProject::setDefaultTitleBlockProperties(const TitleBlockProperties &titleblock) { default_titleblock_properties_ = titleblock; //Integrate the title block in this project @@ -485,26 +485,26 @@ void QETProject::setDefaultXRefProperties(QHash hash) } /** - * @brief QETProject::conductorAutoNum - * @return All value of conductor autonum stored in project - */ + @brief QETProject::conductorAutoNum + @return All value of conductor autonum stored in project +*/ QHash QETProject::conductorAutoNum() const { return m_conductor_autonum; } /** - * @brief QETProject::elementAutoNum - * @return All value of element autonum stored in project - */ + @brief QETProject::elementAutoNum + @return All value of element autonum stored in project +*/ QHash QETProject::elementAutoNum() const { return m_element_autonum; } /** - * @brief QETProject::elementAutoNumFormula - * @param element autonum title - * @return Formula of element autonum stored in element autonum - */ + @brief QETProject::elementAutoNumFormula + @param element autonum title + @return Formula of element autonum stored in element autonum +*/ QString QETProject::elementAutoNumFormula (const QString& key) const { if (m_element_autonum.contains(key)) { @@ -515,34 +515,34 @@ QString QETProject::elementAutoNumFormula (const QString& key) const } /** - * @brief QETProject::elementAutoNumCurrentFormula - * @return current formula being used by project - */ + @brief QETProject::elementAutoNumCurrentFormula + @return current formula being used by project +*/ QString QETProject::elementAutoNumCurrentFormula() const { return elementAutoNumFormula(m_current_element_autonum); } /** - * @brief QETProject::elementCurrentAutoNum - * @return current element autonum title - */ + @brief QETProject::elementCurrentAutoNum + @return current element autonum title +*/ QString QETProject::elementCurrentAutoNum () const { return m_current_element_autonum; } /** - * @brief QETProject::setCurrrentElementAutonum - * @param autoNum : set the current element autonum to @autonum - */ + @brief QETProject::setCurrrentElementAutonum + @param autoNum : set the current element autonum to @autonum +*/ void QETProject::setCurrrentElementAutonum(QString autoNum) { m_current_element_autonum = std::move(autoNum); } /** - * @brief QETProject::conductorAutoNumFormula - * @param conductor autonum title - * @return Formula of element autonum stored in conductor autonum - */ + @brief QETProject::conductorAutoNumFormula + @param conductor autonum title + @return Formula of element autonum stored in conductor autonum +*/ QString QETProject::conductorAutoNumFormula (const QString& key) const { if (m_conductor_autonum.contains(key)) @@ -552,47 +552,47 @@ QString QETProject::conductorAutoNumFormula (const QString& key) const } /** - * @brief QETProject::conductorCurrentAutoNum - * @return current conductor autonum title - */ + @brief QETProject::conductorCurrentAutoNum + @return current conductor autonum title +*/ QString QETProject::conductorCurrentAutoNum () const { return m_current_conductor_autonum; } /** - * @brief QETProject::setCurrentConductorAutoNum - * @param autoNum set the current conductor autonum to @autonum - */ + @brief QETProject::setCurrentConductorAutoNum + @param autoNum set the current conductor autonum to @autonum +*/ void QETProject::setCurrentConductorAutoNum(QString autoNum) { m_current_conductor_autonum = std::move(autoNum); } /** - * @brief QETProject::folioAutoNum - * @return All value of folio autonum stored in project - */ + @brief QETProject::folioAutoNum + @return All value of folio autonum stored in project +*/ QHash QETProject::folioAutoNum() const { return m_folio_autonum; } /** - * @brief QETProject::addConductorAutoNum - * Add a new conductor numerotation context. If key already exist, - * replace old context by the new context - * @param key - * @param context - */ + @brief QETProject::addConductorAutoNum + Add a new conductor numerotation context. If key already exist, + replace old context by the new context + @param key + @param context +*/ void QETProject::addConductorAutoNum(const QString& key, const NumerotationContext& context) { m_conductor_autonum.insert(key, context); } /** - * @brief QETProject::addElementAutoNum - * Add a new element numerotation context. If key already exist, - * replace old context by the new context - * @param key - * @param context - */ + @brief QETProject::addElementAutoNum + Add a new element numerotation context. If key already exist, + replace old context by the new context + @param key + @param context +*/ void QETProject::addElementAutoNum(const QString& key, const NumerotationContext& context) { m_element_autonum.insert(key, context); @@ -600,30 +600,30 @@ void QETProject::addElementAutoNum(const QString& key, const NumerotationContext } /** - * @brief QETProject::addFolioAutoNum - * Add a new folio numerotation context. If key already exist, - * replace old context by the new context - * @param key - * @param context - */ + @brief QETProject::addFolioAutoNum + Add a new folio numerotation context. If key already exist, + replace old context by the new context + @param key + @param context +*/ void QETProject::addFolioAutoNum(const QString& key, const NumerotationContext& context) { m_folio_autonum.insert(key, context); } /** - * @brief QETProject::removeConductorAutoNum - * Remove Conductor Numerotation Context stored with key - * @param key - */ + @brief QETProject::removeConductorAutoNum + Remove Conductor Numerotation Context stored with key + @param key +*/ void QETProject::removeConductorAutoNum(const QString& key) { m_conductor_autonum.remove(key); } /** - * @brief QETProject::removeElementAutonum - * Remove Element Numerotation Context stored with key - * @param key - */ + @brief QETProject::removeElementAutonum + Remove Element Numerotation Context stored with key + @param key +*/ void QETProject::removeElementAutoNum(const QString& key) { m_element_autonum.remove(key); @@ -631,53 +631,53 @@ void QETProject::removeElementAutoNum(const QString& key) } /** - * @brief QETProject::removeFolioAutonum - * Remove Folio Numerotation Context stored with key - * @param key - */ + @brief QETProject::removeFolioAutonum + Remove Folio Numerotation Context stored with key + @param key +*/ void QETProject::removeFolioAutoNum(const QString& key) { m_folio_autonum.remove(key); } /** - * @brief QETProject::conductorAutoNum - * Return conductor numerotation context stored with @key. - * If key is not found, return an empty numerotation context - * @param key - */ + @brief QETProject::conductorAutoNum + Return conductor numerotation context stored with @key. + If key is not found, return an empty numerotation context + @param key +*/ NumerotationContext QETProject::conductorAutoNum (const QString &key) const { if (m_conductor_autonum.contains(key)) return m_conductor_autonum[key]; else return NumerotationContext(); } /** - * @brief QETProject::elementAutoNum - * Return element numerotation context stored with @key. - * If key is not found, return an empty numerotation context - * @param key - */ + @brief QETProject::elementAutoNum + Return element numerotation context stored with @key. + If key is not found, return an empty numerotation context + @param key +*/ NumerotationContext QETProject::elementAutoNum (const QString &key) { if (m_element_autonum.contains(key)) return m_element_autonum[key]; else return NumerotationContext(); } /** - * @brief QETProject::folioAutoNum - * Return folio numerotation context stored with @key. - * If key is not found, return an empty numerotation context - * @param key - */ + @brief QETProject::folioAutoNum + Return folio numerotation context stored with @key. + If key is not found, return an empty numerotation context + @param key +*/ NumerotationContext QETProject::folioAutoNum (const QString &key) const { if (m_folio_autonum.contains(key)) return m_folio_autonum[key]; else return NumerotationContext(); } /** - * @brief QETProject::freezeExistentConductorLabel - * Freeze Existent Conductors in the selected folios - * @param from - first folio index to apply freeze - * @param to - last folio index to apply freeze - */ + @brief QETProject::freezeExistentConductorLabel + Freeze Existent Conductors in the selected folios + @param from - first folio index to apply freeze + @param to - last folio index to apply freeze +*/ void QETProject::freezeExistentConductorLabel(bool freeze, int from, int to) { for (int i = from; i <= to; i++) { m_diagrams_list.at(i)->freezeConductors(freeze); @@ -685,11 +685,11 @@ void QETProject::freezeExistentConductorLabel(bool freeze, int from, int to) { } /** - * @brief QETProject::freezeNewConductorLabel - * Freeze New Conductors in the selected folios - * @param from - first folio index to apply freeze - * @param to - last folio index to apply freeze - */ + @brief QETProject::freezeNewConductorLabel + Freeze New Conductors in the selected folios + @param from - first folio index to apply freeze + @param to - last folio index to apply freeze +*/ void QETProject::freezeNewConductorLabel(bool freeze, int from, int to) { for (int i = from; i <= to; i++) { m_diagrams_list.at(i)->setFreezeNewConductors(freeze); @@ -697,27 +697,27 @@ void QETProject::freezeNewConductorLabel(bool freeze, int from, int to) { } /** - * @brief QETProject::isFreezeNewConductors - * @return freeze new conductors Project Wide status - */ + @brief QETProject::isFreezeNewConductors + @return freeze new conductors Project Wide status +*/ bool QETProject::isFreezeNewConductors() { return m_freeze_new_conductors; } /** - * @brief QETProject::setfreezeNewConductors - * Set Project Wide freeze new conductors - */ + @brief QETProject::setfreezeNewConductors + Set Project Wide freeze new conductors +*/ void QETProject::setFreezeNewConductors(bool set) { m_freeze_new_conductors = set; } /** - * @brief QETProject::freezeExistentElementLabel - * Freeze Existent Elements in the selected folios - * @param from - first folio index to apply freeze - * @param to - last folio index to apply freeze - */ + @brief QETProject::freezeExistentElementLabel + Freeze Existent Elements in the selected folios + @param from - first folio index to apply freeze + @param to - last folio index to apply freeze +*/ void QETProject::freezeExistentElementLabel(bool freeze, int from, int to) { for (int i = from; i <= to; i++) { m_diagrams_list.at(i)->freezeElements(freeze); @@ -725,11 +725,11 @@ void QETProject::freezeExistentElementLabel(bool freeze, int from, int to) { } /** - * @brief QETProject::freezeNewElementLabel - * Freeze New Elements in the selected folios - * @param from - first folio index to apply freeze - * @param to - last folio index to apply freeze - */ + @brief QETProject::freezeNewElementLabel + Freeze New Elements in the selected folios + @param from - first folio index to apply freeze + @param to - last folio index to apply freeze +*/ void QETProject::freezeNewElementLabel(bool freeze, int from, int to) { for (int i = from; i <= to; i++) { m_diagrams_list.at(i)->setFreezeNewElements(freeze); @@ -737,37 +737,37 @@ void QETProject::freezeNewElementLabel(bool freeze, int from, int to) { } /** - * @brief QETProject::freezeNewElements - * @return freeze new elements Project Wide status - */ + @brief QETProject::freezeNewElements + @return freeze new elements Project Wide status +*/ bool QETProject::isFreezeNewElements() { return m_freeze_new_elements; } /** - * @brief QETProject::setfreezeNewElements - * Set Project Wide freeze new elements - */ + @brief QETProject::setfreezeNewElements + Set Project Wide freeze new elements +*/ void QETProject::setFreezeNewElements(bool set) { m_freeze_new_elements = set; } /** - * @brief QETProject::autoConductor - * @return true if use of auto conductor is authorized. - * See also Q_PROPERTY autoConductor - */ + @brief QETProject::autoConductor + @return true if use of auto conductor is authorized. + See also Q_PROPERTY autoConductor +*/ bool QETProject::autoConductor() const { return m_auto_conductor; } /** - * @brief QETProject::setAutoConductor - * @param ac - * Enable the use of auto conductor if true - * See also Q_PROPERTY autoConductor - */ + @brief QETProject::setAutoConductor + @param ac + Enable the use of auto conductor if true + See also Q_PROPERTY autoConductor +*/ void QETProject::setAutoConductor(bool ac) { if (ac != m_auto_conductor) @@ -775,19 +775,19 @@ void QETProject::setAutoConductor(bool ac) } /** - * @brief QETProject::autoFolioNumberingNewFolios - * emit Signal to add new Diagram with autonum - * properties - */ + @brief QETProject::autoFolioNumberingNewFolios + emit Signal to add new Diagram with autonum + properties +*/ void QETProject::autoFolioNumberingNewFolios(){ emit addAutoNumDiagram(); } /** - * @brief QETProject::autoFolioNumberingNewFolios - * @param autonum used, index from selected tabs "from" and "to" - * rename folios with selected autonum - */ + @brief QETProject::autoFolioNumberingNewFolios + @param autonum used, index from selected tabs "from" and "to" + rename folios with selected autonum +*/ void QETProject::autoFolioNumberingSelectedFolios(int from, int to, const QString& autonum){ int total_folio = m_diagrams_list.count(); DiagramContext project_wide_properties = m_project_properties; @@ -862,12 +862,12 @@ bool QETProject::close() { } /** - * @brief QETProject::write - * Save the project in a file - * @see filePath() - * @see setFilePath() - * @return true if the project was successfully saved, else false - */ + @brief QETProject::write + Save the project in a file + @see filePath() + @see setFilePath() + @return true if the project was successfully saved, else false +*/ QETResult QETProject::write() { // this operation requires a filepath @@ -903,10 +903,10 @@ bool QETProject::isReadOnly() const { } /** - * @brief QETProject::setReadOnly - * Set this project to read only if @read_only = true - * @param read_only - */ + @brief QETProject::setReadOnly + Set this project to read only if @read_only = true + @param read_only +*/ void QETProject::setReadOnly(bool read_only) { if (m_read_only != read_only) @@ -940,11 +940,11 @@ bool QETProject::isEmpty() const { } /** - * @brief QETProject::importElement - * Import the element represented by @location to the embbeded collection of this project - * @param location - * @return the location of the imported element, location can be null. - */ + @brief QETProject::importElement + Import the element represented by @location to the embbeded collection of this project + @param location + @return the location of the imported element, location can be null. +*/ ElementsLocation QETProject::importElement(ElementsLocation &location) { //Location isn't an element or doesn't exist @@ -1079,12 +1079,12 @@ bool QETProject::usesElement(const ElementsLocation &location) const } /** - * @brief QETProject::unusedElements - * @return the list of unused element (exactly her location) - * An unused element, is an element present in the embedded collection but not present in a diagram of this project. - * Be aware that an element can be not present in a diagram, - * but managed by an undo command (delete an element), so an unused element can be used after an undo. - */ + @brief QETProject::unusedElements + @return the list of unused element (exactly her location) + An unused element, is an element present in the embedded collection but not present in a diagram of this project. + Be aware that an element can be not present in a diagram, + but managed by an undo command (delete an element), so an unused element can be used after an undo. +*/ QList QETProject::unusedElements() const { QList unused_list; @@ -1114,11 +1114,11 @@ bool QETProject::usesTitleBlockTemplate(const TitleBlockTemplateLocation &locati } /** - * @brief QETProject::addNewDiagram - * Add a new diagram in project at position pos. - * @param pos - * @return the new created diagram - */ + @brief QETProject::addNewDiagram + Add a new diagram in project at position pos. + @param pos + @return the new created diagram +*/ Diagram *QETProject::addNewDiagram(int pos) { if (isReadOnly()) { @@ -1137,10 +1137,10 @@ Diagram *QETProject::addNewDiagram(int pos) } /** - * @brief QETProject::removeDiagram - * Remove @diagram from project - * @param diagram - */ + @brief QETProject::removeDiagram + Remove @diagram from project + @param diagram +*/ void QETProject::removeDiagram(Diagram *diagram) { if (isReadOnly() || @@ -1190,10 +1190,10 @@ void QETProject::setModified(bool modified) { } /** - * @brief QETProject::readProjectXml - * Read and make the project from an xml description - * @param xml_project : the description of the project from an xml - */ + @brief QETProject::readProjectXml + Read and make the project from an xml description + @param xml_project : the description of the project from an xml +*/ void QETProject::readProjectXml(QDomDocument &xml_project) { QDomElement root_elmt = xml_project.documentElement(); @@ -1256,11 +1256,11 @@ void QETProject::readProjectXml(QDomDocument &xml_project) } /** - * @brief QETProject::readDiagramsXml - * Load the diagrams from the xml description of the project. - * Note a project can have 0 diagram - * @param xml_project - */ + @brief QETProject::readDiagramsXml + Load the diagrams from the xml description of the project. + Note a project can have 0 diagram + @param xml_project +*/ void QETProject::readDiagramsXml(QDomDocument &xml_project) { //@TODO try to solve a weird bug (dialog is black) since port to Qt5 with the DialogWaiting @@ -1328,10 +1328,10 @@ void QETProject::readDiagramsXml(QDomDocument &xml_project) } /** - * @brief QETProject::readElementsCollectionXml - * Load the diagrams from the xml description of the project - * @param xml_project : the xml description of the project - */ + @brief QETProject::readElementsCollectionXml + Load the diagrams from the xml description of the project + @param xml_project : the xml description of the project +*/ void QETProject::readElementsCollectionXml(QDomDocument &xml_project) { //Get the embedded elements collection of the project @@ -1354,10 +1354,10 @@ void QETProject::readElementsCollectionXml(QDomDocument &xml_project) } /** - * @brief QETProject::readProjectPropertiesXml - * Load project properties from the XML description of the project - * @param xml_project : the xml description of the project - */ + @brief QETProject::readProjectPropertiesXml + Load project properties from the XML description of the project + @param xml_project : the xml description of the project +*/ void QETProject::readProjectPropertiesXml(QDomDocument &xml_project) { foreach (QDomElement e, QET::findInDomElement(xml_project.documentElement(), "properties")) @@ -1365,11 +1365,11 @@ void QETProject::readProjectPropertiesXml(QDomDocument &xml_project) } /** - * @brief QETProject::readDefaultPropertiesXml - * load default properties for new diagram, found in the xml of this project - * or by default find in the QElectroTech global conf - * @param xml_project : the xml description of the project - */ + @brief QETProject::readDefaultPropertiesXml + load default properties for new diagram, found in the xml of this project + or by default find in the QElectroTech global conf + @param xml_project : the xml description of the project +*/ void QETProject::readDefaultPropertiesXml(QDomDocument &xml_project) { // Find xml element where is stored properties for new diagram diff --git a/sources/qetxml.h b/sources/qetxml.h index aadf0e785..72ff046b1 100644 --- a/sources/qetxml.h +++ b/sources/qetxml.h @@ -28,7 +28,7 @@ class QAbstractItemModel; /** *This namespace contain some function to use xml with QET. - */ +*/ namespace QETXML { QDomElement penToXml(QDomDocument &parent_document, const QPen& pen); diff --git a/sources/recentfiles.cpp b/sources/recentfiles.cpp index 547112d24..ad9cc3139 100644 --- a/sources/recentfiles.cpp +++ b/sources/recentfiles.cpp @@ -111,9 +111,9 @@ void RecentFiles::fileWasOpened(const QString &filepath) { } /** - * @brief RecentFiles::extractFilesFromSettings - * Read the list of recent file from settings - */ + @brief RecentFiles::extractFilesFromSettings + Read the list of recent file from settings +*/ void RecentFiles::extractFilesFromSettings() { //Forget the list of recent files @@ -148,9 +148,9 @@ void RecentFiles::insertFile(const QString &filepath) { } /** - * @brief RecentFiles::saveFilesToSettings - * Write the list of recent files to settings - */ + @brief RecentFiles::saveFilesToSettings + Write the list of recent files to settings +*/ void RecentFiles::saveFilesToSettings() { QSettings settings; diff --git a/sources/richtext/richtexteditor.cpp b/sources/richtext/richtexteditor.cpp index df9cbda5a..2cb0b8b85 100644 --- a/sources/richtext/richtexteditor.cpp +++ b/sources/richtext/richtexteditor.cpp @@ -811,8 +811,8 @@ RichTextEditorDialog::~RichTextEditorDialog() } /** - * @brief RichTextEditorDialog::on_buttonBox_accepted - */ + @brief RichTextEditorDialog::on_buttonBox_accepted +*/ void RichTextEditorDialog::on_buttonBox_accepted() { emit applyEditText( text(Qt::RichText) ); this->close(); diff --git a/sources/titleblock/qettemplateeditor.cpp b/sources/titleblock/qettemplateeditor.cpp index 7a0b39b28..8a985bb87 100644 --- a/sources/titleblock/qettemplateeditor.cpp +++ b/sources/titleblock/qettemplateeditor.cpp @@ -584,9 +584,9 @@ QString QETTitleBlockTemplateEditor::currentlyEditedTitle() const { } /** - * @brief QETTitleBlockTemplateEditor::readSettings - * Read settings - */ + @brief QETTitleBlockTemplateEditor::readSettings + Read settings +*/ void QETTitleBlockTemplateEditor::readSettings() { QSettings settings; @@ -601,9 +601,9 @@ void QETTitleBlockTemplateEditor::readSettings() } /** - * @brief QETTitleBlockTemplateEditor::writeSettings - * Write the settings - */ + @brief QETTitleBlockTemplateEditor::writeSettings + Write the settings +*/ void QETTitleBlockTemplateEditor::writeSettings() { QSettings settings; @@ -907,11 +907,11 @@ void QETTitleBlockTemplateEditor::quit() { } /** - * @brief QETTitleBlockTemplateEditor::savePreviewWidthToApplicationSettings - * Save the new preview width to application settings - * @param former_preview_width : former_preview_width Unused, former preview width - * @param new_preview_width : new_preview_width New preview width - */ + @brief QETTitleBlockTemplateEditor::savePreviewWidthToApplicationSettings + Save the new preview width to application settings + @param former_preview_width : former_preview_width Unused, former preview width + @param new_preview_width : new_preview_width New preview width +*/ void QETTitleBlockTemplateEditor::savePreviewWidthToApplicationSettings(int former_preview_width, int new_preview_width) { Q_UNUSED(former_preview_width) diff --git a/sources/titleblock/templatescollection.cpp b/sources/titleblock/templatescollection.cpp index e98805e3a..7d6a3454d 100644 --- a/sources/titleblock/templatescollection.cpp +++ b/sources/titleblock/templatescollection.cpp @@ -67,18 +67,18 @@ void TitleBlockTemplatesCollection::setProtocol(const QString &protocol) { } /** - * @brief TitleBlockTemplatesCollection::collection - * @return the collection where is stored this collection. - */ + @brief TitleBlockTemplatesCollection::collection + @return the collection where is stored this collection. +*/ QET::QetCollection TitleBlockTemplatesCollection::collection() const { return m_collection; } /** - * @brief TitleBlockTemplatesCollection::setCollection - * Set the storage of this collection - * @param c - */ + @brief TitleBlockTemplatesCollection::setCollection + Set the storage of this collection + @param c +*/ void TitleBlockTemplatesCollection::setCollection(QET::QetCollection c) { m_collection = c; } diff --git a/sources/titleblockproperties.cpp b/sources/titleblockproperties.cpp index c645c3779..642b758f7 100644 --- a/sources/titleblockproperties.cpp +++ b/sources/titleblockproperties.cpp @@ -131,11 +131,11 @@ void TitleBlockProperties::fromXml(const QDomElement &e) { } /** - * @brief TitleBlockProperties::toSettings - * Export the TitleBlockProperties into a QSettings - * @param settings : setting to use - * @param prefix : name to use as prefix for this property - */ + @brief TitleBlockProperties::toSettings + Export the TitleBlockProperties into a QSettings + @param settings : setting to use + @param prefix : name to use as prefix for this property +*/ void TitleBlockProperties::toSettings(QSettings &settings, const QString &prefix) const { settings.setValue(prefix + "title", title); settings.setValue(prefix + "author", author); @@ -176,9 +176,9 @@ void TitleBlockProperties::fromSettings(QSettings &settings, const QString &pref } /** - * @brief TitleBlockProperties::defaultProperties - * Return the default properties stored in the setting file - */ + @brief TitleBlockProperties::defaultProperties + Return the default properties stored in the setting file +*/ TitleBlockProperties TitleBlockProperties::defaultProperties() { QSettings settings; diff --git a/sources/titleblocktemplate.h b/sources/titleblocktemplate.h index c6c5cfb59..2ecc78889 100644 --- a/sources/titleblocktemplate.h +++ b/sources/titleblocktemplate.h @@ -189,7 +189,7 @@ class TitleBlockTemplate : public QObject { QHash vector_logos_; /** @brief bitmap_logos_ : Pixmaps for bitmap logos - */ + */ QHash bitmap_logos_; QList rows_heights_; ///< rows heights -- simple integers @@ -201,7 +201,7 @@ class TitleBlockTemplate : public QObject { /** @brief registered_cells_ : Cells objects created rattached to this template, but not mandatorily used - */ + */ QList registered_cells_; QList< QList > cells_; ///< Cells grid }; diff --git a/sources/titleblocktemplaterenderer.cpp b/sources/titleblocktemplaterenderer.cpp index ebe518957..e1ab13d51 100644 --- a/sources/titleblocktemplaterenderer.cpp +++ b/sources/titleblocktemplaterenderer.cpp @@ -32,7 +32,7 @@ const TitleBlockTemplate *TitleBlockTemplateRenderer::titleBlockTemplate() const /** @brief TitleBlockTemplateRenderer::setTitleBlockTemplate @param titleblock_template : TitleBlock template to render. - */ +*/ void TitleBlockTemplateRenderer::setTitleBlockTemplate( const TitleBlockTemplate *titleblock_template) { if (titleblock_template != m_titleblock_template) { diff --git a/sources/ui/abstractelementpropertieseditorwidget.h b/sources/ui/abstractelementpropertieseditorwidget.h index 3e38f0354..52589e9f2 100644 --- a/sources/ui/abstractelementpropertieseditorwidget.h +++ b/sources/ui/abstractelementpropertieseditorwidget.h @@ -24,9 +24,9 @@ class Element; /** - * @brief The AbstractElementPropertiesEditorWidget class - * This class provide common method for all widget used to edit some properties of an element - */ + @brief The AbstractElementPropertiesEditorWidget class + This class provide common method for all widget used to edit some properties of an element +*/ class AbstractElementPropertiesEditorWidget : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/alignmenttextdialog.cpp b/sources/ui/alignmenttextdialog.cpp index f5980295b..faff36c1f 100644 --- a/sources/ui/alignmenttextdialog.cpp +++ b/sources/ui/alignmenttextdialog.cpp @@ -51,9 +51,9 @@ AlignmentTextDialog::~AlignmentTextDialog() } /** - * @brief AlignmentTextDialog::alignment - * @return the selected alignment - */ + @brief AlignmentTextDialog::alignment + @return the selected alignment +*/ Qt::Alignment AlignmentTextDialog::alignment() const { if(ui->top_left->isChecked()) diff --git a/sources/ui/borderpropertieswidget.cpp b/sources/ui/borderpropertieswidget.cpp index bd83c8ffc..46f27b943 100644 --- a/sources/ui/borderpropertieswidget.cpp +++ b/sources/ui/borderpropertieswidget.cpp @@ -20,11 +20,11 @@ #include "diagram.h" /** - * @brief BorderPropertiesWidget::BorderPropertiesWidget - * default constructor - * @param bp properties - * @param parent paretn widget - */ + @brief BorderPropertiesWidget::BorderPropertiesWidget + default constructor + @param bp properties + @param parent paretn widget +*/ BorderPropertiesWidget::BorderPropertiesWidget(const BorderProperties &bp, QWidget *parent) : QWidget(parent), ui(new Ui::BorderPropertiesWidget) @@ -34,19 +34,19 @@ BorderPropertiesWidget::BorderPropertiesWidget(const BorderProperties &bp, QWidg } /** - * @brief BorderPropertiesWidget::~BorderPropertiesWidget - * default destructor - */ + @brief BorderPropertiesWidget::~BorderPropertiesWidget + default destructor +*/ BorderPropertiesWidget::~BorderPropertiesWidget() { delete ui; } /** - * @brief BorderPropertiesWidget::setProperties - * Set the current properties to edit - * @param bp properties to edit - */ + @brief BorderPropertiesWidget::setProperties + Set the current properties to edit + @param bp properties to edit +*/ void BorderPropertiesWidget::setProperties(const BorderProperties &bp) { m_properties = bp; ui -> m_colums_count_sp ->setValue (m_properties.columns_count); @@ -58,9 +58,9 @@ void BorderPropertiesWidget::setProperties(const BorderProperties &bp) { } /** - * @brief BorderPropertiesWidget::properties - * @return the edited border properties - */ + @brief BorderPropertiesWidget::properties + @return the edited border properties +*/ const BorderProperties &BorderPropertiesWidget::properties () { m_properties.columns_count = ui -> m_colums_count_sp -> value(); m_properties.columns_width = ui -> m_columns_width_sp -> value(); @@ -72,10 +72,10 @@ const BorderProperties &BorderPropertiesWidget::properties () { } /** - * @brief BorderPropertiesWidget::setReadOnly - * Enable or disable this widget - * @param ro true-disable / false-enable - */ + @brief BorderPropertiesWidget::setReadOnly + Enable or disable this widget + @param ro true-disable / false-enable +*/ void BorderPropertiesWidget::setReadOnly(const bool &ro) { ui->border_gb->setDisabled(ro); } diff --git a/sources/ui/borderpropertieswidget.h b/sources/ui/borderpropertieswidget.h index 6b9c973bc..65044ef0e 100644 --- a/sources/ui/borderpropertieswidget.h +++ b/sources/ui/borderpropertieswidget.h @@ -26,9 +26,9 @@ namespace Ui { } /** - * @brief The BorderPropertiesWidget class - * this widget edit the properties of a border - */ + @brief The BorderPropertiesWidget class + this widget edit the properties of a border +*/ class BorderPropertiesWidget : public QWidget { Q_OBJECT diff --git a/sources/ui/compositetexteditdialog.cpp b/sources/ui/compositetexteditdialog.cpp index 5478c8ef3..69d2e1600 100644 --- a/sources/ui/compositetexteditdialog.cpp +++ b/sources/ui/compositetexteditdialog.cpp @@ -35,17 +35,17 @@ CompositeTextEditDialog::~CompositeTextEditDialog() { } /** - * @brief CompositeTextEditDialog::plainText - * @return The edited text - */ + @brief CompositeTextEditDialog::plainText + @return The edited text +*/ QString CompositeTextEditDialog::plainText() const { return ui->m_plain_text_edit->toPlainText(); } /** - * @brief CompositeTextEditDialog::setUpComboBox - * Add the available element information in the combo box - */ + @brief CompositeTextEditDialog::setUpComboBox + Add the available element information in the combo box +*/ void CompositeTextEditDialog::setUpComboBox() { QStringList qstrl; @@ -78,10 +78,10 @@ void CompositeTextEditDialog::on_m_info_cb_activated(const QString &arg1) } /** - * @brief CompositeTextEditDialog::focusInEvent - * Reimplemented from QWidget::focusInEvent - * @param event - */ + @brief CompositeTextEditDialog::focusInEvent + Reimplemented from QWidget::focusInEvent + @param event +*/ void CompositeTextEditDialog::focusInEvent(QFocusEvent *event) { ui->m_plain_text_edit->setFocus(); diff --git a/sources/ui/compositetexteditdialog.h b/sources/ui/compositetexteditdialog.h index 537f3cab6..c2653a65c 100644 --- a/sources/ui/compositetexteditdialog.h +++ b/sources/ui/compositetexteditdialog.h @@ -10,12 +10,12 @@ namespace Ui { class DynamicElementTextItem; /** - * @brief The CompositeTextEditDialog class - * CompositeTextEditDialog display a dialog use to write the complex text - * of a dynamic element text item. - * This dialog provide a QComboBox to quickly add an information of the element - * in the composite text. - */ + @brief The CompositeTextEditDialog class + CompositeTextEditDialog display a dialog use to write the complex text + of a dynamic element text item. + This dialog provide a QComboBox to quickly add an information of the element + in the composite text. +*/ class CompositeTextEditDialog : public QDialog { Q_OBJECT diff --git a/sources/ui/conductorpropertiesdialog.cpp b/sources/ui/conductorpropertiesdialog.cpp index ebc96d4f4..7d51f667a 100644 --- a/sources/ui/conductorpropertiesdialog.cpp +++ b/sources/ui/conductorpropertiesdialog.cpp @@ -24,11 +24,11 @@ #include "QPropertyUndoCommand/qpropertyundocommand.h" /** - * @brief ConductorPropertiesDialog::ConductorPropertiesDialog - * Constructor - * @param conductor, conductor to edit propertie - * @param parent, parent widget - */ + @brief ConductorPropertiesDialog::ConductorPropertiesDialog + Constructor + @param conductor, conductor to edit propertie + @param parent, parent widget +*/ ConductorPropertiesDialog::ConductorPropertiesDialog(Conductor *conductor, QWidget *parent) : QDialog(parent), ui(new Ui::ConductorPropertiesDialog) @@ -45,19 +45,19 @@ ConductorPropertiesDialog::ConductorPropertiesDialog(Conductor *conductor, QWidg } /** - * @brief ConductorPropertiesDialog::~ConductorPropertiesDialog - */ + @brief ConductorPropertiesDialog::~ConductorPropertiesDialog +*/ ConductorPropertiesDialog::~ConductorPropertiesDialog() { delete ui; } /** - * @brief ConductorPropertiesDialog::PropertiesDialog - * Static method for open and apply properties. - * @param conductor, conductor to edit propertie - * @param parent, parent widget - */ + @brief ConductorPropertiesDialog::PropertiesDialog + Static method for open and apply properties. + @param conductor, conductor to edit propertie + @param parent, parent widget +*/ void ConductorPropertiesDialog::PropertiesDialog(Conductor *conductor, QWidget *parent) { ConductorPropertiesDialog cpd (conductor, parent); @@ -86,19 +86,19 @@ void ConductorPropertiesDialog::PropertiesDialog(Conductor *conductor, QWidget * } /** - * @brief ConductorPropertiesDialog::properties - * @return the edited properties - */ + @brief ConductorPropertiesDialog::properties + @return the edited properties +*/ ConductorProperties ConductorPropertiesDialog::properties() const { return m_cpw -> properties(); } /** - * @brief ConductorPropertiesDialog::applyAll - * @return - * true -> must apply the propertie to all conductor at the same potential - * false -> must apply properties only for the edited conductor - */ + @brief ConductorPropertiesDialog::applyAll + @return + true -> must apply the propertie to all conductor at the same potential + false -> must apply properties only for the edited conductor +*/ bool ConductorPropertiesDialog::applyAll() const { return ui -> m_apply_all_cb -> isChecked(); } diff --git a/sources/ui/conductorpropertieswidget.cpp b/sources/ui/conductorpropertieswidget.cpp index 40ca02651..972380af2 100644 --- a/sources/ui/conductorpropertieswidget.cpp +++ b/sources/ui/conductorpropertieswidget.cpp @@ -22,10 +22,10 @@ #include "qtextorientationspinboxwidget.h" /** - * @brief ConductorPropertiesWidget::ConductorPropertiesWidget - * Constructor - * @param parent, paretn widget - */ + @brief ConductorPropertiesWidget::ConductorPropertiesWidget + Constructor + @param parent, paretn widget +*/ ConductorPropertiesWidget::ConductorPropertiesWidget(QWidget *parent) : QWidget(parent), ui(new Ui::ConductorPropertiesWidget) @@ -38,11 +38,11 @@ ConductorPropertiesWidget::ConductorPropertiesWidget(QWidget *parent) : /** - * @brief ConductorPropertiesWidget::ConductorPropertiesWidget - * Constructor with properties - * @param properties, properties to edit - * @param parent, parent widget - */ + @brief ConductorPropertiesWidget::ConductorPropertiesWidget + Constructor with properties + @param properties, properties to edit + @param parent, parent widget +*/ ConductorPropertiesWidget::ConductorPropertiesWidget(const ConductorProperties &properties, QWidget *parent) : QWidget(parent), ui(new Ui::ConductorPropertiesWidget) @@ -53,19 +53,19 @@ ConductorPropertiesWidget::ConductorPropertiesWidget(const ConductorProperties & } /** - * @brief ConductorPropertiesWidget::~ConductorPropertiesWidget - * destructor - */ + @brief ConductorPropertiesWidget::~ConductorPropertiesWidget + destructor +*/ ConductorPropertiesWidget::~ConductorPropertiesWidget() { delete ui; } /** - * @brief ConductorPropertiesWidget::setProperties - * Set the properties - * @param properties - */ + @brief ConductorPropertiesWidget::setProperties + Set the properties + @param properties +*/ void ConductorPropertiesWidget::setProperties(const ConductorProperties &properties) { if (m_properties == properties) @@ -107,9 +107,9 @@ void ConductorPropertiesWidget::setProperties(const ConductorProperties &propert } /** - * @brief ConductorPropertiesWidget::properties - * @return the edited properties - */ + @brief ConductorPropertiesWidget::properties + @return the edited properties +*/ ConductorProperties ConductorPropertiesWidget::properties() const { ConductorProperties properties_; @@ -146,10 +146,10 @@ ConductorProperties ConductorPropertiesWidget::properties() const } /** - * @brief ConductorPropertiesWidget::event - * @param event - * @return - */ + @brief ConductorPropertiesWidget::event + @param event + @return +*/ bool ConductorPropertiesWidget::event(QEvent *event) { if (event->type() == QEvent::WindowActivate) { @@ -160,42 +160,42 @@ bool ConductorPropertiesWidget::event(QEvent *event) /** - * @brief ConductorPropertiesWidget::setReadOnly - * @param ro if true this widget is disabled - */ + @brief ConductorPropertiesWidget::setReadOnly + @param ro if true this widget is disabled +*/ void ConductorPropertiesWidget::setReadOnly(const bool &ro) { this->setDisabled(ro); } /** - * @brief ConductorPropertiesWidget::addAutonumWidget - * @param widget - */ + @brief ConductorPropertiesWidget::addAutonumWidget + @param widget +*/ void ConductorPropertiesWidget::addAutonumWidget(QWidget *widget) { ui->m_autonum_layout->addWidget(widget); } /** - * @brief ConductorPropertiesWidget::setHiddenOneTextPerFolio - * @param hide - */ + @brief ConductorPropertiesWidget::setHiddenOneTextPerFolio + @param hide +*/ void ConductorPropertiesWidget::setHiddenOneTextPerFolio(const bool &hide) { ui -> m_one_text_per_folio_cb -> setHidden(hide); } /** - * @brief ConductorPropertiesWidget::setDisabledShowText - * @param disable - */ + @brief ConductorPropertiesWidget::setDisabledShowText + @param disable +*/ void ConductorPropertiesWidget::setDisabledShowText(const bool &disable) { ui->m_show_text_cb->setDisabled(disable==true? true : false); } /** - * @brief ConductorPropertiesWidget::setHiddenAvailableAutonum - * Hide the label, combo box and push button of available autonum - * @param hide - */ + @brief ConductorPropertiesWidget::setHiddenAvailableAutonum + Hide the label, combo box and push button of available autonum + @param hide +*/ void ConductorPropertiesWidget::setHiddenAvailableAutonum(const bool &hide) { ui->m_autonum_label->setHidden(hide); @@ -214,8 +214,8 @@ QPushButton *ConductorPropertiesWidget::editAutonumPushButton() const } /** - * @brief ConductorPropertiesWidget::initWidget - */ + @brief ConductorPropertiesWidget::initWidget +*/ void ConductorPropertiesWidget::initWidget() { m_verti_select = QETApp::createTextOrientationSpinBoxWidget(); ui -> m_text_angle_gl -> addWidget(m_verti_select, 2, 0, Qt::AlignHCenter); @@ -236,10 +236,10 @@ void ConductorPropertiesWidget::initWidget() { } /** - * @brief ConductorPropertiesWidget::setConductorType - * Update this widget to the new conductor type - * @param type - */ + @brief ConductorPropertiesWidget::setConductorType + Update this widget to the new conductor type + @param type +*/ void ConductorPropertiesWidget::setConductorType(ConductorProperties::ConductorType type) { switch (type) { case ConductorProperties::Multi: @@ -255,11 +255,11 @@ void ConductorPropertiesWidget::setConductorType(ConductorProperties::ConductorT } /** - * @brief ConductorPropertiesWidget::updatePreview - * Update the preview for single lien - * @param b true: update from the value displayed by this widget - * false: update from the properties given at the constructor of this widget - */ + @brief ConductorPropertiesWidget::updatePreview + Update the preview for single lien + @param b true: update from the value displayed by this widget + false: update from the properties given at the constructor of this widget +*/ void ConductorPropertiesWidget::updatePreview(bool b) { const QRect pixmap_rect(0, 0, 96, 96); QPixmap pixmap(pixmap_rect.width(), pixmap_rect.height()); @@ -277,10 +277,10 @@ void ConductorPropertiesWidget::updatePreview(bool b) { } /** - * @brief ConductorPropertiesWidget::on_m_earth_cb_toggled - * Update the widget when toggled - * @param checked - */ + @brief ConductorPropertiesWidget::on_m_earth_cb_toggled + Update the widget when toggled + @param checked +*/ void ConductorPropertiesWidget::on_m_earth_cb_toggled(bool checked) { if (checked && ui -> m_neutral_cb -> isChecked()) ui -> m_pen_cb -> setEnabled(true); @@ -288,10 +288,10 @@ void ConductorPropertiesWidget::on_m_earth_cb_toggled(bool checked) { } /** - * @brief ConductorPropertiesWidget::on_m_neutral_cb_toggled - * Update the widget when toggled - * @param checked - */ + @brief ConductorPropertiesWidget::on_m_neutral_cb_toggled + Update the widget when toggled + @param checked +*/ void ConductorPropertiesWidget::on_m_neutral_cb_toggled(bool checked) { if (checked && ui -> m_earth_cb -> isChecked()) ui -> m_pen_cb -> setEnabled(true); @@ -299,12 +299,12 @@ void ConductorPropertiesWidget::on_m_neutral_cb_toggled(bool checked) { } /** - * @brief ConductorPropertiesWidget::on_m_update_preview_pb_clicked - * Update the preview of single line. - * m_update_preview_pb is a no used button and hidden, his role is only - * to centralize signal from various widget to edit single ligne properties, - * for update the preview - */ + @brief ConductorPropertiesWidget::on_m_update_preview_pb_clicked + Update the preview of single line. + m_update_preview_pb is a no used button and hidden, his role is only + to centralize signal from various widget to edit single ligne properties, + for update the preview +*/ void ConductorPropertiesWidget::on_m_update_preview_pb_clicked() { updatePreview(); } diff --git a/sources/ui/configpage/generalconfigurationpage.cpp b/sources/ui/configpage/generalconfigurationpage.cpp index cfe3b6432..1d1f85c10 100644 --- a/sources/ui/configpage/generalconfigurationpage.cpp +++ b/sources/ui/configpage/generalconfigurationpage.cpp @@ -25,9 +25,9 @@ #include /** - * @brief GeneralConfigurationPage::GeneralConfigurationPage - * @param parent - */ + @brief GeneralConfigurationPage::GeneralConfigurationPage + @param parent +*/ GeneralConfigurationPage::GeneralConfigurationPage(QWidget *parent) : ConfigPage(parent), ui(new Ui::GeneralConfigurationPage) @@ -131,9 +131,9 @@ GeneralConfigurationPage::~GeneralConfigurationPage() } /** - * @brief GeneralConfigurationPage::applyConf - * Write all configuration in settings file - */ + @brief GeneralConfigurationPage::applyConf + Write all configuration in settings file +*/ void GeneralConfigurationPage::applyConf() { QSettings settings; @@ -231,25 +231,25 @@ void GeneralConfigurationPage::applyConf() } /** - * @brief GeneralConfigurationPage::title - * @return The title of this page - */ + @brief GeneralConfigurationPage::title + @return The title of this page +*/ QString GeneralConfigurationPage::title() const { return(tr("Général", "configuration page title")); } /** - * @brief GeneralConfigurationPage::icon - * @return The icon of this page - */ + @brief GeneralConfigurationPage::icon + @return The icon of this page +*/ QIcon GeneralConfigurationPage::icon() const { return(QET::Icons::Settings); } /** - * @brief GeneralConfigurationPage::fillLang - * fill all available lang - */ + @brief GeneralConfigurationPage::fillLang + fill all available lang +*/ void GeneralConfigurationPage::fillLang() { ui->m_lang_cb->addItem(QET::Icons::translation, tr("Système"), "system"); @@ -295,9 +295,9 @@ void GeneralConfigurationPage::fillLang() } /** - * @brief GeneralConfigurationPage::on_m_font_pb_clicked - * Apply font to config - */ + @brief GeneralConfigurationPage::on_m_font_pb_clicked + Apply font to config +*/ void GeneralConfigurationPage::on_m_font_pb_clicked() { bool ok; @@ -317,9 +317,9 @@ void GeneralConfigurationPage::on_m_font_pb_clicked() } /** - * @brief GeneralConfigurationPage::m_dyn_text_font_pb_clicked - * Apply font to config - */ + @brief GeneralConfigurationPage::m_dyn_text_font_pb_clicked + Apply font to config +*/ void GeneralConfigurationPage::on_m_dyn_text_font_pb_clicked() { bool ok; diff --git a/sources/ui/configsaveloaderwidget.h b/sources/ui/configsaveloaderwidget.h index 92a65bdf4..7209d9db5 100644 --- a/sources/ui/configsaveloaderwidget.h +++ b/sources/ui/configsaveloaderwidget.h @@ -25,13 +25,13 @@ class ConfigSaveLoaderWidget; } /** - * @brief The ConfigSaveLoaderWidget class - * This group box provide 4 widget: - * A combo box with the available config. - * A push button to load the selected config of combo box - * A line edit to edit the text of the config to save - * A push button to save the config - */ + @brief The ConfigSaveLoaderWidget class + This group box provide 4 widget: + A combo box with the available config. + A push button to load the selected config of combo box + A line edit to edit the text of the config to save + A push button to save the config +*/ class ConfigSaveLoaderWidget : public QGroupBox { Q_OBJECT diff --git a/sources/ui/diagramcontextwidget.cpp b/sources/ui/diagramcontextwidget.cpp index a33126f9a..7b6117a46 100644 --- a/sources/ui/diagramcontextwidget.cpp +++ b/sources/ui/diagramcontextwidget.cpp @@ -32,9 +32,9 @@ DiagramContextWidget::~DiagramContextWidget() } /** - * @brief DiagramContextWidget::context - * @return The diagram context object edited by this widget - */ + @brief DiagramContextWidget::context + @return The diagram context object edited by this widget +*/ DiagramContext DiagramContextWidget::context() const { DiagramContext context; @@ -60,10 +60,10 @@ DiagramContext DiagramContextWidget::context() const } /** - * @brief DiagramContextWidget::setContext - * Load the content from @context into this widget - * @param context - */ + @brief DiagramContextWidget::setContext + Load the content from @context into this widget + @param context +*/ void DiagramContextWidget::setContext (const DiagramContext &context) { clear(); @@ -80,9 +80,9 @@ void DiagramContextWidget::setContext (const DiagramContext &context) } /** - * @brief DiagramContextWidget::nameLessRowsCount - * @return The count of name-less rows in the table - */ + @brief DiagramContextWidget::nameLessRowsCount + @return The count of name-less rows in the table +*/ int DiagramContextWidget::nameLessRowsCount() const { int name_less_rows_count = 0; @@ -98,9 +98,9 @@ int DiagramContextWidget::nameLessRowsCount() const } /** - * @brief DiagramContextWidget::clear - * Clear any values entered within this widget - */ + @brief DiagramContextWidget::clear + Clear any values entered within this widget +*/ void DiagramContextWidget::clear() { ui->m_table->clearContents(); @@ -112,10 +112,10 @@ void DiagramContextWidget::clear() } /** - * @brief DiagramContextWidget::highlightNonAcceptableKeys - * Highlight keys that would not be accepted by a DiagramContext object. - * @return the number of highlighted keys. - */ + @brief DiagramContextWidget::highlightNonAcceptableKeys + Highlight keys that would not be accepted by a DiagramContext object. + @return the number of highlighted keys. +*/ int DiagramContextWidget::highlightNonAcceptableKeys() { static QRegExp re(DiagramContext::validKeyRegExp()); @@ -146,10 +146,10 @@ int DiagramContextWidget::highlightNonAcceptableKeys() } /** - * @brief DiagramContextWidget::refreshFormatLabel - * Sets the text describing the acceptable format for keys when adding extra - * key/value pairs. - */ + @brief DiagramContextWidget::refreshFormatLabel + Sets the text describing the acceptable format for keys when adding extra + key/value pairs. +*/ void DiagramContextWidget::refreshFormatLabel() { QString format_text = tr( @@ -164,9 +164,9 @@ void DiagramContextWidget::refreshFormatLabel() } /** - * @brief DiagramContextWidget::checkTableRows - * Adds a row in the additional fields table if needed - */ + @brief DiagramContextWidget::checkTableRows + Adds a row in the additional fields table if needed +*/ void DiagramContextWidget::checkTableRows() { refreshFormatLabel(); diff --git a/sources/ui/diagrampropertiesdialog.cpp b/sources/ui/diagrampropertiesdialog.cpp index b7e2752ba..5b1f4cbb6 100644 --- a/sources/ui/diagrampropertiesdialog.cpp +++ b/sources/ui/diagrampropertiesdialog.cpp @@ -25,11 +25,11 @@ #include "changetitleblockcommand.h" /** - * @brief DiagramPropertiesDialog::DiagramPropertiesDialog - * Deafult constructor - * @param diagram : diagram to edit properties - * @param parent : parent widget - */ + @brief DiagramPropertiesDialog::DiagramPropertiesDialog + Deafult constructor + @param diagram : diagram to edit properties + @param parent : parent widget +*/ DiagramPropertiesDialog::DiagramPropertiesDialog(Diagram *diagram, QWidget *parent) : QDialog (parent), m_diagram (diagram) @@ -121,19 +121,19 @@ DiagramPropertiesDialog::DiagramPropertiesDialog(Diagram *diagram, QWidget *pare } /** - * @brief DiagramPropertiesDialog::diagramPropertiesDialog - * Static method to get a DiagramPropertiesDialog. - * @param diagram : diagram to edit properties - * @param parent : parent widget - */ + @brief DiagramPropertiesDialog::diagramPropertiesDialog + Static method to get a DiagramPropertiesDialog. + @param diagram : diagram to edit properties + @param parent : parent widget +*/ void DiagramPropertiesDialog::diagramPropertiesDialog(Diagram *diagram, QWidget *parent) { DiagramPropertiesDialog dialog(diagram, parent); } /** - * @brief DiagramPropertiesDialog::editAutonum - * Open conductor autonum editor - */ + @brief DiagramPropertiesDialog::editAutonum + Open conductor autonum editor +*/ void DiagramPropertiesDialog::editAutonum() { ProjectPropertiesDialog ppd (m_diagram->project(), this); @@ -144,9 +144,9 @@ void DiagramPropertiesDialog::editAutonum() } /** - * @brief DiagramPropertiesDialog::editAutonum - * Open folio autonum editor - */ + @brief DiagramPropertiesDialog::editAutonum + Open folio autonum editor +*/ void DiagramPropertiesDialog::editAutoFolioNum () { ProjectPropertiesDialog ppd (m_diagram->project(), this); ppd.setCurrentPage(ProjectPropertiesDialog::Autonum); diff --git a/sources/ui/diagrampropertiesdialog.h b/sources/ui/diagrampropertiesdialog.h index 9eb31f8f1..85dab08d4 100644 --- a/sources/ui/diagrampropertiesdialog.h +++ b/sources/ui/diagrampropertiesdialog.h @@ -24,9 +24,9 @@ class Diagram; class ConductorPropertiesWidget; /** - * @brief The DiagramPropertiesDialog class - * This dialog open a windows for edit properties of a diagram. - */ + @brief The DiagramPropertiesDialog class + This dialog open a windows for edit properties of a diagram. +*/ class DiagramPropertiesDialog : public QDialog { Q_OBJECT diff --git a/sources/ui/diagrampropertieseditordockwidget.cpp b/sources/ui/diagrampropertieseditordockwidget.cpp index a97e5257f..7e62c4974 100644 --- a/sources/ui/diagrampropertieseditordockwidget.cpp +++ b/sources/ui/diagrampropertieseditordockwidget.cpp @@ -21,10 +21,10 @@ #include "propertieseditorfactory.h" /** - * @brief DiagramPropertiesEditorDockWidget::DiagramPropertiesEditorDockWidget - * Constructor - * @param parent : parent widget - */ + @brief DiagramPropertiesEditorDockWidget::DiagramPropertiesEditorDockWidget + Constructor + @param parent : parent widget +*/ DiagramPropertiesEditorDockWidget::DiagramPropertiesEditorDockWidget(QWidget *parent) : PropertiesEditorDockWidget(parent), m_diagram(nullptr), @@ -32,13 +32,13 @@ DiagramPropertiesEditorDockWidget::DiagramPropertiesEditorDockWidget(QWidget *pa {} /** - * @brief DiagramPropertiesEditorDockWidget::setDiagram - * Set the diagram to edit the selection. - * Connect the diagram signal selectionChanged() to this slot selectionChanged(); - * If diagram = nullptr, we just disconnect all signal and remove editor. - * @param diagram - * @param diagram - */ + @brief DiagramPropertiesEditorDockWidget::setDiagram + Set the diagram to edit the selection. + Connect the diagram signal selectionChanged() to this slot selectionChanged(); + If diagram = nullptr, we just disconnect all signal and remove editor. + @param diagram + @param diagram +*/ void DiagramPropertiesEditorDockWidget::setDiagram(Diagram *diagram) { if (m_diagram == diagram) return; @@ -65,10 +65,10 @@ void DiagramPropertiesEditorDockWidget::setDiagram(Diagram *diagram) } /** - * @brief DiagramPropertiesEditorDockWidget::selectionChanged - * The current selection of diagram was changed. - * We fill the dock with the appropriate ElementPropertiesWidget of the current selection. - */ + @brief DiagramPropertiesEditorDockWidget::selectionChanged + The current selection of diagram was changed. + We fill the dock with the appropriate ElementPropertiesWidget of the current selection. +*/ void DiagramPropertiesEditorDockWidget::selectionChanged() { if (!m_diagram) { @@ -92,9 +92,9 @@ void DiagramPropertiesEditorDockWidget::selectionChanged() } /** - * @brief DiagramPropertiesEditorDockWidget::diagramWasDeleted - * Remove current editor and set m_diagram to nullptr. - */ + @brief DiagramPropertiesEditorDockWidget::diagramWasDeleted + Remove current editor and set m_diagram to nullptr. +*/ void DiagramPropertiesEditorDockWidget::diagramWasDeleted() { m_diagram = nullptr; diff --git a/sources/ui/diagramselection.cpp b/sources/ui/diagramselection.cpp index 9104da7da..72be98369 100644 --- a/sources/ui/diagramselection.cpp +++ b/sources/ui/diagramselection.cpp @@ -38,8 +38,8 @@ diagramselection::~diagramselection() { } /** - * @brief load all Diagrams of project in table - */ + @brief load all Diagrams of project in table +*/ void diagramselection::load_TableDiagram() { // Clear all items ui -> tableDiagram -> clear(); @@ -80,9 +80,9 @@ void diagramselection::load_TableDiagram() { } /** - * @brief get list of Diagrams is selected - * @return this list of Diagrams - */ + @brief get list of Diagrams is selected + @return this list of Diagrams +*/ QList diagramselection::list_of_DiagramSelected() { QList listDiag; for(int i=0; i tableDiagram -> rowCount();i++){ @@ -94,9 +94,9 @@ QList diagramselection::list_of_DiagramSelected() { } /** - * @brief contextMenuRequested - * @param pos - */ + @brief contextMenuRequested + @param pos +*/ void diagramselection::on_tableDiagram_customContextMenuRequested(const QPoint &pos){ QMenu menu(this); QAction *desl = menu.addAction( tr("Désélectionner tout") ); diff --git a/sources/ui/dialogwaiting.cpp b/sources/ui/dialogwaiting.cpp index 0f11071eb..8b00c1333 100644 --- a/sources/ui/dialogwaiting.cpp +++ b/sources/ui/dialogwaiting.cpp @@ -23,9 +23,9 @@ DialogWaiting *DialogWaiting::m_static_dialog = nullptr; /** - * @brief DialogWaiting::DialogWaiting - * @param parent - */ + @brief DialogWaiting::DialogWaiting + @param parent +*/ DialogWaiting::DialogWaiting(QWidget *parent) : QDialog(parent), ui(new Ui::DialogWaiting) @@ -36,58 +36,58 @@ DialogWaiting::DialogWaiting(QWidget *parent) : } /** - * @brief DialogWaiting::~DialogWaiting - */ + @brief DialogWaiting::~DialogWaiting +*/ DialogWaiting::~DialogWaiting() { delete ui; } /** - * @brief DialogWaiting::setProgressBar - * @param val is the progressBar value - */ + @brief DialogWaiting::setProgressBar + @param val is the progressBar value +*/ void DialogWaiting::setProgressBar(int val){ ui->progressBar->setValue(val); qApp->processEvents(); } /** - * @brief DialogWaiting::setProgressReset, clear progressBar and reset - */ + @brief DialogWaiting::setProgressReset, clear progressBar and reset +*/ void DialogWaiting::setProgressReset(){ ui->progressBar->reset(); } /** - * @brief DialogWaiting::setProgressBarRange - * @param min is the minimum of progressBar - * @param max is the maximun of progressBar - */ + @brief DialogWaiting::setProgressBarRange + @param min is the minimum of progressBar + @param max is the maximun of progressBar +*/ void DialogWaiting::setProgressBarRange(int min, int max){ ui->progressBar->setRange(min,max); ui->progressBar->setFormat(QObject::tr("%p% effectué (%v sur %m)")); } /** - * @brief DialogWaiting::setTitle of action - * @param val is the string of action - */ + @brief DialogWaiting::setTitle of action + @param val is the string of action +*/ void DialogWaiting::setTitle(const QString& val){ ui->labelTitle->setText(val); } /** - * @brief DialogWaiting::setDetail of action - * @param val is the string of detail action - */ + @brief DialogWaiting::setDetail of action + @param val is the string of detail action +*/ void DialogWaiting::setDetail(const QString& val){ ui->label_detail->setText(val); } /** - * @brief DialogWaiting::progressBarValue - * @return The current vcalue of the progress bar - */ + @brief DialogWaiting::progressBarValue + @return The current vcalue of the progress bar +*/ int DialogWaiting::progressBarValue() const { return ui->progressBar->value(); diff --git a/sources/ui/dynamicelementtextitemeditor.cpp b/sources/ui/dynamicelementtextitemeditor.cpp index 32799a9c0..b61df0243 100644 --- a/sources/ui/dynamicelementtextitemeditor.cpp +++ b/sources/ui/dynamicelementtextitemeditor.cpp @@ -135,10 +135,10 @@ void DynamicElementTextItemEditor::apply() } /** - * @brief DynamicElementTextItemEditor::setCurrentText - * Expand and select the item for text @text - * @param text - */ + @brief DynamicElementTextItemEditor::setCurrentText + Expand and select the item for text @text + @param text +*/ void DynamicElementTextItemEditor::setCurrentText(DynamicElementTextItem *text) { QModelIndex index = m_model->indexFromText(text); @@ -152,10 +152,10 @@ void DynamicElementTextItemEditor::setCurrentText(DynamicElementTextItem *text) } /** - * @brief DynamicElementTextItemEditor::setCurrentGroup - * Expand and select the item for group @group - * @param group - */ + @brief DynamicElementTextItemEditor::setCurrentGroup + Expand and select the item for group @group + @param group +*/ void DynamicElementTextItemEditor::setCurrentGroup(ElementTextItemGroup *group) { QModelIndex index = m_model->indexFromGroup(group); @@ -193,9 +193,9 @@ void DynamicElementTextItemEditor::dataEdited() } /** - * @brief DynamicElementTextItemEditor::on_m_add_text_clicked - * Add a new dynamic text - */ + @brief DynamicElementTextItemEditor::on_m_add_text_clicked + Add a new dynamic text +*/ void DynamicElementTextItemEditor::on_m_add_text_clicked() { if (!m_element) @@ -214,9 +214,9 @@ void DynamicElementTextItemEditor::on_m_add_text_clicked() } /** - * @brief DynamicElementTextItemEditor::on_m_remove_selection_clicked - * Remove the selected item - */ + @brief DynamicElementTextItemEditor::on_m_remove_selection_clicked + Remove the selected item +*/ void DynamicElementTextItemEditor::on_m_remove_selection_clicked() { DynamicElementTextItem *deti = m_model->textFromIndex(ui->m_tree_view->currentIndex()); @@ -236,9 +236,9 @@ void DynamicElementTextItemEditor::on_m_remove_selection_clicked() } /** - * @brief DynamicElementTextItemEditor::on_m_add_group_clicked - * Add a new group - */ + @brief DynamicElementTextItemEditor::on_m_add_group_clicked + Add a new group +*/ void DynamicElementTextItemEditor::on_m_add_group_clicked() { QString name = QInputDialog::getText(this, tr("Nom du groupe"), tr("Entrer le nom du nouveau groupe")); diff --git a/sources/ui/dynamicelementtextitemeditor.h b/sources/ui/dynamicelementtextitemeditor.h index c383865cc..02fe4390c 100644 --- a/sources/ui/dynamicelementtextitemeditor.h +++ b/sources/ui/dynamicelementtextitemeditor.h @@ -31,14 +31,16 @@ namespace Ui { class DynamicElementTextItemEditor : public AbstractElementPropertiesEditorWidget { - Q_OBJECT - + Q_OBJECT + public: - explicit DynamicElementTextItemEditor(Element *element, QWidget *parent = nullptr); + explicit DynamicElementTextItemEditor( + Element *element, + QWidget *parent = nullptr); ~DynamicElementTextItemEditor() override; void setElement(Element *element) override; - QString title() const override {return tr("Textes");} + QString title() const override {return tr("Textes");} bool setLiveEdit(bool live_edit) override; void apply() override; void setCurrentText(DynamicElementTextItem *text); @@ -47,18 +49,18 @@ class DynamicElementTextItemEditor : public AbstractElementPropertiesEditorWidge private: void dataEdited(); - - private slots: - void on_m_add_text_clicked(); - void on_m_remove_selection_clicked(); + + private slots: + void on_m_add_text_clicked(); + void on_m_remove_selection_clicked(); void on_m_add_group_clicked(); void on_m_tree_view_clicked(const QModelIndex &index); void on_m_export_pb_clicked(); void on_m_import_pb_clicked(); - private: + private: Ui::DynamicElementTextItemEditor *ui; - DynamicElementTextModel *m_model = nullptr; + DynamicElementTextModel *m_model = nullptr; }; #endif // DYNAMICELEMENTTEXTITEMEDITOR_H diff --git a/sources/ui/dynamicelementtextmodel.cpp b/sources/ui/dynamicelementtextmodel.cpp index fc9709d9e..935a33560 100644 --- a/sources/ui/dynamicelementtextmodel.cpp +++ b/sources/ui/dynamicelementtextmodel.cpp @@ -92,10 +92,10 @@ DynamicElementTextModel::~DynamicElementTextModel() } /** - * @brief DynamicElementTextModel::indexIsInGroup - * @param index - * @return True if the index represent a group or an item in a group - */ + @brief DynamicElementTextModel::indexIsInGroup + @param index + @return True if the index represent a group or an item in a group +*/ bool DynamicElementTextModel::indexIsInGroup(const QModelIndex &index) const { QStandardItem *item = itemFromIndex(index); @@ -113,12 +113,12 @@ bool DynamicElementTextModel::indexIsInGroup(const QModelIndex &index) const } /** - * @brief DynamicElementTextModel::itemsForText - * @param deti - * @return The items for the text @deti, if the text @deti is already managed by this model - * the returned list is empty - * The returned items haven't got the same number of childs if the text is in a group or not. - */ + @brief DynamicElementTextModel::itemsForText + @param deti + @return The items for the text @deti, if the text @deti is already managed by this model + the returned list is empty + The returned items haven't got the same number of childs if the text is in a group or not. +*/ QList DynamicElementTextModel::itemsForText(DynamicElementTextItem *deti) { QList qsi_list; @@ -328,18 +328,18 @@ QList DynamicElementTextModel::itemsForText(DynamicElementTextI } /** - * @brief DynamicElementTextModel::addText - * @param deti - */ + @brief DynamicElementTextModel::addText + @param deti +*/ void DynamicElementTextModel::addText(DynamicElementTextItem *deti) { this->appendRow(itemsForText(deti)); } /** - * @brief DynamicElementTextModel::removeText - * @param deti - */ + @brief DynamicElementTextModel::removeText + @param deti +*/ void DynamicElementTextModel::removeText(DynamicElementTextItem *deti) { if (!m_texts_list.contains(deti)) @@ -352,11 +352,11 @@ void DynamicElementTextModel::removeText(DynamicElementTextItem *deti) } /** - * @brief DynamicElementTextModel::textFromIndex - * @param index - * @return the text associated with @index. Returned value can be nullptr - * @Index can be a child of an index associated with a text and can be the column 0 or 1. - */ + @brief DynamicElementTextModel::textFromIndex + @param index + @return the text associated with @index. Returned value can be nullptr + @Index can be a child of an index associated with a text and can be the column 0 or 1. +*/ DynamicElementTextItem *DynamicElementTextModel::textFromIndex(const QModelIndex &index) const { if(!index.isValid()) @@ -369,12 +369,12 @@ DynamicElementTextItem *DynamicElementTextModel::textFromIndex(const QModelIndex } /** - * @brief DynamicElementTextModel::textFromItem - * @param item - * @return the text associated with @item. Return value can be nullptr - * @item can be a child of an item associated with a text and can be the column 0 or 1. - * Note can return nullptr - */ + @brief DynamicElementTextModel::textFromItem + @param item + @return the text associated with @item. Return value can be nullptr + @item can be a child of an item associated with a text and can be the column 0 or 1. + Note can return nullptr +*/ DynamicElementTextItem *DynamicElementTextModel::textFromItem(QStandardItem *item) const { //Get the item of the column 0 @@ -424,10 +424,10 @@ DynamicElementTextItem *DynamicElementTextModel::textFromItem(QStandardItem *ite } /** - * @brief DynamicElementTextModel::indexFromText - * @param text - * @return the QModelIndex for @text, or a default QModelIndex if not match - */ + @brief DynamicElementTextModel::indexFromText + @param text + @return the QModelIndex for @text, or a default QModelIndex if not match +*/ QModelIndex DynamicElementTextModel::indexFromText(DynamicElementTextItem *text) const { if(m_texts_list.contains(text)) @@ -437,12 +437,12 @@ QModelIndex DynamicElementTextModel::indexFromText(DynamicElementTextItem *text) } /** - * @brief DynamicElementTextModel::undoForEditedText - * @param deti - * @return A QUndoCommand that describe all changes made for @deti. - * Each change made for @deti is append as a child of the returned QUndoCommand. - * In other word, if the returned QUndoCommand have no child, that mean there is no change. - */ + @brief DynamicElementTextModel::undoForEditedText + @param deti + @return A QUndoCommand that describe all changes made for @deti. + Each change made for @deti is append as a child of the returned QUndoCommand. + In other word, if the returned QUndoCommand have no child, that mean there is no change. +*/ QUndoCommand *DynamicElementTextModel::undoForEditedText(DynamicElementTextItem *deti, QUndoCommand *parent_undo) const { @@ -562,13 +562,13 @@ QUndoCommand *DynamicElementTextModel::undoForEditedText(DynamicElementTextItem } /** - * @brief DynamicElementTextModel::undoForEditedGroup - * @param group - * @param parent_undo - * @return A QUndoCommand that describe all changes made for @group. - * Each change made for @group is append as a child of the returned QUndoCommand. - * In other word, if the returned QUndoCommand have no child, that mean there is no change. - */ + @brief DynamicElementTextModel::undoForEditedGroup + @param group + @param parent_undo + @return A QUndoCommand that describe all changes made for @group. + Each change made for @group is append as a child of the returned QUndoCommand. + In other word, if the returned QUndoCommand have no child, that mean there is no change. +*/ QUndoCommand *DynamicElementTextModel::undoForEditedGroup(ElementTextItemGroup *group, QUndoCommand *parent_undo) const { QUndoCommand *undo = nullptr; @@ -629,10 +629,10 @@ QUndoCommand *DynamicElementTextModel::undoForEditedGroup(ElementTextItemGroup * } /** - * @brief DynamicElementTextModel::AddGroup - * Add a text item group to this model - * @param group - */ + @brief DynamicElementTextModel::AddGroup + Add a text item group to this model + @param group +*/ void DynamicElementTextModel::addGroup(ElementTextItemGroup *group) { if(m_groups_list.keys().contains(group)) @@ -759,10 +759,10 @@ void DynamicElementTextModel::addGroup(ElementTextItemGroup *group) } /** - * @brief DynamicElementTextModel::removeGroup - * Remove the text item group from this model - * @param group - */ + @brief DynamicElementTextModel::removeGroup + Remove the text item group from this model + @param group +*/ void DynamicElementTextModel::removeGroup(ElementTextItemGroup *group) { if(m_groups_list.keys().contains(group)) @@ -775,11 +775,11 @@ void DynamicElementTextModel::removeGroup(ElementTextItemGroup *group) } /** - * @brief DynamicElementTextModel::textAddedToGroup - * Add the text @text to the group @group - * @param deti - * @param group - */ + @brief DynamicElementTextModel::textAddedToGroup + Add the text @text to the group @group + @param deti + @param group +*/ void DynamicElementTextModel::addTextToGroup(DynamicElementTextItem *deti, ElementTextItemGroup *group) { QStandardItem *group_item = m_groups_list.value(group); @@ -800,11 +800,11 @@ void DynamicElementTextModel::removeTextFromGroup(DynamicElementTextItem *deti, } /** - * @brief DynamicElementTextModel::groupFromIndex - * @param index - * @return the group associated with @index. Return value can be nullptr - * @Index can be a child of an index associated with a group and can be the column 0 or 1. - */ + @brief DynamicElementTextModel::groupFromIndex + @param index + @return the group associated with @index. Return value can be nullptr + @Index can be a child of an index associated with a group and can be the column 0 or 1. +*/ ElementTextItemGroup *DynamicElementTextModel::groupFromIndex(const QModelIndex &index) const { if(!index.isValid()) @@ -817,11 +817,11 @@ ElementTextItemGroup *DynamicElementTextModel::groupFromIndex(const QModelIndex } /** - * @brief DynamicElementTextModel::groupFromItem - * @param item - * @return the group associated with @item. Return value can be nullptr - * @item can be a child of an item associated with a group and can be the column 0 or 1. - */ + @brief DynamicElementTextModel::groupFromItem + @param item + @return the group associated with @item. Return value can be nullptr + @item can be a child of an item associated with a group and can be the column 0 or 1. +*/ ElementTextItemGroup *DynamicElementTextModel::groupFromItem(QStandardItem *item) const { //Get the item of the column 0 @@ -843,11 +843,11 @@ ElementTextItemGroup *DynamicElementTextModel::groupFromItem(QStandardItem *item } /** - * @brief DynamicElementTextModel::indexFromGroup - * @param group - * @return The index associated to the group @group - * or a default QModelIndex if not match - */ + @brief DynamicElementTextModel::indexFromGroup + @param group + @return The index associated to the group @group + or a default QModelIndex if not match +*/ QModelIndex DynamicElementTextModel::indexFromGroup(ElementTextItemGroup *group) const { if(m_groups_list.keys().contains(group)) @@ -857,11 +857,11 @@ QModelIndex DynamicElementTextModel::indexFromGroup(ElementTextItemGroup *group) } /** - * @brief DynamicElementTextModel::indexIsText - * @param index - * @return True if @index represente a text, both for the column 0 and 1. - * Return false if @index is a child of an index associated to a text. - */ + @brief DynamicElementTextModel::indexIsText + @param index + @return True if @index represente a text, both for the column 0 and 1. + Return false if @index is a child of an index associated to a text. +*/ bool DynamicElementTextModel::indexIsText(const QModelIndex &index) const { QStandardItem *item = nullptr; @@ -884,11 +884,11 @@ bool DynamicElementTextModel::indexIsText(const QModelIndex &index) const } /** - * @brief DynamicElementTextModel::indexIsGroup - * @param index - * @return True if @index represente a group, both for the column 0 and 1. - * Return false if @index is a child of an index associated to a group. - */ + @brief DynamicElementTextModel::indexIsGroup + @param index + @return True if @index represente a group, both for the column 0 and 1. + Return false if @index is a child of an index associated to a group. +*/ bool DynamicElementTextModel::indexIsGroup(const QModelIndex &index) const { QStandardItem *item = nullptr; @@ -957,14 +957,14 @@ bool DynamicElementTextModel::canDropMimeData(const QMimeData *data, Qt::DropAct } /** - * @brief DynamicElementTextModel::dropMimeData - * @param data - * @param action - * @param row - * @param column - * @param parent - * @return In any case return false, for overwrite the default behavior of model. - */ + @brief DynamicElementTextModel::dropMimeData + @param data + @param action + @param row + @param column + @param parent + @return In any case return false, for overwrite the default behavior of model. +*/ bool DynamicElementTextModel::dropMimeData(const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) { Q_UNUSED(action) @@ -1081,9 +1081,9 @@ QMimeData *DynamicElementTextModel::mimeData(const QModelIndexList &indexes) con } /** - * @brief DynamicElementTextModel::mimeTypes - * @return - */ + @brief DynamicElementTextModel::mimeTypes + @return +*/ QStringList DynamicElementTextModel::mimeTypes() const { QStringList mime_list = QAbstractItemModel::mimeTypes(); @@ -1092,11 +1092,11 @@ QStringList DynamicElementTextModel::mimeTypes() const } /** - * @brief DynamicElementTextModel::enableSourceText - * Enable the good field, according to the current source of text, for the edited text @deti - * @param deti - * @param tf - */ + @brief DynamicElementTextModel::enableSourceText + Enable the good field, according to the current source of text, for the edited text @deti + @param deti + @param tf +*/ void DynamicElementTextModel::enableSourceText(DynamicElementTextItem *deti, DynamicElementTextItem::TextFrom tf) { if (!m_texts_list.contains(deti)) @@ -1124,10 +1124,10 @@ void DynamicElementTextModel::enableSourceText(DynamicElementTextItem *deti, Dyn } /** - * @brief DynamicElementTextModel::enableGroupRotation - * Enable/disable the item "group rotation" according the option hold to bottom - * @param group - */ + @brief DynamicElementTextModel::enableGroupRotation + Enable/disable the item "group rotation" according the option hold to bottom + @param group +*/ void DynamicElementTextModel::enableGroupRotationAndPos(ElementTextItemGroup *group) { if(!m_groups_list.contains(group)) @@ -1218,12 +1218,12 @@ void DynamicElementTextModel::itemDataChanged(QStandardItem *qsi) } /** - * @brief DynamicElementTextModel::setConnection - * Set up the connection for @deti to keep up to date the data of this model and the text. - * Is notably use with the use of QUndoCommand. - * @param deti - text to setup connection - * @param set - true = set connection - false unset connection - */ + @brief DynamicElementTextModel::setConnection + Set up the connection for @deti to keep up to date the data of this model and the text. + Is notably use with the use of QUndoCommand. + @param deti - text to setup connection + @param set - true = set connection - false unset connection +*/ void DynamicElementTextModel::setConnection(DynamicElementTextItem *deti, bool set) { if(set) @@ -1258,12 +1258,12 @@ void DynamicElementTextModel::setConnection(DynamicElementTextItem *deti, bool s } /** - * @brief DynamicElementTextModel::setConnection - * Set up the connection for @group to keep up to date the data of this model and the group. - * Is notably use with the use of QUndoCommand. - * @param group group to setup the connection - * @param set true = set connection - false unset connection - */ + @brief DynamicElementTextModel::setConnection + Set up the connection for @group to keep up to date the data of this model and the group. + Is notably use with the use of QUndoCommand. + @param group group to setup the connection + @param set true = set connection - false unset connection +*/ void DynamicElementTextModel::setConnection(ElementTextItemGroup *group, bool set) { if(set) @@ -1440,8 +1440,8 @@ void DynamicElementTextModel::updateDataFromGroup(ElementTextItemGroup *group, D /*************************************************** - * A little delegate only for add a combobox and a color dialog, - * for use with the model + A little delegate only for add a combobox and a color dialog, + for use with the model ***************************************************/ DynamicTextItemDelegate::DynamicTextItemDelegate(QObject *parent) : @@ -1763,10 +1763,10 @@ bool DynamicTextItemDelegate::eventFilter(QObject *object, QEvent *event) } /** - * @brief DynamicTextItemDelegate::availableInfo - * @param deti - * @return A list of available info of element - */ + @brief DynamicTextItemDelegate::availableInfo + @param deti + @return A list of available info of element +*/ QStringList DynamicTextItemDelegate::availableInfo(DynamicElementTextItem *deti) const { QStringList qstrl; diff --git a/sources/ui/dynamicelementtextmodel.h b/sources/ui/dynamicelementtextmodel.h index 493290947..82836db37 100644 --- a/sources/ui/dynamicelementtextmodel.h +++ b/sources/ui/dynamicelementtextmodel.h @@ -27,11 +27,11 @@ class ElementTextItemGroup; class Element; /** - * @brief The DynamicElementTextModel class - * A model to use with QtView. - * This model display and can edit the value of dynamic text of an element. - * Set the delegate DynamicTextItemDelegate as delegate of this model. - */ + @brief The DynamicElementTextModel class + A model to use with QtView. + This model display and can edit the value of dynamic text of an element. + Set the delegate DynamicTextItemDelegate as delegate of this model. +*/ class DynamicElementTextModel : public QStandardItemModel { Q_OBJECT diff --git a/sources/ui/elementinfopartwidget.cpp b/sources/ui/elementinfopartwidget.cpp index 00ffc2532..f2b3c1a20 100644 --- a/sources/ui/elementinfopartwidget.cpp +++ b/sources/ui/elementinfopartwidget.cpp @@ -24,12 +24,12 @@ typedef SearchAndReplaceWorker sarw; /** - * @brief ElementInfoPartWidget::ElementInfoPartWidget - * Constructor - * @param key the string key what represent this info part - * @param translated_key the string key translated - * @param parent parent widget - */ + @brief ElementInfoPartWidget::ElementInfoPartWidget + Constructor + @param key the string key what represent this info part + @param translated_key the string key translated + @param parent parent widget +*/ ElementInfoPartWidget::ElementInfoPartWidget(QString key, const QString& translated_key, QWidget *parent): QWidget(parent), ui(new Ui::ElementInfoPartWidget), @@ -44,19 +44,19 @@ ElementInfoPartWidget::ElementInfoPartWidget(QString key, const QString& transla } /** - * @brief ElementInfoPartWidget::~ElementInfoPartWidget - * destructor - */ + @brief ElementInfoPartWidget::~ElementInfoPartWidget + destructor +*/ ElementInfoPartWidget::~ElementInfoPartWidget() { delete ui; } /** - * @brief ElementInfoPartWidget::setText - * Set text to line edit - * @param txt - */ + @brief ElementInfoPartWidget::setText + Set text to line edit + @param txt +*/ void ElementInfoPartWidget::setText(const QString &txt) { if (m_show_erase) { @@ -67,68 +67,68 @@ void ElementInfoPartWidget::setText(const QString &txt) } /** - * @brief ElementInfoPartWidget::text - * @return the text in the line edit - */ + @brief ElementInfoPartWidget::text + @return the text in the line edit +*/ QString ElementInfoPartWidget::text() const { return (ui->line_edit->text()); } /** - * @brief ElementInfoPartWidget::setPlaceHolderText - * @param text - */ + @brief ElementInfoPartWidget::setPlaceHolderText + @param text +*/ void ElementInfoPartWidget::setPlaceHolderText(const QString &text) { ui->line_edit->setPlaceholderText(text); } /** - * @brief ElementInfoPartWidget::setFocusTolineEdit - * Set the focus to the line edit - */ + @brief ElementInfoPartWidget::setFocusTolineEdit + Set the focus to the line edit +*/ void ElementInfoPartWidget::setFocusTolineEdit() { ui->line_edit->setFocus(); } /** - * @brief ElementInfoPartWidget::setEnabled - * enable the line edit - * @param e - */ + @brief ElementInfoPartWidget::setEnabled + enable the line edit + @param e +*/ void ElementInfoPartWidget::setEnabled(bool e) { ui->line_edit->setEnabled(e); } /** - * @brief ElementInfoPartWidget::setDisabled - * disable the line edit - * @param d - */ + @brief ElementInfoPartWidget::setDisabled + disable the line edit + @param d +*/ void ElementInfoPartWidget::setDisabled(bool d) { ui->line_edit->setDisabled(d); } /** - * @brief ElementInfoPartWidget::setEraseTextVisible - * @param visible - */ + @brief ElementInfoPartWidget::setEraseTextVisible + @param visible +*/ void ElementInfoPartWidget::setEraseTextVisible(bool visible) { ui->m_erase_text->setVisible(visible); m_show_erase = visible; } /** - * @brief ElementInfoPartWidget::setEraseTextChecked - * @param check - */ + @brief ElementInfoPartWidget::setEraseTextChecked + @param check +*/ void ElementInfoPartWidget::setEraseTextChecked(bool check) { ui->m_erase_text->setChecked(check); } /** - * @brief ElementInfoPartWidget::EraseTextCheckState - * @return - */ + @brief ElementInfoPartWidget::EraseTextCheckState + @return +*/ Qt::CheckState ElementInfoPartWidget::EraseTextCheckState() const { return ui->m_erase_text->checkState(); } diff --git a/sources/ui/elementinfowidget.cpp b/sources/ui/elementinfowidget.cpp index 0ba00c706..89af5edf8 100644 --- a/sources/ui/elementinfowidget.cpp +++ b/sources/ui/elementinfowidget.cpp @@ -24,11 +24,11 @@ #include "element.h" /** - * @brief ElementInfoWidget::ElementInfoWidget - * Constructor - * @param elmt element to edit information - * @param parent parent widget - */ + @brief ElementInfoWidget::ElementInfoWidget + Constructor + @param elmt element to edit information + @param parent parent widget +*/ ElementInfoWidget::ElementInfoWidget(Element *elmt, QWidget *parent) : AbstractElementPropertiesEditorWidget(parent), ui(new Ui::ElementInfoWidget), @@ -40,9 +40,9 @@ ElementInfoWidget::ElementInfoWidget(Element *elmt, QWidget *parent) : } /** - * @brief ElementInfoWidget::~ElementInfoWidget - * Destructor - */ + @brief ElementInfoWidget::~ElementInfoWidget + Destructor +*/ ElementInfoWidget::~ElementInfoWidget() { qDeleteAll(m_eipw_list); @@ -50,10 +50,10 @@ ElementInfoWidget::~ElementInfoWidget() } /** - * @brief ElementInfoWidget::setElement - * Set @element to be the edited element - * @param element - */ + @brief ElementInfoWidget::setElement + Set @element to be the edited element + @param element +*/ void ElementInfoWidget::setElement(Element *element) { if (m_element == element) return; @@ -84,10 +84,10 @@ void ElementInfoWidget::setElement(Element *element) } /** - * @brief ElementInfoWidget::apply - * Apply the new information with a new undo command (got with method associatedUndo) - * pushed to the stack of element project. - */ + @brief ElementInfoWidget::apply + Apply the new information with a new undo command (got with method associatedUndo) + pushed to the stack of element project. +*/ void ElementInfoWidget::apply() { if (QUndoCommand *undo = associatedUndo()) @@ -95,12 +95,12 @@ void ElementInfoWidget::apply() } /** - * @brief ElementInfoWidget::associatedUndo - * If the edited info is different of the actual element info, - * return a QUndoCommand with the change. - * If no change return nullptr; - * @return - */ + @brief ElementInfoWidget::associatedUndo + If the edited info is different of the actual element info, + return a QUndoCommand with the change. + If no change return nullptr; + @return +*/ QUndoCommand* ElementInfoWidget::associatedUndo() const { DiagramContext new_info = currentInfo(); @@ -113,10 +113,10 @@ QUndoCommand* ElementInfoWidget::associatedUndo() const } /** - * @brief ElementInfoWidget::setLiveEdit - * @param live_edit true : enable the live edit mode, false disable - * @return always true; - */ + @brief ElementInfoWidget::setLiveEdit + @param live_edit true : enable the live edit mode, false disable + @return always true; +*/ bool ElementInfoWidget::setLiveEdit(bool live_edit) { if (m_live_edit == live_edit) return true; @@ -131,13 +131,13 @@ bool ElementInfoWidget::setLiveEdit(bool live_edit) } /** - * @brief ElementInfoWidget::event - * Reimplemented from QWidget::event - * Only give focus to the first line edit at first activation. - * After send the event to QWidget. - * @param event - * @return - */ + @brief ElementInfoWidget::event + Reimplemented from QWidget::event + Only give focus to the first line edit at first activation. + After send the event to QWidget. + @param event + @return +*/ bool ElementInfoWidget::event(QEvent *event) { if (m_first_activation) @@ -152,9 +152,9 @@ bool ElementInfoWidget::event(QEvent *event) } /** - * @brief ElementInfoWidget::enableLiveEdit - * Enable the live edit mode - */ + @brief ElementInfoWidget::enableLiveEdit + Enable the live edit mode +*/ void ElementInfoWidget::enableLiveEdit() { for (ElementInfoPartWidget *eipw : m_eipw_list) @@ -162,9 +162,9 @@ void ElementInfoWidget::enableLiveEdit() } /** - * @brief ElementInfoWidget::disableLiveEdit - * disable the live edit mode - */ + @brief ElementInfoWidget::disableLiveEdit + disable the live edit mode +*/ void ElementInfoWidget::disableLiveEdit() { for (ElementInfoPartWidget *eipw : m_eipw_list) @@ -172,9 +172,9 @@ void ElementInfoWidget::disableLiveEdit() } /** - * @brief ElementInfoWidget::buildInterface - * Build the widget - */ + @brief ElementInfoWidget::buildInterface + Build the widget +*/ void ElementInfoWidget::buildInterface() { foreach (QString str, QETApp::elementInfoKeys()) @@ -187,10 +187,10 @@ void ElementInfoWidget::buildInterface() } /** - * @brief ElementInfoWidget::infoPartWidgetForKey - * @param key - * @return the ElementInfoPartWidget with key @key, if not found return nullptr; - */ + @brief ElementInfoWidget::infoPartWidgetForKey + @param key + @return the ElementInfoPartWidget with key @key, if not found return nullptr; +*/ ElementInfoPartWidget *ElementInfoWidget::infoPartWidgetForKey(const QString &key) const { foreach (ElementInfoPartWidget *eipw, m_eipw_list) @@ -203,10 +203,10 @@ ElementInfoPartWidget *ElementInfoWidget::infoPartWidgetForKey(const QString &ke } /** - * @brief ElementInfoWidget::updateUi - * fill information fetch in m_element_info to the - * corresponding line edit - */ + @brief ElementInfoWidget::updateUi + fill information fetch in m_element_info to the + corresponding line edit +*/ void ElementInfoWidget::updateUi() { //We disable live edit to avoid wrong undo when we fill the line edit with new text @@ -224,9 +224,9 @@ void ElementInfoWidget::updateUi() } /** - * @brief ElementInfoWidget::currentInfo - * @return the info currently edited - */ + @brief ElementInfoWidget::currentInfo + @return the info currently edited +*/ DiagramContext ElementInfoWidget::currentInfo() const { DiagramContext info_; @@ -249,18 +249,18 @@ DiagramContext ElementInfoWidget::currentInfo() const } /** - * @brief ElementInfoWidget::firstActivated - * Slot activated when this widget is show. - * Set the focus to the first line edit provided by this widget - */ + @brief ElementInfoWidget::firstActivated + Slot activated when this widget is show. + Set the focus to the first line edit provided by this widget +*/ void ElementInfoWidget::firstActivated() { m_eipw_list.first() -> setFocusTolineEdit(); } /** - * @brief ElementInfoWidget::elementInfoChange - * This slot is called when m_element::elementInformation change. - */ + @brief ElementInfoWidget::elementInfoChange + This slot is called when m_element::elementInformation change. +*/ void ElementInfoWidget::elementInfoChange() { if(currentInfo() != m_element->elementInformations()) diff --git a/sources/ui/elementinfowidget.h b/sources/ui/elementinfowidget.h index 9b4145f66..b0316cde1 100644 --- a/sources/ui/elementinfowidget.h +++ b/sources/ui/elementinfowidget.h @@ -32,9 +32,9 @@ namespace Ui { } /** - * @brief The ElementInfoWidget class - * this class is a widget to edit an element informations. - */ + @brief The ElementInfoWidget class + this class is a widget to edit an element informations. +*/ class ElementInfoWidget : public AbstractElementPropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/elementpropertieswidget.cpp b/sources/ui/elementpropertieswidget.cpp index 08e60806e..1e8dd26af 100644 --- a/sources/ui/elementpropertieswidget.cpp +++ b/sources/ui/elementpropertieswidget.cpp @@ -32,11 +32,11 @@ #include /** - * @brief ElementPropertiesWidget::ElementPropertiesWidget - * Default constructor - * @param elmt - * @param parent - */ + @brief ElementPropertiesWidget::ElementPropertiesWidget + Default constructor + @param elmt + @param parent +*/ ElementPropertiesWidget::ElementPropertiesWidget(Element *elmt, QWidget *parent) : AbstractElementPropertiesEditorWidget (parent), m_diagram (elmt->diagram()), @@ -48,13 +48,13 @@ ElementPropertiesWidget::ElementPropertiesWidget(Element *elmt, QWidget *parent) } /** - * @brief ElementPropertiesWidget::ElementPropertiesWidget - * Same as default constructor, the edited element, is the parent element of @text. - * The only difference with default constructor, is that the current tab is the tab for dynamic texts, - * and the item in the tree that represent @text is expanded and selected. - * @param text - * @param parent - */ + @brief ElementPropertiesWidget::ElementPropertiesWidget + Same as default constructor, the edited element, is the parent element of @text. + The only difference with default constructor, is that the current tab is the tab for dynamic texts, + and the item in the tree that represent @text is expanded and selected. + @param text + @param parent +*/ ElementPropertiesWidget::ElementPropertiesWidget(DynamicElementTextItem *text, QWidget *parent) : AbstractElementPropertiesEditorWidget (parent), m_tab (nullptr), @@ -69,13 +69,13 @@ ElementPropertiesWidget::ElementPropertiesWidget(DynamicElementTextItem *text, Q } /** - * @brief ElementPropertiesWidget::ElementPropertiesWidget - * Same as default constructor, the edited element, is the parent element of @group. - * The only difference with default constructor, is that the current tab is the tab for dynamic texts, - * and the item in the tree that represent @group is expanded and selected. - * @param group - * @param parent - */ + @brief ElementPropertiesWidget::ElementPropertiesWidget + Same as default constructor, the edited element, is the parent element of @group. + The only difference with default constructor, is that the current tab is the tab for dynamic texts, + and the item in the tree that represent @group is expanded and selected. + @param group + @param parent +*/ ElementPropertiesWidget::ElementPropertiesWidget(ElementTextItemGroup *group, QWidget *parent) : AbstractElementPropertiesEditorWidget (parent), m_tab (nullptr), @@ -91,10 +91,10 @@ ElementPropertiesWidget::ElementPropertiesWidget(ElementTextItemGroup *group, QW } /** - * @brief ElementPropertiesWidget::setElement - * Set @element to be the edited element - * @param element - */ + @brief ElementPropertiesWidget::setElement + Set @element to be the edited element + @param element +*/ void ElementPropertiesWidget::setElement(Element *element) { if (m_element == element) return; @@ -118,11 +118,11 @@ void ElementPropertiesWidget::setElement(Element *element) } /** - * @brief ElementPropertiesWidget::setDynamicText - * convenience function: same as call : ElementPropertiesWidget::setElement, with parameter the parent element of @text. - * Set the dynamics text tab as current tab, expand and select the item that represent @text - * @param text - */ + @brief ElementPropertiesWidget::setDynamicText + convenience function: same as call : ElementPropertiesWidget::setElement, with parameter the parent element of @text. + Set the dynamics text tab as current tab, expand and select the item that represent @text + @param text +*/ void ElementPropertiesWidget::setDynamicText(DynamicElementTextItem *text) { if(text->parentElement()) @@ -141,11 +141,11 @@ void ElementPropertiesWidget::setDynamicText(DynamicElementTextItem *text) } /** - * @brief ElementPropertiesWidget::setTextsGroup - * Conveniance function : same as call : ElementPropertiesWidget::setElement, with parameter the parent element of @group. - * Set the dynamics text tab as current tab, expand and select the item that represent @group - * @param group - */ + @brief ElementPropertiesWidget::setTextsGroup + Conveniance function : same as call : ElementPropertiesWidget::setElement, with parameter the parent element of @group. + Set the dynamics text tab as current tab, expand and select the item that represent @group + @param group +*/ void ElementPropertiesWidget::setTextsGroup(ElementTextItemGroup *group) { if(group->parentItem() && group->parentItem()->type() == Element::Type) @@ -164,10 +164,10 @@ void ElementPropertiesWidget::setTextsGroup(ElementTextItemGroup *group) } /** - * @brief ElementPropertiesWidget::apply - * Apply the new properties by pushing an undo command - * to the parent project's undo stack of element - */ + @brief ElementPropertiesWidget::apply + Apply the new properties by pushing an undo command + to the parent project's undo stack of element +*/ void ElementPropertiesWidget::apply() { QList undo_list; @@ -191,9 +191,9 @@ void ElementPropertiesWidget::apply() } /** - * @brief ElementPropertiesWidget::reset - * Reset the edited properties - */ + @brief ElementPropertiesWidget::reset + Reset the edited properties +*/ void ElementPropertiesWidget::reset() { foreach (PropertiesEditorWidget *pew, m_list_editor) pew->reset(); } @@ -210,9 +210,9 @@ bool ElementPropertiesWidget::setLiveEdit(bool live_edit) } /** - * @brief ElementPropertiesWidget::findInPanel - * If m_element is a custom element, emit findElementRequired - */ + @brief ElementPropertiesWidget::findInPanel + If m_element is a custom element, emit findElementRequired +*/ void ElementPropertiesWidget::findInPanel() { if (m_element && m_diagram) @@ -223,9 +223,9 @@ void ElementPropertiesWidget::findInPanel() } /** - * @brief ElementPropertiesWidget::editElement - * If m_element is a custom element, emit findElementRequired and editElementRequired - */ + @brief ElementPropertiesWidget::editElement + If m_element is a custom element, emit findElementRequired and editElementRequired +*/ void ElementPropertiesWidget::editElement() { if (m_element && m_diagram) @@ -237,9 +237,9 @@ void ElementPropertiesWidget::editElement() } /** - * @brief ElementPropertiesWidget::build - * Build the content of this widget - */ + @brief ElementPropertiesWidget::build + Build the content of this widget +*/ void ElementPropertiesWidget::buildGui() { m_tab = new QTabWidget(this); @@ -249,9 +249,9 @@ void ElementPropertiesWidget::buildGui() } /** - * @brief ElementPropertiesWidget::updateUi - * Update the content of this widget - */ + @brief ElementPropertiesWidget::updateUi + Update the content of this widget +*/ void ElementPropertiesWidget::updateUi() { //We keep the current title of the tab, to return to the same tab @@ -317,9 +317,9 @@ void ElementPropertiesWidget::updateUi() } /** - * @brief ElementPropertiesWidget::addGeneralWidget - * Add or update the general widget on this tab widget - */ + @brief ElementPropertiesWidget::addGeneralWidget + Add or update the general widget on this tab widget +*/ void ElementPropertiesWidget::addGeneralWidget() { int index = m_tab->currentIndex(); @@ -334,9 +334,9 @@ void ElementPropertiesWidget::addGeneralWidget() } /** - * @brief ElementPropertiesWidget::generalWidget - * @return build and return the "general" widget - */ + @brief ElementPropertiesWidget::generalWidget + @return build and return the "general" widget +*/ QWidget *ElementPropertiesWidget::generalWidget() { QString description_string(tr("Élement\n")); diff --git a/sources/ui/imagepropertieswidget.cpp b/sources/ui/imagepropertieswidget.cpp index 8cdfe3d4d..239e1e1f9 100644 --- a/sources/ui/imagepropertieswidget.cpp +++ b/sources/ui/imagepropertieswidget.cpp @@ -22,11 +22,11 @@ #include "QPropertyUndoCommand/qpropertyundocommand.h" /** - * @brief ImagePropertiesWidget::ImagePropertiesWidget - * Constructor - * @param image : image to edit properties - * @param parent : parent widget - */ + @brief ImagePropertiesWidget::ImagePropertiesWidget + Constructor + @param image : image to edit properties + @param parent : parent widget +*/ ImagePropertiesWidget::ImagePropertiesWidget(DiagramImageItem *image, QWidget *parent) : PropertiesEditorWidget(parent), ui(new Ui::ImagePropertiesWidget), @@ -38,18 +38,18 @@ ImagePropertiesWidget::ImagePropertiesWidget(DiagramImageItem *image, QWidget *p } /** - * @brief ImagePropertiesWidget::~ImagePropertiesWidget - * Destructor - */ + @brief ImagePropertiesWidget::~ImagePropertiesWidget + Destructor +*/ ImagePropertiesWidget::~ImagePropertiesWidget() { delete ui; } /** - * @brief ImagePropertiesWidget::setImageItem - * Set the image to edit properties - * @param image : image to edit - */ + @brief ImagePropertiesWidget::setImageItem + Set the image to edit properties + @param image : image to edit +*/ void ImagePropertiesWidget::setImageItem(DiagramImageItem *image) { if(!image) return; @@ -66,9 +66,9 @@ void ImagePropertiesWidget::setImageItem(DiagramImageItem *image) } /** - * @brief ImagePropertiesWidget::apply - * Apply the change - */ + @brief ImagePropertiesWidget::apply + Apply the change +*/ void ImagePropertiesWidget::apply() { if(!m_image) return; @@ -88,9 +88,9 @@ void ImagePropertiesWidget::apply() } /** - * @brief ImagePropertiesWidget::reset - * Reset the change - */ + @brief ImagePropertiesWidget::reset + Reset the change +*/ void ImagePropertiesWidget::reset() { if(!m_image) return; @@ -101,11 +101,11 @@ void ImagePropertiesWidget::reset() } /** - * @brief ImagePropertiesWidget::setLiveEdit - * @param live_edit true -> enable live edit + @brief ImagePropertiesWidget::setLiveEdit + @param live_edit true -> enable live edit * false -> disable live edit - * @return always true - */ + @return always true +*/ bool ImagePropertiesWidget::setLiveEdit(bool live_edit) { if (m_live_edit == live_edit) return true; @@ -126,10 +126,10 @@ bool ImagePropertiesWidget::setLiveEdit(bool live_edit) } /** - * @brief ImagePropertiesWidget::associatedUndo - * @return the change in an undo command (ItemResizerCommand). - * If there is no change return nullptr - */ + @brief ImagePropertiesWidget::associatedUndo + @return the change in an undo command (ItemResizerCommand). + If there is no change return nullptr +*/ QUndoCommand* ImagePropertiesWidget::associatedUndo() const { @@ -143,9 +143,9 @@ QUndoCommand* ImagePropertiesWidget::associatedUndo() const } /** - * @brief ImagePropertiesWidget::updateUi - * Udpdate the ui, notably when the image to edit change - */ + @brief ImagePropertiesWidget::updateUi + Udpdate the ui, notably when the image to edit change +*/ void ImagePropertiesWidget::updateUi() { if (!m_image) return; @@ -154,10 +154,10 @@ void ImagePropertiesWidget::updateUi() } /** - * @brief ImagePropertiesWidget::on_m_scale_slider_valueChanged - * Update the size of image when move slider. - * @param value - */ + @brief ImagePropertiesWidget::on_m_scale_slider_valueChanged + Update the size of image when move slider. + @param value +*/ void ImagePropertiesWidget::on_m_scale_slider_valueChanged(int value) { qreal scale = value; @@ -165,9 +165,9 @@ void ImagePropertiesWidget::on_m_scale_slider_valueChanged(int value) } /** - * @brief ImagePropertiesWidget::on_m_lock_pos_cb_clicked - * Set movable or not the image according to corresponding check box - */ + @brief ImagePropertiesWidget::on_m_lock_pos_cb_clicked + Set movable or not the image according to corresponding check box +*/ void ImagePropertiesWidget::on_m_lock_pos_cb_clicked() { m_image->setMovable(!ui->m_lock_pos_cb->isChecked()); } diff --git a/sources/ui/imagepropertieswidget.h b/sources/ui/imagepropertieswidget.h index 2eb3d9d74..7529fd583 100644 --- a/sources/ui/imagepropertieswidget.h +++ b/sources/ui/imagepropertieswidget.h @@ -27,9 +27,9 @@ namespace Ui { } /** - * @brief The ImagePropertiesWidget class - * This class provide a widget to edit the propertie of a DiagramImageItem - */ + @brief The ImagePropertiesWidget class + This class provide a widget to edit the propertie of a DiagramImageItem +*/ class ImagePropertiesWidget : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/importelementtextpatterndialog.cpp b/sources/ui/importelementtextpatterndialog.cpp index df6ea04d6..95b5049f2 100644 --- a/sources/ui/importelementtextpatterndialog.cpp +++ b/sources/ui/importelementtextpatterndialog.cpp @@ -30,16 +30,16 @@ ImportElementTextPatternDialog::~ImportElementTextPatternDialog() } /** - * @brief ImportElementTextPatternDialog::getItem - * For all arguments see QInputDialog::getItem, except for erase, they store the state of the check box. - * @param parent - * @param title - * @param label - * @param items - * @param ok - * @param erase - * @return - */ + @brief ImportElementTextPatternDialog::getItem + For all arguments see QInputDialog::getItem, except for erase, they store the state of the check box. + @param parent + @param title + @param label + @param items + @param ok + @param erase + @return +*/ QString ImportElementTextPatternDialog::getItem(QWidget *parent, const QString &title, const QString &label, const QStringList &items, bool *ok, bool *erase) { QString text(items.value(0)); diff --git a/sources/ui/importelementtextpatterndialog.h b/sources/ui/importelementtextpatterndialog.h index 9fc769db4..2c1053f4b 100644 --- a/sources/ui/importelementtextpatterndialog.h +++ b/sources/ui/importelementtextpatterndialog.h @@ -25,11 +25,11 @@ namespace Ui { } /** - * @brief The ImportElementTextPatternDialog class - * A dialog use for ask user to select a element text pattern. - * This dialog is highly inspired from QInputDialog::getItem. - * In fact this the same + a check box. - */ + @brief The ImportElementTextPatternDialog class + A dialog use for ask user to select a element text pattern. + This dialog is highly inspired from QInputDialog::getItem. + In fact this the same + a check box. +*/ class ImportElementTextPatternDialog : public QDialog { Q_OBJECT diff --git a/sources/ui/inditextpropertieswidget.cpp b/sources/ui/inditextpropertieswidget.cpp index b87ea3625..8afb321ef 100644 --- a/sources/ui/inditextpropertieswidget.cpp +++ b/sources/ui/inditextpropertieswidget.cpp @@ -25,10 +25,10 @@ #include /** - * @brief IndiTextPropertiesWidget::IndiTextPropertiesWidget - * @param text : the text to edit - * @param parent : the parent widget of this widget - */ + @brief IndiTextPropertiesWidget::IndiTextPropertiesWidget + @param text : the text to edit + @param parent : the parent widget of this widget +*/ IndiTextPropertiesWidget::IndiTextPropertiesWidget(IndependentTextItem *text, QWidget *parent) : PropertiesEditorWidget(parent), ui(new Ui::IndiTextPropertiesWidget) @@ -40,10 +40,10 @@ IndiTextPropertiesWidget::IndiTextPropertiesWidget(IndependentTextItem *text, QW } /** - * @brief IndiTextPropertiesWidget::IndiTextPropertiesWidget - * @param text_list : a list of texts to edit - * @param parent : the parent widget of this widget - */ + @brief IndiTextPropertiesWidget::IndiTextPropertiesWidget + @param text_list : a list of texts to edit + @param parent : the parent widget of this widget +*/ IndiTextPropertiesWidget::IndiTextPropertiesWidget(QList text_list, QWidget *parent) : PropertiesEditorWidget (parent), ui(new Ui::IndiTextPropertiesWidget) @@ -53,16 +53,16 @@ IndiTextPropertiesWidget::IndiTextPropertiesWidget(QList } /** - * @brief IndiTextPropertiesWidget::~IndiTextPropertiesWidget - */ + @brief IndiTextPropertiesWidget::~IndiTextPropertiesWidget +*/ IndiTextPropertiesWidget::~IndiTextPropertiesWidget() { delete ui; } /** - * @brief IndiTextPropertiesWidget::setText - * @param text : set @text as edited text - */ + @brief IndiTextPropertiesWidget::setText + @param text : set @text as edited text +*/ void IndiTextPropertiesWidget::setText(IndependentTextItem *text) { if (m_text) { @@ -109,10 +109,10 @@ void IndiTextPropertiesWidget::setText(QList text_list) } /** - * @brief IndiTextPropertiesWidget::apply - * Apply the current edition through a QUndoCommand pushed - * to the undo stack of text's diagram. - */ + @brief IndiTextPropertiesWidget::apply + Apply the current edition through a QUndoCommand pushed + to the undo stack of text's diagram. +*/ void IndiTextPropertiesWidget::apply() { Diagram *d = nullptr; @@ -138,10 +138,10 @@ void IndiTextPropertiesWidget::apply() } /** - * @brief IndiTextPropertiesWidget::setLiveEdit - * @param live_edit - * @return - */ + @brief IndiTextPropertiesWidget::setLiveEdit + @param live_edit + @return +*/ bool IndiTextPropertiesWidget::setLiveEdit(bool live_edit) { if (m_live_edit == live_edit) { @@ -162,9 +162,9 @@ bool IndiTextPropertiesWidget::setLiveEdit(bool live_edit) } /** - * @brief IndiTextPropertiesWidget::associatedUndo - * @return - */ + @brief IndiTextPropertiesWidget::associatedUndo + @return +*/ QUndoCommand *IndiTextPropertiesWidget::associatedUndo() const { if (m_live_edit) @@ -314,9 +314,9 @@ QUndoCommand *IndiTextPropertiesWidget::associatedUndo() const } /** - * @brief IndiTextPropertiesWidget::setUpEditConnection - * Disconnect the previous connection, and reconnect the connection between the editors widgets and void IndiTextPropertiesWidget::apply function - */ + @brief IndiTextPropertiesWidget::setUpEditConnection + Disconnect the previous connection, and reconnect the connection between the editors widgets and void IndiTextPropertiesWidget::apply function +*/ void IndiTextPropertiesWidget::setUpEditConnection() { for (QMetaObject::Connection c : m_edit_connection) { @@ -339,8 +339,8 @@ void IndiTextPropertiesWidget::setUpEditConnection() } /** - * @brief IndiTextPropertiesWidget::updateUi - */ + @brief IndiTextPropertiesWidget::updateUi +*/ void IndiTextPropertiesWidget::updateUi() { if (!m_text && m_text_list.isEmpty()) { @@ -417,8 +417,8 @@ void IndiTextPropertiesWidget::updateUi() } /** - * @brief IndiTextPropertiesWidget::on_m_advanced_editor_pb_clicked - */ + @brief IndiTextPropertiesWidget::on_m_advanced_editor_pb_clicked +*/ void IndiTextPropertiesWidget::on_m_advanced_editor_pb_clicked() { if (m_text) { m_text->edit(); diff --git a/sources/ui/inditextpropertieswidget.h b/sources/ui/inditextpropertieswidget.h index 1012fafed..ab5a77329 100644 --- a/sources/ui/inditextpropertieswidget.h +++ b/sources/ui/inditextpropertieswidget.h @@ -27,9 +27,9 @@ namespace Ui { } /** - * @brief The IndiTextPropertiesWidget class - * This widget is used to edit the properties of one or several independent text item - */ + @brief The IndiTextPropertiesWidget class + This widget is used to edit the properties of one or several independent text item +*/ class IndiTextPropertiesWidget : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/linksingleelementwidget.cpp b/sources/ui/linksingleelementwidget.cpp index 26b1e1484..f95e52a47 100644 --- a/sources/ui/linksingleelementwidget.cpp +++ b/sources/ui/linksingleelementwidget.cpp @@ -26,13 +26,13 @@ #include /** - * @brief LinkSingleElementWidget::LinkSingleElementWidget - * Default constructor - * @param elmt - * the edited element - * @param parent - * the parent widget - */ + @brief LinkSingleElementWidget::LinkSingleElementWidget + Default constructor + @param elmt + the edited element + @param parent + the parent widget +*/ LinkSingleElementWidget::LinkSingleElementWidget(Element *elmt, QWidget *parent) : AbstractElementPropertiesEditorWidget(parent), ui(new Ui::LinkSingleElementWidget) @@ -75,9 +75,9 @@ LinkSingleElementWidget::LinkSingleElementWidget(Element *elmt, QWidget *parent) } /** - * @brief LinkSingleElementWidget::~LinkSingleElementWidget - * Default destructor - */ + @brief LinkSingleElementWidget::~LinkSingleElementWidget + Default destructor +*/ LinkSingleElementWidget::~LinkSingleElementWidget() { if(m_showed_element) @@ -93,10 +93,10 @@ LinkSingleElementWidget::~LinkSingleElementWidget() } /** - * @brief LinkSingleElementWidget::setElement - * Set element to be the edited element. - * @param element - */ + @brief LinkSingleElementWidget::setElement + Set element to be the edited element. + @param element +*/ void LinkSingleElementWidget::setElement(Element *element) { if (m_element == element) @@ -135,10 +135,10 @@ void LinkSingleElementWidget::setElement(Element *element) } /** - * @brief LinkSingleElementWidget::apply - * Apply the new property of the edited element by pushing - * the associated undo command to parent project undo stack - */ + @brief LinkSingleElementWidget::apply + Apply the new property of the edited element by pushing + the associated undo command to parent project undo stack +*/ void LinkSingleElementWidget::apply() { QUndoCommand *undo = associatedUndo(); @@ -151,10 +151,10 @@ void LinkSingleElementWidget::apply() } /** - * @brief LinkSingleElementWidget::associatedUndo - * @return the undo command associated to the current edition - * if there isn't change, return nulptr - */ + @brief LinkSingleElementWidget::associatedUndo + @return the undo command associated to the current edition + if there isn't change, return nulptr +*/ QUndoCommand *LinkSingleElementWidget::associatedUndo() const { LinkElementCommand *undo = new LinkElementCommand(m_element); @@ -173,9 +173,9 @@ QUndoCommand *LinkSingleElementWidget::associatedUndo() const } /** - * @brief LinkSingleElementWidget::title - * @return the title used for this editor - */ + @brief LinkSingleElementWidget::title + @return the title used for this editor +*/ QString LinkSingleElementWidget::title() const { if (m_element->linkType() & Element::AllReport) @@ -185,9 +185,9 @@ QString LinkSingleElementWidget::title() const } /** - * @brief LinkSingleElementWidget::updateUi - * Update the content of this widget - */ + @brief LinkSingleElementWidget::updateUi + Update the content of this widget +*/ void LinkSingleElementWidget::updateUi() { m_unlink = false; @@ -202,9 +202,9 @@ void LinkSingleElementWidget::updateUi() } /** - * @brief LinkSingleElementWidget::buildTree - * Build the content of the QTreeWidget - */ + @brief LinkSingleElementWidget::buildTree + Build the content of the QTreeWidget +*/ void LinkSingleElementWidget::buildTree() { clearTreeWidget(); @@ -324,10 +324,10 @@ void LinkSingleElementWidget::buildTree() } /** - * @brief LinkSingleElementWidget::setLiveEdit - * @param live_edit - * @return - */ + @brief LinkSingleElementWidget::setLiveEdit + @param live_edit + @return +*/ bool LinkSingleElementWidget::setLiveEdit(bool live_edit) { if (m_live_edit == live_edit) @@ -339,11 +339,11 @@ bool LinkSingleElementWidget::setLiveEdit(bool live_edit) } /** - * @brief LinkSingleElementWidget::availableElements - * @return A QList with all available element - * to be linked with the edited element. - * This methode take care of the combo box "find in diagram" - */ + @brief LinkSingleElementWidget::availableElements + @return A QList with all available element + to be linked with the edited element. + This methode take care of the combo box "find in diagram" +*/ QList LinkSingleElementWidget::availableElements() { QList elmt_list; @@ -366,9 +366,9 @@ QList LinkSingleElementWidget::availableElements() } /** - * @brief LinkSingleElementWidget::setUpCompleter - * Setup the completer of search_field - */ + @brief LinkSingleElementWidget::setUpCompleter + Setup the completer of search_field +*/ void LinkSingleElementWidget::setUpCompleter() { ui->m_search_field->clear(); @@ -385,11 +385,11 @@ void LinkSingleElementWidget::setUpCompleter() } /** - * @brief LinkSingleElementWidget::clearTreeWidget - * Clear the tree widget. - * Delete all QTreeWidget (in the tree widget and in the hash). - * Clear the hash. - */ + @brief LinkSingleElementWidget::clearTreeWidget + Clear the tree widget. + Delete all QTreeWidget (in the tree widget and in the hash). + Clear the hash. +*/ void LinkSingleElementWidget::clearTreeWidget() { while(ui->m_tree_widget->topLevelItemCount()) @@ -439,10 +439,10 @@ void LinkSingleElementWidget::setUpHeaderLabels() } /** - * @brief LinkSingleElementWidget::diagramWasRemovedFromProject - * * This slot is called when a diagram is removed from the parent project of edited element - * to update the content of this widget - */ + @brief LinkSingleElementWidget::diagramWasRemovedFromProject + * This slot is called when a diagram is removed from the parent project of edited element + to update the content of this widget +*/ void LinkSingleElementWidget::diagramWasRemovedFromProject() { //We use a timer because if the removed diagram contain the master element linked to the edited element @@ -456,9 +456,9 @@ void LinkSingleElementWidget::showedElementWasDeleted() } /** - * @brief LinkSingleElementWidget::linkTriggered - * Action linkis triggered - */ + @brief LinkSingleElementWidget::linkTriggered + Action linkis triggered +*/ void LinkSingleElementWidget::linkTriggered() { if(!m_qtwi_at_context_menu) @@ -493,9 +493,9 @@ void LinkSingleElementWidget::linkTriggered() } /** - * @brief LinkSingleElementWidget::hideButtons - * Hide the button displayed when element is already linked - */ + @brief LinkSingleElementWidget::hideButtons + Hide the button displayed when element is already linked +*/ void LinkSingleElementWidget::hideButtons() { ui->m_label->hide(); @@ -506,9 +506,9 @@ void LinkSingleElementWidget::hideButtons() } /** - * @brief LinkSingleElementWidget::showButtons - * Show the button displayed when element is already linked - */ + @brief LinkSingleElementWidget::showButtons + Show the button displayed when element is already linked +*/ void LinkSingleElementWidget::showButtons() { ui->m_label->show(); @@ -539,11 +539,11 @@ void LinkSingleElementWidget::on_m_unlink_pb_clicked() } /** - * @brief LinkSingleElementWidget::on_m_tree_widget_itemDoubleClicked - * Highlight the element represented by @item - * @param item - * @param column - */ + @brief LinkSingleElementWidget::on_m_tree_widget_itemDoubleClicked + Highlight the element represented by @item + @param item + @param column +*/ void LinkSingleElementWidget::on_m_tree_widget_itemDoubleClicked(QTreeWidgetItem *item, int column) { Q_UNUSED(column); @@ -599,11 +599,11 @@ void LinkSingleElementWidget::on_m_show_this_pb_clicked() } /** - * @brief LinkSingleElementWidget::on_m_search_field_textEdited - * Search all items which match with @arg1 and shows it, other items is hidden. - * If @arg1 is empty, show all items. - * @param arg1 - */ + @brief LinkSingleElementWidget::on_m_search_field_textEdited + Search all items which match with @arg1 and shows it, other items is hidden. + If @arg1 is empty, show all items. + @param arg1 +*/ void LinkSingleElementWidget::on_m_search_field_textEdited(const QString &arg1) { //Show all items if arg1 is empty, if not hide all items diff --git a/sources/ui/linksingleelementwidget.h b/sources/ui/linksingleelementwidget.h index 6e6e2b70c..d725a84a1 100644 --- a/sources/ui/linksingleelementwidget.h +++ b/sources/ui/linksingleelementwidget.h @@ -29,14 +29,14 @@ namespace Ui { /** * @brief The LinkSingleElementWidget class - * this class provide a widget to select an element to be linked - * to the element given in the constructor. - * The element given in constructor must be linked with only one other element (like report or slave element). - * This widget detect automaticaly the kind of element given in the constructor and - * search all element that can be linked with it. - * If the element is already linked, the widget ask user to unlink. - * This widget embedded the diagram command for undo/redo the action - */ + this class provide a widget to select an element to be linked + to the element given in the constructor. + The element given in constructor must be linked with only one other element (like report or slave element). + This widget detect automaticaly the kind of element given in the constructor and + search all element that can be linked with it. + If the element is already linked, the widget ask user to unlink. + This widget embedded the diagram command for undo/redo the action +*/ class LinkSingleElementWidget : public AbstractElementPropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/marginseditdialog.cpp b/sources/ui/marginseditdialog.cpp index 332f9bbd1..d9e3660b8 100644 --- a/sources/ui/marginseditdialog.cpp +++ b/sources/ui/marginseditdialog.cpp @@ -41,12 +41,12 @@ QMargins MarginsEditDialog::margins() const { } /** - * @brief MarginsEditDialog::getMargins - * @param margins : margins to set by default - * @param accepted : bool to know if dialog is accepted - * @param parent : parent widget. - * @return The a margins with the edited value if dialog is accepted or a default constructed QMargins() if dialog is rejected - */ + @brief MarginsEditDialog::getMargins + @param margins : margins to set by default + @param accepted : bool to know if dialog is accepted + @param parent : parent widget. + @return The a margins with the edited value if dialog is accepted or a default constructed QMargins() if dialog is rejected +*/ QMargins MarginsEditDialog::getMargins(QMargins margins, bool *accepted, QWidget *parent) { QScopedPointer d(new MarginsEditDialog(margins, parent)); diff --git a/sources/ui/marginseditdialog.h b/sources/ui/marginseditdialog.h index 073889746..dc4e82409 100644 --- a/sources/ui/marginseditdialog.h +++ b/sources/ui/marginseditdialog.h @@ -26,9 +26,9 @@ class MarginsEditDialog; } /** - * @brief The MarginsEditDialog class - * A simple dialog to edit QMargins - */ + @brief The MarginsEditDialog class + A simple dialog to edit QMargins +*/ class MarginsEditDialog : public QDialog { Q_OBJECT diff --git a/sources/ui/masterpropertieswidget.cpp b/sources/ui/masterpropertieswidget.cpp index 09f440146..fedadc13c 100644 --- a/sources/ui/masterpropertieswidget.cpp +++ b/sources/ui/masterpropertieswidget.cpp @@ -168,7 +168,7 @@ void MasterPropertiesWidget::setElement(Element *element) pushed to the stack of element project. Return true if link change, else false @note is void no Return ??? - */ +*/ void MasterPropertiesWidget::apply() { if (QUndoCommand *undo = associatedUndo()) m_element -> diagram() -> undoStack().push(undo); diff --git a/sources/ui/masterpropertieswidget.h b/sources/ui/masterpropertieswidget.h index 492c735a9..155019123 100644 --- a/sources/ui/masterpropertieswidget.h +++ b/sources/ui/masterpropertieswidget.h @@ -54,9 +54,9 @@ class MasterPropertiesWidget : public AbstractElementPropertiesEditorWidget void reset() override; QUndoCommand *associatedUndo () const override; /** - * @brief title - * @return QString title - */ + @brief title + @return QString title + */ QString title() const override { return tr("Référence croisée (maître)");} bool setLiveEdit(bool live_edit) override; diff --git a/sources/ui/potentialselectordialog.cpp b/sources/ui/potentialselectordialog.cpp index acabbf4ba..c047477c1 100644 --- a/sources/ui/potentialselectordialog.cpp +++ b/sources/ui/potentialselectordialog.cpp @@ -30,9 +30,9 @@ //### BEGIN PRIVATE CLASS ###// /** - * @brief The NewConductorPotentialSelector class - * Use for get the conductor propertie when two potentials is linked by a conductor - */ + @brief The NewConductorPotentialSelector class + Use for get the conductor propertie when two potentials is linked by a conductor +*/ class NewConductorPotentialSelector : public AbstractPotentialSelector { public: @@ -60,12 +60,12 @@ class NewConductorPotentialSelector : public AbstractPotentialSelector bool isValid() const override {return m_is_valid;} /** - * @brief getPotential - * Get the conductor propertie of the potential at terminal, and the number of wire in this potential. - * @param terminal - * @param properties - * @param number - */ + @brief getPotential + Get the conductor propertie of the potential at terminal, and the number of wire in this potential. + @param terminal + @param properties + @param number + */ void getPotential(Terminal *terminal, autonum::sequentialNumbers &seq_num , int &number, QList &properties_list, QList &c_list) { Conductor *conductor_in_potential = nullptr; @@ -117,9 +117,9 @@ class NewConductorPotentialSelector : public AbstractPotentialSelector }; /** - * @brief The LinkReportPotentialSelector class - * Use for get the conductor propertie when two potentials is linked with a folio report - */ + @brief The LinkReportPotentialSelector class + Use for get the conductor propertie when two potentials is linked with a folio report +*/ class LinkReportPotentialSelector : public AbstractPotentialSelector { public: @@ -215,12 +215,12 @@ ConductorProperties PotentialSelectorDialog::chosenProperties(QListm_conductor_number_1)); @@ -336,9 +336,9 @@ void PotentialSelectorDialog::buildWidget() } /** - * @brief PotentialSelectorDialog::on_buttonBox_accepted - * Action when user click on OK button - */ + @brief PotentialSelectorDialog::on_buttonBox_accepted + Action when user click on OK button +*/ void PotentialSelectorDialog::on_buttonBox_accepted() { if (!m_potential_selector->isValid()) diff --git a/sources/ui/potentialselectordialog.h b/sources/ui/potentialselectordialog.h index e4316a293..9794674d3 100644 --- a/sources/ui/potentialselectordialog.h +++ b/sources/ui/potentialselectordialog.h @@ -43,20 +43,20 @@ namespace Ui { } /** - * @brief The PotentialSelectorDialog class - * This dialog is used when user try to connect two existing potential together. - * The dialog ask to user to make a choice between the properties of the two existing potential, - * to apply it for the new potential. + @brief The PotentialSelectorDialog class + This dialog is used when user try to connect two existing potential together. + The dialog ask to user to make a choice between the properties of the two existing potential, + to apply it for the new potential. * - * Each constructor have a QUndoCommand @parent_undo for parameter - * If @parent_undo isn't null, when user click on OK button, the dialog will use the parent-undo - * as parent of the undo command that describe the changes. - * If @parent_undo is null, the created undo-command is push to the undo stack of the parent diagram of a conductor in potential. - * else we apply the change without a QUndoCommand. - * - * the static function chosenProperties, open a dialog who ask user to make a choice between the given - * properties - */ + Each constructor have a QUndoCommand @parent_undo for parameter + If @parent_undo isn't null, when user click on OK button, the dialog will use the parent-undo + as parent of the undo command that describe the changes. + If @parent_undo is null, the created undo-command is push to the undo stack of the parent diagram of a conductor in potential. + else we apply the change without a QUndoCommand. + + the static function chosenProperties, open a dialog who ask user to make a choice between the given + properties +*/ class PotentialSelectorDialog : public QDialog { Q_OBJECT diff --git a/sources/ui/projectpropertiesdialog.cpp b/sources/ui/projectpropertiesdialog.cpp index 607930850..866f14358 100644 --- a/sources/ui/projectpropertiesdialog.cpp +++ b/sources/ui/projectpropertiesdialog.cpp @@ -22,11 +22,11 @@ #include "configpages.h" /** - * @brief ProjectPropertiesDialog::ProjectPropertiesDialog - * Default constructor - * @param project : project to edit properties - * @param parent : parent widget of this dialog - */ + @brief ProjectPropertiesDialog::ProjectPropertiesDialog + Default constructor + @param project : project to edit properties + @param parent : parent widget of this dialog +*/ ProjectPropertiesDialog::ProjectPropertiesDialog(QETProject *project, QWidget *parent) { NewDiagramPage *newDiagramPage = new NewDiagramPage(project,parent,this); ProjectAutoNumConfigPage *projectAutoNumConfigPage = new ProjectAutoNumConfigPage (project); @@ -43,34 +43,34 @@ ProjectPropertiesDialog::ProjectPropertiesDialog(QETProject *project, QWidget *p } /** - * @brief ProjectPropertiesDialog::~ProjectPropertiesDialog - */ + @brief ProjectPropertiesDialog::~ProjectPropertiesDialog +*/ ProjectPropertiesDialog::~ProjectPropertiesDialog () { delete m_properties_dialog; } /** - * @brief ProjectPropertiesDialog::exec - * execute this dialog. - */ + @brief ProjectPropertiesDialog::exec + execute this dialog. +*/ void ProjectPropertiesDialog::exec() { m_properties_dialog->setWindowModality(Qt::WindowModal); m_properties_dialog -> exec(); } /** - * @brief ProjectPropertiesDialog::setCurrentPage - * Change the current displayed page by p. - * @param p : page to display - */ + @brief ProjectPropertiesDialog::setCurrentPage + Change the current displayed page by p. + @param p : page to display +*/ void ProjectPropertiesDialog::setCurrentPage(ProjectPropertiesDialog::Page p) { m_properties_dialog -> setCurrentPage(static_cast (p)); } /** - * @brief ProjectPropertiesDialog::changeToFolio - * Change the current displayed tab to folio tab. - */ + @brief ProjectPropertiesDialog::changeToFolio + Change the current displayed tab to folio tab. +*/ void ProjectPropertiesDialog::changeToFolio() { ProjectAutoNumConfigPage *autoNumPage = static_cast (m_properties_dialog->pages.at(2)); autoNumPage->changeToTab(3); diff --git a/sources/ui/projectpropertiesdialog.h b/sources/ui/projectpropertiesdialog.h index d38cb5bed..90d7d8e90 100644 --- a/sources/ui/projectpropertiesdialog.h +++ b/sources/ui/projectpropertiesdialog.h @@ -24,9 +24,9 @@ class QWidget; class ConfigDialog; /** - * @brief The ProjectPropertiesDialog class - * this class builds a dialog to edit whole properties of a project - */ + @brief The ProjectPropertiesDialog class + this class builds a dialog to edit whole properties of a project +*/ class ProjectPropertiesDialog : public QObject { public: enum Page { diff --git a/sources/ui/shapegraphicsitempropertieswidget.cpp b/sources/ui/shapegraphicsitempropertieswidget.cpp index 69547d052..e35e2d731 100644 --- a/sources/ui/shapegraphicsitempropertieswidget.cpp +++ b/sources/ui/shapegraphicsitempropertieswidget.cpp @@ -22,11 +22,11 @@ #include "QPropertyUndoCommand/qpropertyundocommand.h" /** - * @brief ShapeGraphicsItemPropertiesWidget::ShapeGraphicsItemPropertiesWidget - * Constructor - * @param item : shape to edit - * @param parent : parent widget - */ + @brief ShapeGraphicsItemPropertiesWidget::ShapeGraphicsItemPropertiesWidget + Constructor + @param item : shape to edit + @param parent : parent widget +*/ ShapeGraphicsItemPropertiesWidget::ShapeGraphicsItemPropertiesWidget(QetShapeItem *item, QWidget *parent) : PropertiesEditorWidget(parent), ui(new Ui::ShapeGraphicsItemPropertiesWidget), @@ -45,19 +45,19 @@ ShapeGraphicsItemPropertiesWidget::ShapeGraphicsItemPropertiesWidget(QList shapes_list) { for (QMetaObject::Connection c : m_connect_list) { @@ -119,10 +119,10 @@ void ShapeGraphicsItemPropertiesWidget::setItems(QList shapes_li } /** - * @brief ShapeGraphicsItemPropertiesWidget::apply - * Apply the current change, by pushing an undo command to the - * undo stack of the shape diagram. - */ + @brief ShapeGraphicsItemPropertiesWidget::apply + Apply the current change, by pushing an undo command to the + undo stack of the shape diagram. +*/ void ShapeGraphicsItemPropertiesWidget::apply() { Diagram *d = nullptr; @@ -151,19 +151,19 @@ void ShapeGraphicsItemPropertiesWidget::apply() } /** - * @brief ShapeGraphicsItemPropertiesWidget::reset - * Reset the change - */ + @brief ShapeGraphicsItemPropertiesWidget::reset + Reset the change +*/ void ShapeGraphicsItemPropertiesWidget::reset() { updateUi(); } /** - * @brief ShapeGraphicsItemPropertiesWidget::associatedUndo - * @return an undo command that represent the change edited by this widget. - * The returned undo command is a QPropertyUndoCommand with the properties "pen". - * If there isn't change, return nullptr - */ + @brief ShapeGraphicsItemPropertiesWidget::associatedUndo + @return an undo command that represent the change edited by this widget. + The returned undo command is a QPropertyUndoCommand with the properties "pen". + If there isn't change, return nullptr +*/ QUndoCommand* ShapeGraphicsItemPropertiesWidget::associatedUndo() const { if (m_live_edit) @@ -357,8 +357,8 @@ QUndoCommand* ShapeGraphicsItemPropertiesWidget::associatedUndo() const } /** - * @brief ShapeGraphicsItemPropertiesWidget::updateUi - */ + @brief ShapeGraphicsItemPropertiesWidget::updateUi +*/ void ShapeGraphicsItemPropertiesWidget::updateUi() { if (!m_shape && m_shapes_list.isEmpty()) { @@ -455,10 +455,10 @@ void ShapeGraphicsItemPropertiesWidget::updateUi() } /** - * @brief ShapeGraphicsItemPropertiesWidget::setLiveEdit - * @param live_edit - * @return always true - */ + @brief ShapeGraphicsItemPropertiesWidget::setLiveEdit + @param live_edit + @return always true +*/ bool ShapeGraphicsItemPropertiesWidget::setLiveEdit(bool live_edit) { if (live_edit == m_live_edit) { @@ -480,9 +480,9 @@ bool ShapeGraphicsItemPropertiesWidget::setLiveEdit(bool live_edit) } /** - * @brief ShapeGraphicsItemPropertiesWidget::setUpEditConnection - * Disconnect the previous connection, and reconnect the connection between the editors widgets and void ShapeGraphicsItemPropertiesWidget::apply function - */ + @brief ShapeGraphicsItemPropertiesWidget::setUpEditConnection + Disconnect the previous connection, and reconnect the connection between the editors widgets and void ShapeGraphicsItemPropertiesWidget::apply function +*/ void ShapeGraphicsItemPropertiesWidget::setUpEditConnection() { for (QMetaObject::Connection c : m_edit_connection) { diff --git a/sources/ui/shapegraphicsitempropertieswidget.h b/sources/ui/shapegraphicsitempropertieswidget.h index f7cedd858..5f7c46617 100644 --- a/sources/ui/shapegraphicsitempropertieswidget.h +++ b/sources/ui/shapegraphicsitempropertieswidget.h @@ -27,9 +27,9 @@ namespace Ui { class QetShapeItem; /** - * @brief The ShapeGraphicsItemPropertiesWidget class - * Provide a widget to edit the properties of a QetShapeItem - */ + @brief The ShapeGraphicsItemPropertiesWidget class + Provide a widget to edit the properties of a QetShapeItem +*/ class ShapeGraphicsItemPropertiesWidget : public PropertiesEditorWidget { Q_OBJECT diff --git a/sources/ui/titleblockpropertieswidget.cpp b/sources/ui/titleblockpropertieswidget.cpp index 0103ace43..da3164c2f 100644 --- a/sources/ui/titleblockpropertieswidget.cpp +++ b/sources/ui/titleblockpropertieswidget.cpp @@ -25,12 +25,12 @@ #include /** - * @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget - * default constructor - * @param titleblock properties to edit - * @param current_date if true, display the radio button "current date" - * @param parent parent widget - */ + @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget + default constructor + @param titleblock properties to edit + @param current_date if true, display the radio button "current date" + @param parent parent widget +*/ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(const TitleBlockProperties &titleblock, bool current_date, QETProject *project, QWidget *parent) : QWidget(parent), ui(new Ui::TitleBlockPropertiesWidget) @@ -41,13 +41,13 @@ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(const TitleBlockPropertie } /** - * @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget - * default constructor with tempalte list - * @param tbt_collection template list - * @param titleblock properties to edit - * @param current_date if true, display the radio button "current date" - * @param parent parent widget - */ + @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget + default constructor with tempalte list + @param tbt_collection template list + @param titleblock properties to edit + @param current_date if true, display the radio button "current date" + @param parent parent widget +*/ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(TitleBlockTemplatesCollection *tbt_collection, const TitleBlockProperties &titleblock, bool current_date, QETProject *project, QWidget *parent) : QWidget(parent), ui(new Ui::TitleBlockPropertiesWidget) @@ -60,13 +60,13 @@ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(TitleBlockTemplatesCollec } /** - * @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget - * Default constructor with several template collection - * @param tbt_collection template list - * @param titleblock properties to edit - * @param current_date if true, display the radio button "current date" - * @param parent parent widget - */ + @brief TitleBlockPropertiesWidget::TitleBlockPropertiesWidget + Default constructor with several template collection + @param tbt_collection template list + @param titleblock properties to edit + @param current_date if true, display the radio button "current date" + @param parent parent widget +*/ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(QList tbt_collection, const TitleBlockProperties &titleblock, bool current_date, QETProject *project, QWidget *parent) : QWidget(parent), ui(new Ui::TitleBlockPropertiesWidget) @@ -80,18 +80,18 @@ TitleBlockPropertiesWidget::TitleBlockPropertiesWidget(QList m_title_le -> setText (properties.title); ui -> m_author_le -> setText (properties.author); @@ -146,9 +146,9 @@ void TitleBlockPropertiesWidget::setProperties(const TitleBlockProperties &prope } /** - * @brief TitleBlockPropertiesWidget::properties - * @return the edited properties - */ + @brief TitleBlockPropertiesWidget::properties + @return the edited properties +*/ TitleBlockProperties TitleBlockPropertiesWidget::properties() const { TitleBlockProperties prop; prop.title = ui -> m_title_le -> text(); @@ -187,9 +187,9 @@ TitleBlockProperties TitleBlockPropertiesWidget::properties() const { } /** - * @brief TitleBlockPropertiesWidget::properties - * @return return properties to enable folio autonum - */ + @brief TitleBlockPropertiesWidget::properties + @return return properties to enable folio autonum +*/ TitleBlockProperties TitleBlockPropertiesWidget::propertiesAutoNum(QString autoNum) const { TitleBlockProperties prop; prop.title = ui -> m_title_le -> text(); @@ -242,9 +242,9 @@ TitleBlockTemplateLocation TitleBlockPropertiesWidget::currentTitleBlockLocation } /** - * @brief TitleBlockPropertiesWidget::setTitleBlockTemplatesVisible - * if true, title block template combo box and menu button is visible - */ + @brief TitleBlockPropertiesWidget::setTitleBlockTemplatesVisible + if true, title block template combo box and menu button is visible +*/ void TitleBlockPropertiesWidget::setTitleBlockTemplatesVisible(const bool &visible) { ui -> m_tbt_label -> setVisible(visible); ui -> m_tbt_cb -> setVisible(visible); @@ -252,17 +252,17 @@ void TitleBlockPropertiesWidget::setTitleBlockTemplatesVisible(const bool &visib } /** - * @brief TitleBlockPropertiesWidget::setReadOnly - * if true, this widget is disable - */ + @brief TitleBlockPropertiesWidget::setReadOnly + if true, this widget is disable +*/ void TitleBlockPropertiesWidget::setReadOnly(const bool &ro) { ui->m_tbt_gb->setDisabled(ro); } /** - * @brief TitleBlockPropertiesWidget::currentTitleBlockTemplateName - * @return the current title block name - */ + @brief TitleBlockPropertiesWidget::currentTitleBlockTemplateName + @return the current title block name +*/ QString TitleBlockPropertiesWidget::currentTitleBlockTemplateName() const { int index = ui -> m_tbt_cb -> currentIndex(); if(index != -1) @@ -271,10 +271,10 @@ QString TitleBlockPropertiesWidget::currentTitleBlockTemplateName() const { } /** - * @brief TitleBlockPropertiesWidget::addCollection - * add a collection of title block available in the combo box - * @param tbt_collection - */ + @brief TitleBlockPropertiesWidget::addCollection + add a collection of title block available in the combo box + @param tbt_collection +*/ void TitleBlockPropertiesWidget::addCollection(TitleBlockTemplatesCollection *tbt_collection) { if (!tbt_collection || m_tbt_collection_list.contains(tbt_collection)) return; @@ -282,10 +282,10 @@ void TitleBlockPropertiesWidget::addCollection(TitleBlockTemplatesCollection *tb } /** - * @brief TitleBlockPropertiesWidget::initDialog - * Init this dialog - * @param current_date true for display current date radio button - */ + @brief TitleBlockPropertiesWidget::initDialog + Init this dialog + @param current_date true for display current date radio button +*/ void TitleBlockPropertiesWidget::initDialog(const bool ¤t_date, QETProject *project) { m_dcw = new DiagramContextWidget(); ui -> m_tab2_vlayout -> addWidget(m_dcw); @@ -321,12 +321,12 @@ void TitleBlockPropertiesWidget::initDialog(const bool ¤t_date, QETProjec } /** - * @brief TitleBlockPropertiesWidget::getIndexFor - * Find the index of the combo box for the title block @tbt_name available on the collection @collection - * @param tbt_name : title block name - * @param collection : title block collection - * @return the index of the title block or -1 if no match - */ + @brief TitleBlockPropertiesWidget::getIndexFor + Find the index of the combo box for the title block @tbt_name available on the collection @collection + @param tbt_name : title block name + @param collection : title block collection + @return the index of the title block or -1 if no match +*/ int TitleBlockPropertiesWidget::getIndexFor(const QString &tbt_name, const QET::QetCollection collection) const { for (int i = 0; im_tbt_cb->count(); i++) { @@ -346,9 +346,9 @@ void TitleBlockPropertiesWidget::duplicateCurrentTitleBlockTemplate() { } /** - * @brief TitleBlockPropertiesWidget::updateTemplateList - * Update the title block template list available in the combo box - */ + @brief TitleBlockPropertiesWidget::updateTemplateList + Update the title block template list available in the combo box +*/ void TitleBlockPropertiesWidget::updateTemplateList() { ui -> m_tbt_cb ->clear(); @@ -386,9 +386,9 @@ void TitleBlockPropertiesWidget::updateTemplateList() } /** - * @brief TitleBlockPropertiesWidget::changeCurrentTitleBlockTemplate - * Load the additionnal field of title block "text" - */ + @brief TitleBlockPropertiesWidget::changeCurrentTitleBlockTemplate + Load the additionnal field of title block "text" +*/ void TitleBlockPropertiesWidget::changeCurrentTitleBlockTemplate(int index) { m_dcw -> clear(); @@ -415,17 +415,17 @@ void TitleBlockPropertiesWidget::changeCurrentTitleBlockTemplate(int index) } /** - * @brief TitleBlockPropertiesWidget::on_m_date_now_pb_clicked - * Set the date to current date - */ + @brief TitleBlockPropertiesWidget::on_m_date_now_pb_clicked + Set the date to current date +*/ void TitleBlockPropertiesWidget::on_m_date_now_pb_clicked() { ui -> m_date_edit -> setDate(QDate::currentDate()); } /** - * @brief TitleBlockPropertiesWidget::on_m_edit_autofolionum_pb_clicked - * Open Auto Folio Num dialog - */ + @brief TitleBlockPropertiesWidget::on_m_edit_autofolionum_pb_clicked + Open Auto Folio Num dialog +*/ void TitleBlockPropertiesWidget::on_m_edit_autofolionum_pb_clicked() { emit openAutoNumFolioEditor(ui->auto_page_cb->currentText()); if (ui->auto_page_cb->currentText()!=tr("Créer un Folio Numérotation Auto")) diff --git a/sources/ui/xrefpropertieswidget.cpp b/sources/ui/xrefpropertieswidget.cpp index e3f3f6b1f..c0dc80330 100644 --- a/sources/ui/xrefpropertieswidget.cpp +++ b/sources/ui/xrefpropertieswidget.cpp @@ -23,11 +23,11 @@ #include /** - * @brief XRefPropertiesWidget::XRefPropertiesWidget - * Default constructor - * @param properties: properties to use - * @param parent: parent widget - */ + @brief XRefPropertiesWidget::XRefPropertiesWidget + Default constructor + @param properties: properties to use + @param parent: parent widget +*/ XRefPropertiesWidget::XRefPropertiesWidget(QHash properties, QWidget *parent) : QWidget(parent), ui(new Ui::XRefPropertiesWidget), @@ -42,9 +42,9 @@ XRefPropertiesWidget::XRefPropertiesWidget(QHash prope } /** - * @brief XRefPropertiesWidget::~XRefPropertiesWidget - * Default destructor - */ + @brief XRefPropertiesWidget::~XRefPropertiesWidget + Default destructor +*/ XRefPropertiesWidget::~XRefPropertiesWidget() { disconnect(ui->m_display_has_cross_rb, SIGNAL(toggled(bool)), ui->m_cross_properties_gb, SLOT(setEnabled(bool))); @@ -54,10 +54,10 @@ XRefPropertiesWidget::~XRefPropertiesWidget() } /** - * @brief XRefPropertiesWidget::setProperties - * set new properties for this widget - * @param properties - */ + @brief XRefPropertiesWidget::setProperties + set new properties for this widget + @param properties +*/ void XRefPropertiesWidget::setProperties(const QHash &properties) { m_properties = properties; updateDisplay(); @@ -65,19 +65,19 @@ void XRefPropertiesWidget::setProperties(const QHash & } /** - * @brief XRefPropertiesWidget::properties - * @return the properties edited by this widget - */ + @brief XRefPropertiesWidget::properties + @return the properties edited by this widget +*/ QHash XRefPropertiesWidget::properties(){ saveProperties(ui->m_type_cb->currentIndex()); return m_properties; } /** - * @brief XRefPropertiesWidget::setReadOnly - * Set all of this widget disable if true - * @param ro - */ + @brief XRefPropertiesWidget::setReadOnly + Set all of this widget disable if true + @param ro +*/ void XRefPropertiesWidget::setReadOnly(bool ro) { ui->m_type_cb->setDisabled(ro); ui->m_display_gb->setDisabled(ro); @@ -89,9 +89,9 @@ void XRefPropertiesWidget::setReadOnly(bool ro) { } /** - * @brief XRefPropertiesWidget::buildUi - * Build some widget of this ui. - */ + @brief XRefPropertiesWidget::buildUi + Build some widget of this ui. +*/ void XRefPropertiesWidget::buildUi() { ui -> m_type_cb -> addItem(tr("Bobine"), "coil"); @@ -110,10 +110,10 @@ void XRefPropertiesWidget::buildUi() } /** - * @brief XRefPropertiesWidget::saveProperties - * Save the properties of the type define at @index of the combo box m_type_cb - * @param index - */ + @brief XRefPropertiesWidget::saveProperties + Save the properties of the type define at @index of the combo box m_type_cb + @param index +*/ void XRefPropertiesWidget::saveProperties(int index) { QString type = ui->m_type_cb->itemData(index).toString(); XRefProperties xrp = m_properties[type]; @@ -145,9 +145,9 @@ void XRefPropertiesWidget::saveProperties(int index) { } /** - * @brief XRefPropertiesWidget::updateDisplay - * Update display with the curent displayed type. - */ + @brief XRefPropertiesWidget::updateDisplay + Update display with the curent displayed type. +*/ void XRefPropertiesWidget::updateDisplay() { QString type = ui->m_type_cb->itemData(ui->m_type_cb->currentIndex()).toString(); XRefProperties xrp = m_properties[type]; @@ -191,10 +191,10 @@ void XRefPropertiesWidget::updateDisplay() { } /** - * @brief XRefPropertiesWidget::typeChanged - * manage the save of the current properties, - * when the combo box of type change. - */ + @brief XRefPropertiesWidget::typeChanged + manage the save of the current properties, + when the combo box of type change. +*/ void XRefPropertiesWidget::typeChanged() { //save the properties of the previous xref type saveProperties(m_previous_type_index); @@ -206,9 +206,9 @@ void XRefPropertiesWidget::typeChanged() { } /** - * @brief XRefPropertiesWidget::enableOffsetSB - * Enable Offset SB only if Snap to Footer is selected - */ + @brief XRefPropertiesWidget::enableOffsetSB + Enable Offset SB only if Snap to Footer is selected +*/ void XRefPropertiesWidget::enableOffsetSB(int i){ if (i) ui->m_offset_sb->setEnabled(false); diff --git a/sources/ui/xrefpropertieswidget.h b/sources/ui/xrefpropertieswidget.h index 6c33bd9b3..73d33a9e9 100644 --- a/sources/ui/xrefpropertieswidget.h +++ b/sources/ui/xrefpropertieswidget.h @@ -26,9 +26,9 @@ namespace Ui { } /** - * @brief The XRefPropertiesWidget class - * This class provide a widget to edit the XRefProperties - */ + @brief The XRefPropertiesWidget class + This class provide a widget to edit the XRefProperties +*/ class XRefPropertiesWidget : public QWidget { Q_OBJECT diff --git a/sources/undocommand/changeelementinformationcommand.cpp b/sources/undocommand/changeelementinformationcommand.cpp index 930d6cec0..71f890995 100644 --- a/sources/undocommand/changeelementinformationcommand.cpp +++ b/sources/undocommand/changeelementinformationcommand.cpp @@ -21,12 +21,12 @@ #include /** - * @brief ChangeElementInformationCommand::ChangeElementInformationCommand - * Default constructor - * @param elmt : element to change information - * @param old_info : old info of element - * @param new_info : new info of element - */ + @brief ChangeElementInformationCommand::ChangeElementInformationCommand + Default constructor + @param elmt : element to change information + @param old_info : old info of element + @param new_info : new info of element +*/ ChangeElementInformationCommand::ChangeElementInformationCommand(Element *elmt, DiagramContext &old_info, DiagramContext &new_info, QUndoCommand *parent) : QUndoCommand (parent), m_element (elmt), @@ -46,16 +46,16 @@ bool ChangeElementInformationCommand::mergeWith(const QUndoCommand *other) } /** - * @brief ChangeElementInformationCommand::undo - */ + @brief ChangeElementInformationCommand::undo +*/ void ChangeElementInformationCommand::undo() { m_element -> setElementInformations(m_old_info); updateProjectDB(); } /** - * @brief ChangeElementInformationCommand::redo - */ + @brief ChangeElementInformationCommand::redo +*/ void ChangeElementInformationCommand::redo() { m_element -> setElementInformations(m_new_info); updateProjectDB(); diff --git a/sources/undocommand/changeelementinformationcommand.h b/sources/undocommand/changeelementinformationcommand.h index 38ef5cdae..654e94bd5 100644 --- a/sources/undocommand/changeelementinformationcommand.h +++ b/sources/undocommand/changeelementinformationcommand.h @@ -24,9 +24,9 @@ class Element; /** - * @brief The ChangeElementInformationCommand class - * This class manage undo/redo to change the element information. - */ + @brief The ChangeElementInformationCommand class + This class manage undo/redo to change the element information. +*/ class ChangeElementInformationCommand : public QUndoCommand { public: diff --git a/sources/undocommand/changetitleblockcommand.cpp b/sources/undocommand/changetitleblockcommand.cpp index ed009032c..5ea323484 100644 --- a/sources/undocommand/changetitleblockcommand.cpp +++ b/sources/undocommand/changetitleblockcommand.cpp @@ -20,12 +20,12 @@ #include "diagram.h" /** - * @brief ChangeTitleBlockCommand::ChangeTitleBlockCommand - * @param d - * @param old_ip - * @param new_ip - * @param parent - */ + @brief ChangeTitleBlockCommand::ChangeTitleBlockCommand + @param d + @param old_ip + @param new_ip + @param parent +*/ ChangeTitleBlockCommand::ChangeTitleBlockCommand( Diagram *d, const TitleBlockProperties &old_ip, diff --git a/sources/undocommand/changetitleblockcommand.h b/sources/undocommand/changetitleblockcommand.h index 6358b78a2..1d33098a6 100644 --- a/sources/undocommand/changetitleblockcommand.h +++ b/sources/undocommand/changetitleblockcommand.h @@ -24,9 +24,9 @@ class Diagram; /** - * @brief The ChangeTitleBlockCommand class - * This command changes the title block properties for a particular diagram. - */ + @brief The ChangeTitleBlockCommand class + This command changes the title block properties for a particular diagram. +*/ class ChangeTitleBlockCommand : public QUndoCommand { public: diff --git a/sources/undocommand/deleteqgraphicsitemcommand.cpp b/sources/undocommand/deleteqgraphicsitemcommand.cpp index aa3173450..17d965fa5 100644 --- a/sources/undocommand/deleteqgraphicsitemcommand.cpp +++ b/sources/undocommand/deleteqgraphicsitemcommand.cpp @@ -29,11 +29,11 @@ #include "qetdiagrameditor.h" /** - * @brief DeleteQGraphicsItemCommand::DeleteQGraphicsItemCommand - * @param diagram : deigram where this undo work - * @param content : content to remove - * @param parent : parent undo - */ + @brief DeleteQGraphicsItemCommand::DeleteQGraphicsItemCommand + @param diagram : deigram where this undo work + @param content : content to remove + @param parent : parent undo +*/ DeleteQGraphicsItemCommand::DeleteQGraphicsItemCommand(Diagram *diagram, const DiagramContent &content, QUndoCommand *parent) : QUndoCommand(parent), m_removed_contents(content), @@ -107,10 +107,10 @@ DeleteQGraphicsItemCommand::~DeleteQGraphicsItemCommand() { } /** - * @brief DeleteQGraphicsItemCommand::setPotentialsOfRemovedElements - * This function creates new conductors (if needed) for conserve the electrical potentials - * present at the terminals of each removed elements. - */ + @brief DeleteQGraphicsItemCommand::setPotentialsOfRemovedElements + This function creates new conductors (if needed) for conserve the electrical potentials + present at the terminals of each removed elements. +*/ void DeleteQGraphicsItemCommand::setPotentialsOfRemovedElements() { for (Element *elmt : m_removed_contents.m_elements) @@ -194,14 +194,14 @@ void DeleteQGraphicsItemCommand::setPotentialsOfRemovedElements() } /** - * @brief DeleteQGraphicsItemCommand::terminalInSamePotential - * Return a terminal at the same potential of @terminal, by traveling through the conductors connected to @terminal - * only if the owner element of the terminal is not delete by this undo command. - * Return nullptr if a terminal can't be found. - * @param terminal - terminal from search - * @param conductor_to_exclude - a conductor to exlcude from search. - * @return - */ + @brief DeleteQGraphicsItemCommand::terminalInSamePotential + Return a terminal at the same potential of @terminal, by traveling through the conductors connected to @terminal + only if the owner element of the terminal is not delete by this undo command. + Return nullptr if a terminal can't be found. + @param terminal - terminal from search + @param conductor_to_exclude - a conductor to exlcude from search. + @return +*/ Terminal *DeleteQGraphicsItemCommand::terminalInSamePotential(Terminal *terminal, Conductor *conductor_to_exclude) { QList conductor_list = terminal->conductors(); @@ -227,9 +227,9 @@ Terminal *DeleteQGraphicsItemCommand::terminalInSamePotential(Terminal *terminal } /** - * @brief DeleteQGraphicsItemCommand::undo - * Undo this command - */ + @brief DeleteQGraphicsItemCommand::undo + Undo this command +*/ void DeleteQGraphicsItemCommand::undo() { m_diagram->showMe(); @@ -265,9 +265,9 @@ void DeleteQGraphicsItemCommand::undo() } /** - * @brief DeleteQGraphicsItemCommand::redo - * Redo the delete command - */ + @brief DeleteQGraphicsItemCommand::redo + Redo the delete command +*/ void DeleteQGraphicsItemCommand::redo() { m_diagram -> showMe(); diff --git a/sources/undocommand/itemmodelcommand.cpp b/sources/undocommand/itemmodelcommand.cpp index feb4ec54e..7446d6a9e 100644 --- a/sources/undocommand/itemmodelcommand.cpp +++ b/sources/undocommand/itemmodelcommand.cpp @@ -18,11 +18,11 @@ #include "itemmodelcommand.h" /** - * @brief ModelIndexCommand::ModelIndexCommand - * @param model - * @param index - * @param parent - */ + @brief ModelIndexCommand::ModelIndexCommand + @param model + @param index + @param parent +*/ ModelIndexCommand::ModelIndexCommand(QAbstractItemModel *model, const QModelIndex &index, QUndoCommand *parent): QUndoCommand(parent), m_model(model), @@ -30,10 +30,10 @@ ModelIndexCommand::ModelIndexCommand(QAbstractItemModel *model, const QModelInde {} /** - * @brief ModelIndexCommand::setData - * @param value - * @param role - */ + @brief ModelIndexCommand::setData + @param value + @param role +*/ void ModelIndexCommand::setData(const QVariant &value, int role) { m_new_value = value; @@ -47,9 +47,9 @@ void ModelIndexCommand::setData(const QVariant &value, int role) } /** - * @brief ModelIndexCommand::redo - * Reimplemented from QUndoCommand - */ + @brief ModelIndexCommand::redo + Reimplemented from QUndoCommand +*/ void ModelIndexCommand::redo() { if (m_model && m_index.isValid()) { m_model->setData(m_index, m_new_value, m_role); @@ -57,9 +57,9 @@ void ModelIndexCommand::redo() { } /** - * @brief ModelIndexCommand::undo - * Reimplemented from QUndoCommand - */ + @brief ModelIndexCommand::undo + Reimplemented from QUndoCommand +*/ void ModelIndexCommand::undo() { if (m_model && m_index.isValid()) { m_model->setData(m_index, m_old_value, m_role); @@ -67,23 +67,23 @@ void ModelIndexCommand::undo() { } /** - * @brief ModelHeaderDataCommand::ModelHeaderDataCommand - * @param model - * @param parent - */ + @brief ModelHeaderDataCommand::ModelHeaderDataCommand + @param model + @param parent +*/ ModelHeaderDataCommand::ModelHeaderDataCommand(QAbstractItemModel *model, QUndoCommand *parent) : QUndoCommand(parent), m_model(model) {} /** - * @brief ModelHeaderDataCommand::setData - * See QAbstractItemModel::setHeaderData - * @param section - * @param orientation - * @param value - * @param role - */ + @brief ModelHeaderDataCommand::setData + See QAbstractItemModel::setHeaderData + @param section + @param orientation + @param value + @param role +*/ void ModelHeaderDataCommand::setData(int section, Qt::Orientation orientation, const QVariant &value, int role) { m_section = section; @@ -98,9 +98,9 @@ void ModelHeaderDataCommand::setData(int section, Qt::Orientation orientation, c } /** - * @brief ModelHeaderDataCommand::redo - * Reimplemented from QUndoCommand - */ + @brief ModelHeaderDataCommand::redo + Reimplemented from QUndoCommand +*/ void ModelHeaderDataCommand::redo() { if (m_model) { @@ -109,9 +109,9 @@ void ModelHeaderDataCommand::redo() } /** - * @brief ModelHeaderDataCommand::undo - * Reimplemented from QUndoCommand - */ + @brief ModelHeaderDataCommand::undo + Reimplemented from QUndoCommand +*/ void ModelHeaderDataCommand::undo() { if (m_model) { diff --git a/sources/undocommand/itemmodelcommand.h b/sources/undocommand/itemmodelcommand.h index 4f96c578d..79a92a5cf 100644 --- a/sources/undocommand/itemmodelcommand.h +++ b/sources/undocommand/itemmodelcommand.h @@ -25,9 +25,9 @@ class QAbstractItemModel; /** - * @brief The ModelIndexCommand class - * Change a data of an index of QAbstractItemModel - */ + @brief The ModelIndexCommand class + Change a data of an index of QAbstractItemModel +*/ class ModelIndexCommand : public QUndoCommand { public: @@ -46,9 +46,9 @@ class ModelIndexCommand : public QUndoCommand }; /** - * @brief The ModelHeaderDataCommand class - * Change the data of a header - */ + @brief The ModelHeaderDataCommand class + Change the data of a header +*/ class ModelHeaderDataCommand : public QUndoCommand { public: diff --git a/sources/undocommand/linkelementcommand.cpp b/sources/undocommand/linkelementcommand.cpp index a031f84ad..2cda6265e 100644 --- a/sources/undocommand/linkelementcommand.cpp +++ b/sources/undocommand/linkelementcommand.cpp @@ -23,11 +23,11 @@ #include "potentialselectordialog.h" /** - * @brief LinkElementCommand::LinkElementCommand - * Constructor - * @param element_ : element where we work the link / unlink - * @param parent : parent undo - */ + @brief LinkElementCommand::LinkElementCommand + Constructor + @param element_ : element where we work the link / unlink + @param parent : parent undo +*/ LinkElementCommand::LinkElementCommand(Element *element_, QUndoCommand *parent): QUndoCommand(parent), m_element(element_), @@ -38,10 +38,10 @@ LinkElementCommand::LinkElementCommand(Element *element_, QUndoCommand *parent): } /** - * @brief LinkElementCommand::mergeWith - * @param other try to merge this command with other - * @return true if merge with success else false - */ + @brief LinkElementCommand::mergeWith + @param other try to merge this command with other + @return true if merge with success else false +*/ bool LinkElementCommand::mergeWith(const QUndoCommand *other) { if (id() != other->id() || other->childCount()) return false; @@ -52,17 +52,17 @@ bool LinkElementCommand::mergeWith(const QUndoCommand *other) } /** - * @brief LinkElementCommand::isLinkable - * @param element_a - * @param element_b - * @param already_linked - * @return true if element_a and element_b can be linked between them. - * There is few condition to be linked : - * 1- element_a and element_b must be linkable type. (Ex : A is master and B is slave 'OK', A and B is master 'KO') - * 2- For element type slave and report (no matter if element is 'A' or 'B'), the element must be free (not connected to an element) - * 3- we can override the section 2 by set already_linked to true. In this case, if slave or report is already - * linked to the other element ('A' or 'B') return true, but if linked to another element (not 'A' or 'B') return false - */ + @brief LinkElementCommand::isLinkable + @param element_a + @param element_b + @param already_linked + @return true if element_a and element_b can be linked between them. + There is few condition to be linked : + 1- element_a and element_b must be linkable type. (Ex : A is master and B is slave 'OK', A and B is master 'KO') + 2- For element type slave and report (no matter if element is 'A' or 'B'), the element must be free (not connected to an element) + 3- we can override the section 2 by set already_linked to true. In this case, if slave or report is already + linked to the other element ('A' or 'B') return true, but if linked to another element (not 'A' or 'B') return false +*/ bool LinkElementCommand::isLinkable(Element *element_a, Element *element_b, bool already_linked) { switch(element_a->linkType()) @@ -124,11 +124,11 @@ bool LinkElementCommand::isLinkable(Element *element_a, Element *element_b, bool } /** - * @brief LinkElementCommand::setLink - * Replace all linked elements of edited element by elements stored in @element_list - * This method do several check to know if element can be linked or not. - * @param element_list - */ + @brief LinkElementCommand::setLink + Replace all linked elements of edited element by elements stored in @element_list + This method do several check to know if element can be linked or not. + @param element_list +*/ void LinkElementCommand::setLink(const QList& element_list) { m_linked_after.clear(); @@ -136,10 +136,10 @@ void LinkElementCommand::setLink(const QList& element_list) } /** - * @brief LinkElementCommand::setLink - * This is an overloaded function. - * @param element_ - */ + @brief LinkElementCommand::setLink + This is an overloaded function. + @param element_ +*/ void LinkElementCommand::setLink(Element *element_) { QList list; @@ -148,10 +148,10 @@ void LinkElementCommand::setLink(Element *element_) } /** - * @brief LinkElementCommand::unlink - * Unlink all elements of element_list from the edited element. - * @param element_list - */ + @brief LinkElementCommand::unlink + Unlink all elements of element_list from the edited element. + @param element_list +*/ void LinkElementCommand::unlink(QList element_list) { foreach(Element *elmt, element_list) @@ -159,17 +159,17 @@ void LinkElementCommand::unlink(QList element_list) } /** - * @brief LinkElementCommand::unlinkAll - * Unlink all element of the edited element - */ + @brief LinkElementCommand::unlinkAll + Unlink all element of the edited element +*/ void LinkElementCommand::unlinkAll() { m_linked_after.clear(); } /** - * @brief LinkElementCommand::undo - * Undo this command - */ + @brief LinkElementCommand::undo + Undo this command +*/ void LinkElementCommand::undo() { if(m_element->diagram()) m_element->diagram()->showMe(); @@ -178,9 +178,9 @@ void LinkElementCommand::undo() } /** - * @brief LinkElementCommand::redo - * Redo this command - */ + @brief LinkElementCommand::redo + Redo this command +*/ void LinkElementCommand::redo() { if(m_element->diagram()) m_element->diagram()->showMe(); @@ -221,13 +221,13 @@ void LinkElementCommand::redo() } /** - * @brief LinkElementCommand::setUpNewLink - * Update the content of m_link_after with the content of @element_list. - * Each linkable element (know via the static method isLinkable) is added to m_linked_after - * @already_link is used for the static method isLinkable. - * @param element_list - * @param already_link - */ + @brief LinkElementCommand::setUpNewLink + Update the content of m_link_after with the content of @element_list. + Each linkable element (know via the static method isLinkable) is added to m_linked_after + @already_link is used for the static method isLinkable. + @param element_list + @param already_link +*/ void LinkElementCommand::setUpNewLink(const QList &element_list, bool already_link) { //m_element is a master we can connect several element to it @@ -252,11 +252,11 @@ void LinkElementCommand::setUpNewLink(const QList &element_list, bool } /** - * @brief LinkElementCommand::makeLink - * Make the link between m_element and element_list; - * This method unlink elements if needed. - * @param element_list - */ + @brief LinkElementCommand::makeLink + Make the link between m_element and element_list; + This method unlink elements if needed. + @param element_list +*/ void LinkElementCommand::makeLink(const QList &element_list) { //List is empty, that mean m_element must be free, so we unlink all elements diff --git a/sources/undocommand/linkelementcommand.h b/sources/undocommand/linkelementcommand.h index 67410e826..31b1bd623 100644 --- a/sources/undocommand/linkelementcommand.h +++ b/sources/undocommand/linkelementcommand.h @@ -23,11 +23,11 @@ class Element; /** - * @brief The LinkElementCommand class - * This undo class manage link between elements. - * In the same instance of this class, we can link and unlink elements from an edited element - * This undo class support the merge. - */ + @brief The LinkElementCommand class + This undo class manage link between elements. + In the same instance of this class, we can link and unlink elements from an edited element + This undo class support the merge. +*/ class LinkElementCommand : public QUndoCommand { public: diff --git a/sources/undocommand/rotateselectioncommand.cpp b/sources/undocommand/rotateselectioncommand.cpp index 435553935..2a66cecd9 100644 --- a/sources/undocommand/rotateselectioncommand.cpp +++ b/sources/undocommand/rotateselectioncommand.cpp @@ -80,8 +80,8 @@ m_diagram(diagram) } /** - * @brief RotateSelectionCommand::undo - */ + @brief RotateSelectionCommand::undo +*/ void RotateSelectionCommand::undo() { m_diagram->showMe(); @@ -96,8 +96,8 @@ void RotateSelectionCommand::undo() } /** - * @brief RotateSelectionCommand::redo - */ + @brief RotateSelectionCommand::redo +*/ void RotateSelectionCommand::redo() { m_diagram->showMe(); @@ -111,9 +111,9 @@ void RotateSelectionCommand::redo() } /** - * @brief RotateSelectionCommand::isValid - * @return true if this command rotate a least one item. - */ + @brief RotateSelectionCommand::isValid + @return true if this command rotate a least one item. +*/ bool RotateSelectionCommand::isValid() { if(childCount()) diff --git a/sources/undocommand/rotateselectioncommand.h b/sources/undocommand/rotateselectioncommand.h index a9f0a0e30..bdf1d1b76 100644 --- a/sources/undocommand/rotateselectioncommand.h +++ b/sources/undocommand/rotateselectioncommand.h @@ -26,9 +26,9 @@ class ConductorTextItem; class QPropertyUndoCommand; /** - * @brief The RotateSelectionCommand class - * Rotate the selected items in the given diagram - */ + @brief The RotateSelectionCommand class + Rotate the selected items in the given diagram +*/ class RotateSelectionCommand : public QUndoCommand { public: diff --git a/sources/undocommand/rotatetextscommand.cpp b/sources/undocommand/rotatetextscommand.cpp index abe07a0ec..c0e46909e 100644 --- a/sources/undocommand/rotatetextscommand.cpp +++ b/sources/undocommand/rotatetextscommand.cpp @@ -25,11 +25,11 @@ #include "qtextorientationspinboxwidget.h" /** - * @brief RotateTextsCommand::RotateTextsCommand - * @param diagram : Apply the rotation to the selected texts and group of texts - * of diagram at construction time. - * @param parent : undo parent - */ + @brief RotateTextsCommand::RotateTextsCommand + @param diagram : Apply the rotation to the selected texts and group of texts + of diagram at construction time. + @param parent : undo parent +*/ RotateTextsCommand::RotateTextsCommand(Diagram *diagram, QUndoCommand *parent) : QUndoCommand(parent), m_diagram(diagram) diff --git a/sources/undocommand/rotatetextscommand.h b/sources/undocommand/rotatetextscommand.h index dcdc4798c..8ee37f3d3 100644 --- a/sources/undocommand/rotatetextscommand.h +++ b/sources/undocommand/rotatetextscommand.h @@ -26,10 +26,10 @@ class Diagram; class QParallelAnimationGroup; /** - * @brief The RotateTextsCommand class - * Open a dialog for edit the rotation of the current selected texts and texts group in diagram. - * Just instantiate this undo command and push it in a QUndoStack. - */ + @brief The RotateTextsCommand class + Open a dialog for edit the rotation of the current selected texts and texts group in diagram. + Just instantiate this undo command and push it in a QUndoStack. +*/ class RotateTextsCommand : public QUndoCommand { public: diff --git a/sources/utils/conductorcreator.h b/sources/utils/conductorcreator.h index c8f5c27af..02bc5e56b 100644 --- a/sources/utils/conductorcreator.h +++ b/sources/utils/conductorcreator.h @@ -31,10 +31,10 @@ class Conductor; /** - * @brief The ConductorCreator class - * This class create one or several or several conductors - * in a given context - */ + @brief The ConductorCreator class + This class create one or several or several conductors + in a given context +*/ class ConductorCreator { public: