mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-19 23:20:52 +01:00
Fix some doxygen issues (~100)
This commit is contained in:
@@ -334,7 +334,7 @@ ElementsLocation ElementCollectionHandler::copy(ElementsLocation &source, Elemen
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionHandler::createDir
|
@brief ElementCollectionHandler::createDir
|
||||||
Create a directorie with name @name as child of @parent.
|
Create a directorie with name as child of parent.
|
||||||
Parent must be a directory
|
Parent must be a directory
|
||||||
@param parent : parent of the dir to create
|
@param parent : parent of the dir to create
|
||||||
@param name : name of directorie to create
|
@param name : name of directorie to create
|
||||||
@@ -395,8 +395,9 @@ ElementsLocation ElementCollectionHandler::createDir(ElementsLocation &parent, c
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionHandler::importFromProject
|
@brief ElementCollectionHandler::importFromProject
|
||||||
Import the element represented by @location to the embedded collection of @project at the same path.
|
Import the element represented by location to the embedded collection
|
||||||
@location must represente an element owned by a project 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 project : project where copy the element
|
||||||
@param location : location to copy
|
@param location : location to copy
|
||||||
@return true if import with success
|
@return true if import with success
|
||||||
@@ -438,7 +439,8 @@ bool ElementCollectionHandler::importFromProject(QETProject *project, ElementsLo
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionHandler::setNames
|
@brief ElementCollectionHandler::setNames
|
||||||
Set the names stored in @name_list as the names of the item represented by location
|
Set the names stored in name_list as the names
|
||||||
|
of the item represented by location
|
||||||
@param location : location to change the names
|
@param location : location to change the names
|
||||||
@param name_list : NamesList to use
|
@param name_list : NamesList to use
|
||||||
@return return true if success
|
@return return true if success
|
||||||
|
|||||||
@@ -39,11 +39,15 @@ void ElementCollectionItem::clearData()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionItem::lastItemForPath
|
@brief ElementCollectionItem::lastItemForPath
|
||||||
Return the last existing item in this ElementCollectionItem hierarchy according to the given path.
|
Return the last existing item in this ElementCollectionItem hierarchy
|
||||||
Next_item is the first non existing item in this hierarchy according to the given path.
|
according to the given path.
|
||||||
@param path : The path to find last item. The path must be in form : path/otherPath/.../.../myElement.elmt.
|
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
|
@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)
|
@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)
|
ElementCollectionItem *ElementCollectionItem::lastItemForPath(const QString &path, QString &no_found_path)
|
||||||
{
|
{
|
||||||
@@ -68,7 +72,7 @@ ElementCollectionItem *ElementCollectionItem::lastItemForPath(const QString &pat
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionItem::childWithCollectionName
|
@brief ElementCollectionItem::childWithCollectionName
|
||||||
Return the child with the collection name @name, else return nullptr
|
Return the child with the collection name name, else return nullptr
|
||||||
@param name
|
@param name
|
||||||
@return
|
@return
|
||||||
*/
|
*/
|
||||||
@@ -101,10 +105,10 @@ QList<QStandardItem *> ElementCollectionItem::directChilds() const
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementCollectionItem::rowForInsertItem
|
@brief ElementCollectionItem::rowForInsertItem
|
||||||
Return the row for insert a new child item to this item with name @collection_name.
|
Return the row for insert a new child item to this item with name.
|
||||||
If row can't be found (collection_name is null, or already exist) return -1;
|
@param name
|
||||||
@param collection_name
|
|
||||||
@return
|
@return
|
||||||
|
If row can't be found (name is null, or already exist) return -1;
|
||||||
*/
|
*/
|
||||||
int ElementCollectionItem::rowForInsertItem(const QString &name)
|
int ElementCollectionItem::rowForInsertItem(const QString &name)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -500,7 +500,7 @@ QList <ElementCollectionItem *> ElementsCollectionModel::items() const
|
|||||||
/**
|
/**
|
||||||
@brief ElementsCollectionModel::projectItems
|
@brief ElementsCollectionModel::projectItems
|
||||||
@param project
|
@param project
|
||||||
@return return all items for project @project. the list can be empty
|
@return return all items for project. the list can be empty
|
||||||
*/
|
*/
|
||||||
QList<ElementCollectionItem *> ElementsCollectionModel::projectItems(QETProject *project) const
|
QList<ElementCollectionItem *> ElementsCollectionModel::projectItems(QETProject *project) const
|
||||||
{
|
{
|
||||||
@@ -531,7 +531,7 @@ void ElementsCollectionModel::hideElement()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementsCollectionModel::indexFromLocation
|
@brief ElementsCollectionModel::indexFromLocation
|
||||||
Return the index who represent @location.
|
Return the index who represent location.
|
||||||
Index can be non valid
|
Index can be non valid
|
||||||
@param location
|
@param location
|
||||||
@return
|
@return
|
||||||
|
|||||||
@@ -46,7 +46,8 @@ ElementsCollectionWidget::ElementsCollectionWidget(QWidget *parent):
|
|||||||
QWidget(parent),
|
QWidget(parent),
|
||||||
m_model(nullptr)
|
m_model(nullptr)
|
||||||
{
|
{
|
||||||
//The connection in the method ElementsCollectionWidget::reload return a warning message at compilation :
|
//The connection in the method ElementsCollectionWidget::reload
|
||||||
|
//return a warning message at compilation :
|
||||||
//**********
|
//**********
|
||||||
//QObject::connect: Cannot queue arguments of type 'QVector<int>'
|
//QObject::connect: Cannot queue arguments of type 'QVector<int>'
|
||||||
//(Make sure 'QVector<int>' is registered using qRegisterMetaType().)
|
//(Make sure 'QVector<int>' is registered using qRegisterMetaType().)
|
||||||
@@ -80,7 +81,7 @@ void ElementsCollectionWidget::expandFirstItems()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementsCollectionWidget::addProject
|
@brief ElementsCollectionWidget::addProject
|
||||||
Add @project to be displayed
|
Add project to be displayed
|
||||||
@param project
|
@param project
|
||||||
*/
|
*/
|
||||||
void ElementsCollectionWidget::addProject(QETProject *project)
|
void ElementsCollectionWidget::addProject(QETProject *project)
|
||||||
@@ -105,7 +106,7 @@ void ElementsCollectionWidget::removeProject(QETProject *project) {
|
|||||||
/**
|
/**
|
||||||
@brief ElementsCollectionWidget::highlightUnusedElement
|
@brief ElementsCollectionWidget::highlightUnusedElement
|
||||||
highlight the unused element
|
highlight the unused element
|
||||||
@See ElementsCollectionModel::highlightUnusedElement()
|
@see ElementsCollectionModel::highlightUnusedElement()
|
||||||
*/
|
*/
|
||||||
void ElementsCollectionWidget::highlightUnusedElement()
|
void ElementsCollectionWidget::highlightUnusedElement()
|
||||||
{
|
{
|
||||||
@@ -115,7 +116,7 @@ void ElementsCollectionWidget::highlightUnusedElement()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementsCollectionWidget::setCurrentLocation
|
@brief ElementsCollectionWidget::setCurrentLocation
|
||||||
Set the current item to be the item for @location
|
Set the current item to be the item for location
|
||||||
@param location
|
@param location
|
||||||
*/
|
*/
|
||||||
void ElementsCollectionWidget::setCurrentLocation(
|
void ElementsCollectionWidget::setCurrentLocation(
|
||||||
@@ -771,11 +772,11 @@ void ElementsCollectionWidget::hideCollection(bool hide)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementsCollectionWidget::hideItem
|
@brief ElementsCollectionWidget::hideItem
|
||||||
Hide the item index. If @recursive is true,
|
Hide the item index. If recursive is true,
|
||||||
hide all subchilds of index
|
hide all subchilds of index
|
||||||
@param hide- true = hide , false = visible
|
@param hide : - true = hide , false = visible
|
||||||
@param index- index to hide
|
@param index : - index to hide
|
||||||
@param recursive- true = apply to child , false = only for index
|
@param recursive : - true = apply to child , false = only for index
|
||||||
*/
|
*/
|
||||||
void ElementsCollectionWidget::hideItem(bool hide,
|
void ElementsCollectionWidget::hideItem(bool hide,
|
||||||
const QModelIndex &index,
|
const QModelIndex &index,
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ void ElementsTreeView::startDrag(Qt::DropActions supportedActions)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief ElementsTreeView::startElementDrag
|
@brief ElementsTreeView::startElementDrag
|
||||||
Build a QDrag according to the content of @location
|
Build a QDrag according to the content of location
|
||||||
@param location : location to use for create the content of the QDrag
|
@param location : location to use for create the content of the QDrag
|
||||||
*/
|
*/
|
||||||
void ElementsTreeView::startElementDrag(const ElementsLocation &location)
|
void ElementsTreeView::startElementDrag(const ElementsLocation &location)
|
||||||
|
|||||||
@@ -241,7 +241,7 @@ bool FileElementCollectionItem::isCustomCollection() const
|
|||||||
/**
|
/**
|
||||||
@brief FileElementCollectionItem::addChildAtPath
|
@brief FileElementCollectionItem::addChildAtPath
|
||||||
Ask to this item item to add a child
|
Ask to this item item to add a child
|
||||||
with collection name @collection_name
|
with collection name collection_name
|
||||||
@param collection_name
|
@param collection_name
|
||||||
*/
|
*/
|
||||||
void FileElementCollectionItem::addChildAtPath(const QString &collection_name)
|
void FileElementCollectionItem::addChildAtPath(const QString &collection_name)
|
||||||
|
|||||||
@@ -25,10 +25,12 @@
|
|||||||
@brief XmlElementCollection::XmlElementCollection
|
@brief XmlElementCollection::XmlElementCollection
|
||||||
Build an empty collection.
|
Build an empty collection.
|
||||||
The collection start by :
|
The collection start by :
|
||||||
* <collection>
|
@code{xml}
|
||||||
* <category name="import>
|
<collection>
|
||||||
* </category>
|
<category name="import>
|
||||||
* </collection>
|
</category>
|
||||||
|
</collection>
|
||||||
|
@endcode
|
||||||
All elements and category are stored as child of <category name="import>
|
All elements and category are stored as child of <category name="import>
|
||||||
@param project : the project of this collection
|
@param project : the project of this collection
|
||||||
*/
|
*/
|
||||||
@@ -72,8 +74,10 @@ XmlElementCollection::XmlElementCollection(QETProject *project) :
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::XmlElementCollection
|
@brief XmlElementCollection::XmlElementCollection
|
||||||
Constructor with an collection. The tagName of @dom_element must be "collection"
|
Constructor with an collection.
|
||||||
@param dom_element -the collection in a dom_element (the dom element in cloned)
|
The tagName of dom_element must be "collection"
|
||||||
|
@param dom_element :
|
||||||
|
-the collection in a dom_element (the dom element in cloned)
|
||||||
@param project : the project of this collection
|
@param project : the project of this collection
|
||||||
*/
|
*/
|
||||||
XmlElementCollection::XmlElementCollection(const QDomElement &dom_element, QETProject *project) :
|
XmlElementCollection::XmlElementCollection(const QDomElement &dom_element, QETProject *project) :
|
||||||
@@ -108,7 +112,7 @@ QDomElement XmlElementCollection::importCategory() const {
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::childs
|
@brief XmlElementCollection::childs
|
||||||
@param parent_element
|
@param parent_element
|
||||||
@return All childs element in the @parent_element tree
|
@return All childs element in the parent_element tree
|
||||||
*/
|
*/
|
||||||
QDomNodeList XmlElementCollection::childs(const QDomElement &parent_element) const
|
QDomNodeList XmlElementCollection::childs(const QDomElement &parent_element) const
|
||||||
{
|
{
|
||||||
@@ -118,10 +122,13 @@ QDomNodeList XmlElementCollection::childs(const QDomElement &parent_element) con
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::child
|
@brief XmlElementCollection::child
|
||||||
If parent_element have child element with an attribute name = @child_name, return it, else return a null QDomElement.
|
If parent_element have child element
|
||||||
Only search for element with tag-name "category" and "element" (if child_name end with ".elmt")
|
with an attribute name = child_name, return it,
|
||||||
|
else return a null QDomElement.
|
||||||
|
Only search for element with tag-name "category" and "element"
|
||||||
|
(if child_name end with ".elmt")
|
||||||
@param parent_element : the parent DomElement where we search for child.
|
@param parent_element : the parent DomElement where we search for child.
|
||||||
@parent_element must be a child node of this XmlElementCollection.
|
parent_element must be a child node of this XmlElementCollection.
|
||||||
@param child_name : name of child to search.
|
@param child_name : name of child to search.
|
||||||
@return The child QDomElement or a null QDomElement if not found
|
@return The child QDomElement or a null QDomElement if not found
|
||||||
*/
|
*/
|
||||||
@@ -175,7 +182,7 @@ QDomElement XmlElementCollection::child(const QString &path) const
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::directories
|
@brief XmlElementCollection::directories
|
||||||
@param parent_element
|
@param parent_element
|
||||||
@return A list of directory stored in @parent_element
|
@return A list of directory stored in parent_element
|
||||||
*/
|
*/
|
||||||
QList<QDomElement> XmlElementCollection::directories(const QDomElement &parent_element) const
|
QList<QDomElement> XmlElementCollection::directories(const QDomElement &parent_element) const
|
||||||
{
|
{
|
||||||
@@ -196,7 +203,7 @@ QList<QDomElement> XmlElementCollection::directories(const QDomElement &parent_e
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::directoriesNames
|
@brief XmlElementCollection::directoriesNames
|
||||||
@param parent_element
|
@param parent_element
|
||||||
@return a list of names for every child directories of @parent_element
|
@return a list of names for every child directories of parent_element
|
||||||
*/
|
*/
|
||||||
QStringList XmlElementCollection::directoriesNames(const QDomElement &parent_element) const
|
QStringList XmlElementCollection::directoriesNames(const QDomElement &parent_element) const
|
||||||
{
|
{
|
||||||
@@ -216,7 +223,7 @@ QStringList XmlElementCollection::directoriesNames(const QDomElement &parent_ele
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::elements
|
@brief XmlElementCollection::elements
|
||||||
@param parent_element
|
@param parent_element
|
||||||
@return A list of element stored in @parent_element
|
@return A list of element stored in parent_element
|
||||||
*/
|
*/
|
||||||
QList<QDomElement> XmlElementCollection::elements(const QDomElement &parent_element) const
|
QList<QDomElement> XmlElementCollection::elements(const QDomElement &parent_element) const
|
||||||
{
|
{
|
||||||
@@ -237,7 +244,7 @@ QList<QDomElement> XmlElementCollection::elements(const QDomElement &parent_elem
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::elementsNames
|
@brief XmlElementCollection::elementsNames
|
||||||
@param parent_element
|
@param parent_element
|
||||||
@return A list of names fr every childs element of @parent_element
|
@return A list of names fr every childs element of parent_element
|
||||||
*/
|
*/
|
||||||
QStringList XmlElementCollection::elementsNames(const QDomElement &parent_element) const
|
QStringList XmlElementCollection::elementsNames(const QDomElement &parent_element) const
|
||||||
{
|
{
|
||||||
@@ -257,7 +264,7 @@ QStringList XmlElementCollection::elementsNames(const QDomElement &parent_elemen
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::element
|
@brief XmlElementCollection::element
|
||||||
@param path : path of the element in this collection
|
@param path : path of the element in this collection
|
||||||
@return the QDomElement that represent the element at path @path
|
@return the QDomElement that represent the element at path path
|
||||||
or a null QDomElement if not found or doesn't represent an element
|
or a null QDomElement if not found or doesn't represent an element
|
||||||
*/
|
*/
|
||||||
QDomElement XmlElementCollection::element(const QString &path) const
|
QDomElement XmlElementCollection::element(const QString &path) const
|
||||||
@@ -275,7 +282,7 @@ QDomElement XmlElementCollection::element(const QString &path) const
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::directory
|
@brief XmlElementCollection::directory
|
||||||
@param path : path of the directory in this collection
|
@param path : path of the directory in this collection
|
||||||
@return the QDomElement that represent the directory at path @path
|
@return the QDomElement that represent the directory at path path
|
||||||
or a null QDomElement if not found.
|
or a null QDomElement if not found.
|
||||||
*/
|
*/
|
||||||
QDomElement XmlElementCollection::directory(const QString &path) const
|
QDomElement XmlElementCollection::directory(const QString &path) const
|
||||||
@@ -291,12 +298,16 @@ QDomElement XmlElementCollection::directory(const QString &path) const
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::addElement
|
@brief XmlElementCollection::addElement
|
||||||
Add the element at location to this collection.
|
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
|
The element is copied in this collection
|
||||||
if the path is dir1/dir2/dir3/myElement.elmt, myElement is copied to this collection at the path : import/dir1/dir2/dir3/myElement.elmt
|
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 path doesn't exist, he was created.
|
||||||
If the element already exist, do nothing.
|
If the element already exist, do nothing.
|
||||||
@param location, location of the element
|
@param location, location of the element
|
||||||
@return the collection path of the added item or a null QString if element can't be added.
|
@return the collection path of the added item
|
||||||
|
or a null QString if element can't be added.
|
||||||
*/
|
*/
|
||||||
QString XmlElementCollection::addElement(ElementsLocation &location)
|
QString XmlElementCollection::addElement(ElementsLocation &location)
|
||||||
{
|
{
|
||||||
@@ -424,12 +435,15 @@ QString XmlElementCollection::addElement(ElementsLocation &location)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::addElementDefinition
|
@brief XmlElementCollection::addElementDefinition
|
||||||
Add the élément defintion @xml_definition in the directory at path @dir_path with the name @elmt_name.
|
Add the élément defintion xml_definition
|
||||||
@param dir_path : the path of the directory where we must add the element.
|
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.
|
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 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.
|
@param xml_definition : The xml definition of the element.
|
||||||
The tag name of @xml_definition must be "definition".
|
The tag name of xml_definition must be "definition".
|
||||||
@return True if the element is added with success.
|
@return True if the element is added with success.
|
||||||
*/
|
*/
|
||||||
bool XmlElementCollection::addElementDefinition(const QString &dir_path, const QString &elmt_name, const QDomElement &xml_definition)
|
bool XmlElementCollection::addElementDefinition(const QString &dir_path, const QString &elmt_name, const QDomElement &xml_definition)
|
||||||
@@ -462,7 +476,7 @@ bool XmlElementCollection::addElementDefinition(const QString &dir_path, const Q
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::removeElement
|
@brief XmlElementCollection::removeElement
|
||||||
Remove the element at path @path.
|
Remove the element at path path.
|
||||||
@param path
|
@param path
|
||||||
@return True if element is removed and emit the signal elementRemoved.
|
@return True if element is removed and emit the signal elementRemoved.
|
||||||
else false.
|
else false.
|
||||||
@@ -482,14 +496,19 @@ bool XmlElementCollection::removeElement(const QString& path)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::copy
|
@brief XmlElementCollection::copy
|
||||||
Copy the content represented by source (an element or a directory) to destination.
|
Copy the content represented by source (an element or a directory)
|
||||||
|
to destination.
|
||||||
Destination must be a directory of this collection.
|
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.
|
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 source : content to copy
|
||||||
@param destination : destination of the copy, must be a directory of this collection
|
@param destination : destination of the copy, must be a directory
|
||||||
@param rename : rename the copy with @rename else use the name of source
|
of this collection
|
||||||
@param deep_copy : if true copy all childs of source (only if source is directory)
|
@param rename : rename the copy with rename else use the name of source
|
||||||
@return the ElementLocation that represent the copy, if copy failed return a null ElementLocation
|
@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)
|
ElementsLocation XmlElementCollection::copy(ElementsLocation &source, ElementsLocation &destination, const QString& rename, bool deep_copy)
|
||||||
{
|
{
|
||||||
@@ -504,7 +523,7 @@ ElementsLocation XmlElementCollection::copy(ElementsLocation &source, ElementsLo
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::exist
|
@brief XmlElementCollection::exist
|
||||||
Return true if the path @path exist in this collection
|
Return true if the path path exist in this collection
|
||||||
@param path
|
@param path
|
||||||
@return
|
@return
|
||||||
*/
|
*/
|
||||||
@@ -552,7 +571,7 @@ bool XmlElementCollection::createDir(const QString& path, const QString& name, c
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::removeDir
|
@brief XmlElementCollection::removeDir
|
||||||
Remove the directory at path @path.
|
Remove the directory at path path.
|
||||||
@param path
|
@param path
|
||||||
@return true if successfuly removed and emit directoryRemoved(QString),
|
@return true if successfuly removed and emit directoryRemoved(QString),
|
||||||
else false.
|
else false.
|
||||||
@@ -574,7 +593,8 @@ bool XmlElementCollection::removeDir(const QString& path)
|
|||||||
If dom_element is null, return all location owned by this collection
|
If dom_element is null, return all location owned by this collection
|
||||||
dom_element must be a child of this collection.
|
dom_element must be a child of this collection.
|
||||||
@param dom_element : dom_element where we must to search location.
|
@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.
|
@param childs = if true return all childs location of dom_element,
|
||||||
|
if false, only return the direct childs location of dom_element.
|
||||||
@return
|
@return
|
||||||
*/
|
*/
|
||||||
QList<ElementsLocation> XmlElementCollection::elementsLocation(QDomElement dom_element, bool childs) const
|
QList<ElementsLocation> XmlElementCollection::elementsLocation(QDomElement dom_element, bool childs) const
|
||||||
@@ -615,7 +635,8 @@ QList<ElementsLocation> XmlElementCollection::elementsLocation(QDomElement dom_e
|
|||||||
@brief XmlElementCollection::domToLocation
|
@brief XmlElementCollection::domToLocation
|
||||||
Return the element location who represent the xml element : dom_element
|
Return the element location who represent the xml element : dom_element
|
||||||
dom_element must be owned by this collection
|
dom_element must be owned by this collection
|
||||||
@param dom_element : the dom_element of this collection that represent an element.
|
@param dom_element :
|
||||||
|
the dom_element of this collection that represent an element.
|
||||||
The tag name of dom_element must be "element"
|
The tag name of dom_element must be "element"
|
||||||
@return the element location, location can be null if fail.
|
@return the element location, location can be null if fail.
|
||||||
*/
|
*/
|
||||||
@@ -668,12 +689,14 @@ void XmlElementCollection::cleanUnusedDirectory()
|
|||||||
/**
|
/**
|
||||||
@brief XmlElementCollection::copyDirectory
|
@brief XmlElementCollection::copyDirectory
|
||||||
Copy the directory represented by source to destination.
|
Copy the directory represented by source to destination.
|
||||||
if destination have a directory with the same name as source, then this directory is removed
|
if destination have a directory with the same name as source,
|
||||||
|
then this directory is removed
|
||||||
@param source : directory to copy
|
@param source : directory to copy
|
||||||
@param destination : destination of the copy
|
@param destination : destination of the copy
|
||||||
@param rename : rename the copy with @rename else use the name of source
|
@param rename : rename the copy with rename else use the name of source
|
||||||
@param deep_copy :if true copy all childs 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
|
@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)
|
ElementsLocation XmlElementCollection::copyDirectory(ElementsLocation &source, ElementsLocation &destination, const QString& rename, bool deep_copy)
|
||||||
{
|
{
|
||||||
@@ -733,7 +756,8 @@ ElementsLocation XmlElementCollection::copyDirectory(ElementsLocation &source, E
|
|||||||
|
|
||||||
QDomNode other_collection_node = source.projectCollection()->child(source.collectionPath(false)).cloneNode(deep_copy);
|
QDomNode other_collection_node = source.projectCollection()->child(source.collectionPath(false)).cloneNode(deep_copy);
|
||||||
|
|
||||||
//We don't make a deep copy, but we must to get the local names of the copied directory
|
//We don't make a deep copy,
|
||||||
|
// but we must to get the local names of the copied directory
|
||||||
if (!deep_copy) {
|
if (!deep_copy) {
|
||||||
QDomNode names = source.projectCollection()->child(source.collectionPath(false)).namedItem("names");
|
QDomNode names = source.projectCollection()->child(source.collectionPath(false)).namedItem("names");
|
||||||
if (!names.isNull() && names.isElement())
|
if (!names.isNull() && names.isElement())
|
||||||
@@ -759,7 +783,7 @@ ElementsLocation XmlElementCollection::copyDirectory(ElementsLocation &source, E
|
|||||||
If element already exist in destination he will be replaced by the new.
|
If element already exist in destination he will be replaced by the new.
|
||||||
@param source : element to copy
|
@param source : element to copy
|
||||||
@param destination : destination of the copy
|
@param destination : destination of the copy
|
||||||
@param rename : rename the copy with @rename else use the name of source
|
@param rename : rename the copy with rename else use the name of source
|
||||||
@return The ElementsLocation of the copy
|
@return The ElementsLocation of the copy
|
||||||
*/
|
*/
|
||||||
ElementsLocation XmlElementCollection::copyElement(ElementsLocation &source, ElementsLocation &destination, const QString& rename)
|
ElementsLocation XmlElementCollection::copyElement(ElementsLocation &source, ElementsLocation &destination, const QString& rename)
|
||||||
|
|||||||
@@ -129,7 +129,7 @@ bool XmlProjectElementCollectionItem::isCollectionRoot() const
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief XmlProjectElementCollectionItem::addChildAtPath
|
@brief XmlProjectElementCollectionItem::addChildAtPath
|
||||||
Ask to this item item to add a new child with collection name @collection_name
|
Ask to this item item to add a new child with collection name collection_name
|
||||||
(the child must exist in the xml element collection)
|
(the child must exist in the xml element collection)
|
||||||
@param collection_name : name of the child item to add.
|
@param collection_name : name of the child item to add.
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ void NameListWidget::addLine()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NameListWidget::setNames
|
@brief NameListWidget::setNames
|
||||||
Set the current names of this dialog from @name_list
|
Set the current names of this dialog from name_list
|
||||||
@param name_list
|
@param name_list
|
||||||
*/
|
*/
|
||||||
void NameListWidget::setNames(const NamesList &name_list)
|
void NameListWidget::setNames(const NamesList &name_list)
|
||||||
|
|||||||
@@ -26,13 +26,17 @@
|
|||||||
/**
|
/**
|
||||||
@brief The PropertiesEditorDialog class
|
@brief The PropertiesEditorDialog class
|
||||||
Create a dialog to edit some properties of a thing.
|
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.
|
Only create a instance of this class and call exec,
|
||||||
The first argument (a template) must be a subclass of QWidget and provide the 3 methods bellow :
|
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()
|
QString::title()
|
||||||
void::apply()
|
void::apply()
|
||||||
void::reset()
|
void::reset()
|
||||||
You can subclass the interface PropertiesEditorWidget who provide all this methods.
|
You can subclass the interface PropertiesEditorWidget
|
||||||
This dialog take ownership of the editor, so the editor will be deleted by this dialog
|
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
|
class PropertiesEditorDialog : public QDialog
|
||||||
{
|
{
|
||||||
@@ -44,7 +48,8 @@ class PropertiesEditorDialog : public QDialog
|
|||||||
{
|
{
|
||||||
//Set dialog title
|
//Set dialog title
|
||||||
setWindowTitle(editor->title());
|
setWindowTitle(editor->title());
|
||||||
//Reparent the editor, to be deleted at the same time of this dialog
|
// Reparent the editor,
|
||||||
|
// to be deleted at the same time of this dialog
|
||||||
editor->setParent(this);
|
editor->setParent(this);
|
||||||
|
|
||||||
//Build the dialog
|
//Build the dialog
|
||||||
|
|||||||
@@ -80,12 +80,13 @@ void PropertiesEditorDockWidget::reset()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief PropertiesEditorDockWidget::addEditor
|
@brief PropertiesEditorDockWidget::addEditor
|
||||||
Add an @editor in this dock at @index in the main vertical layout (note the button box
|
Add an editor in this dock at index in the main vertical layout
|
||||||
are displayed at bottom of this layout by default)
|
(note the button box are displayed at bottom of this layout by default)
|
||||||
When an editor is added, we enable the button box
|
When an editor is added, we enable the button box
|
||||||
@param editor : editor to add;
|
@param editor : editor to add;
|
||||||
@param index : index of editor in the layout
|
@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)
|
@return true if was added (or already add)
|
||||||
|
or false if can't be add (editor = nullptr)
|
||||||
*/
|
*/
|
||||||
bool PropertiesEditorDockWidget::addEditor(PropertiesEditorWidget *editor, int index)
|
bool PropertiesEditorDockWidget::addEditor(PropertiesEditorWidget *editor, int index)
|
||||||
{
|
{
|
||||||
@@ -107,7 +108,8 @@ QList<PropertiesEditorWidget *> PropertiesEditorDockWidget::editors() const {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief PropertiesEditorDockWidget::removeEditor
|
@brief PropertiesEditorDockWidget::removeEditor
|
||||||
Remove @editor from this dock. The editor wasn't delete a the end of this method
|
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
|
If the editor was the last on this widget, we disabled the button box
|
||||||
@param editor : editor to remove
|
@param editor : editor to remove
|
||||||
@return true on success, else false
|
@return true on success, else false
|
||||||
|
|||||||
@@ -48,10 +48,13 @@ QString PropertiesEditorWidget::title() const {
|
|||||||
/**
|
/**
|
||||||
@brief PropertiesEditorWidget::setLiveEdit
|
@brief PropertiesEditorWidget::setLiveEdit
|
||||||
Set the editor in live edit mode.
|
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).
|
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.
|
If live edit can be enable, return true, else false.
|
||||||
By default this method do nothing and return false (live edit is disable).
|
By default this method do nothing and return false
|
||||||
Herited class of PropertiesEditorWidget must reimplemente this methode to manage the live edit mode.
|
(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
|
@param live_edit true to enable live edit
|
||||||
@return true if live edit is enable, else false.
|
@return true if live edit is enable, else false.
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
/**
|
/**
|
||||||
@brief QPropertyUndoCommand::QPropertyUndoCommand
|
@brief QPropertyUndoCommand::QPropertyUndoCommand
|
||||||
Default constructor with old and new value
|
Default constructor with old and new value
|
||||||
This command don't take ownership of @object
|
This command don't take ownership of object
|
||||||
@param object
|
@param object
|
||||||
@param old_value
|
@param old_value
|
||||||
@param new_value
|
@param new_value
|
||||||
@@ -38,7 +38,7 @@ QPropertyUndoCommand::QPropertyUndoCommand(QObject *object, const char *property
|
|||||||
@brief QPropertyUndoCommand::QPropertyUndoCommand
|
@brief QPropertyUndoCommand::QPropertyUndoCommand
|
||||||
Default constructor with old value.
|
Default constructor with old value.
|
||||||
Call setNewValue to setup the new value of the edited QObject
|
Call setNewValue to setup the new value of the edited QObject
|
||||||
This command don't take ownership of @object
|
This command don't take ownership of object
|
||||||
@param object
|
@param object
|
||||||
@param old_value
|
@param old_value
|
||||||
@param parent
|
@param parent
|
||||||
@@ -63,7 +63,7 @@ QPropertyUndoCommand::QPropertyUndoCommand(const QPropertyUndoCommand *other)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief QPropertyUndoCommand::setNewValue
|
@brief QPropertyUndoCommand::setNewValue
|
||||||
Set the new value of the property (set with redo) to @new_value
|
Set the new value of the property (set with redo) to new_value
|
||||||
@param new_value
|
@param new_value
|
||||||
*/
|
*/
|
||||||
void QPropertyUndoCommand::setNewValue(const QVariant &new_value) {
|
void QPropertyUndoCommand::setNewValue(const QVariant &new_value) {
|
||||||
|
|||||||
@@ -22,7 +22,8 @@
|
|||||||
@brief QWidgetAnimation::QWidgetAnimation
|
@brief QWidgetAnimation::QWidgetAnimation
|
||||||
@param widget : widget to animate
|
@param widget : widget to animate
|
||||||
@param orientation : animate widget horizontally or vertically
|
@param orientation : animate widget horizontally or vertically
|
||||||
@param duration : the duration of animation @see void QVariantAnimation::setDuration(int msecs)
|
@param duration : the duration of animation
|
||||||
|
@see void QVariantAnimation::setDuration(int msecs)
|
||||||
*/
|
*/
|
||||||
QWidgetAnimation::QWidgetAnimation(QWidget *widget, Qt::Orientation orientation, QWidgetAnimation::Behavior behavior, int duration) :
|
QWidgetAnimation::QWidgetAnimation(QWidget *widget, Qt::Orientation orientation, QWidgetAnimation::Behavior behavior, int duration) :
|
||||||
QPropertyAnimation(widget),
|
QPropertyAnimation(widget),
|
||||||
@@ -149,7 +150,7 @@ void QWidgetAnimation::setHidden(bool hidden)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief QWidgetAnimation::setLastShowSize
|
@brief QWidgetAnimation::setLastShowSize
|
||||||
Force the last show size value to @size
|
Force the last show size value to size
|
||||||
@param size
|
@param size
|
||||||
*/
|
*/
|
||||||
void QWidgetAnimation::setLastShowSize(int size)
|
void QWidgetAnimation::setLastShowSize(int size)
|
||||||
|
|||||||
@@ -25,15 +25,22 @@
|
|||||||
/**
|
/**
|
||||||
@brief The QWidgetAnimation class
|
@brief The QWidgetAnimation class
|
||||||
This class animate the show and hide function of a QWidget.
|
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.
|
The role of behavior is to calcul as best the animation process
|
||||||
Because this class don't change the current and final size of the widget but her maximum size during 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.
|
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 minimumSizeHint : the final size of the widget
|
||||||
Behavior availableSpace : the final size of widget will be the available size of her parent.
|
will be his minimum size hint.
|
||||||
Since parent can have other widgets you can add a QVector of widget to subtract of the final size.
|
Behavior availableSpace : the final size of widget will be
|
||||||
Because we suppose the animated widget will take the maximum available space, we subtract the minimum size hint of widgets in QVector.
|
the available size of her parent.
|
||||||
Behavior lastSize : The widget will have the same size as the last time he was showed.
|
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
|
class QWidgetAnimation : public QPropertyAnimation
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ QRectF QetGraphicsHandlerUtility::mirrorRectForPosAtIndex(const QRectF &old_rect
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief QetGraphicsHandlerUtility::lineForPosAtIndex
|
@brief QetGraphicsHandlerUtility::lineForPosAtIndex
|
||||||
Return a line after modification of @pos at index @index of @old_line.
|
Return a line after modification of pos at index index of old_line.
|
||||||
@param old_line
|
@param old_line
|
||||||
@param pos
|
@param pos
|
||||||
@param index
|
@param index
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ SearchAndReplaceWorker::SearchAndReplaceWorker()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWorker::replaceDiagram
|
@brief SearchAndReplaceWorker::replaceDiagram
|
||||||
Replace all properties of each diagram in @diagram_list,
|
Replace all properties of each diagram in diagram_list,
|
||||||
by the current titleblock propertie of this worker
|
by the current titleblock propertie of this worker
|
||||||
@param diagram_list, list of diagram to be changed,
|
@param diagram_list, list of diagram to be changed,
|
||||||
all diagrams must belong to the same project;
|
all diagrams must belong to the same project;
|
||||||
@@ -93,7 +93,7 @@ void SearchAndReplaceWorker::replaceDiagram(Diagram *diagram)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWorker::replaceElement
|
@brief SearchAndReplaceWorker::replaceElement
|
||||||
Replace all properties of each elements in @list
|
Replace all properties of each elements in list
|
||||||
All element must belong to the same project,
|
All element must belong to the same project,
|
||||||
if not this function do nothing.
|
if not this function do nothing.
|
||||||
All change are made through a undo command append
|
All change are made through a undo command append
|
||||||
@@ -151,7 +151,7 @@ void SearchAndReplaceWorker::replaceElement(Element *element)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWorker::replaceIndiText
|
@brief SearchAndReplaceWorker::replaceIndiText
|
||||||
Replace all displayed text of independent text of @list
|
Replace all displayed text of independent text of list
|
||||||
Each must belong to the same project, if not this function do nothing
|
Each must belong to the same project, if not this function do nothing
|
||||||
@param list
|
@param list
|
||||||
*/
|
*/
|
||||||
@@ -187,7 +187,7 @@ void SearchAndReplaceWorker::replaceIndiText(IndependentTextItem *text)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWorker::replaceConductor
|
@brief SearchAndReplaceWorker::replaceConductor
|
||||||
Replace all properties of each conductor in @list
|
Replace all properties of each conductor in list
|
||||||
All conductor must belong to the same project,
|
All conductor must belong to the same project,
|
||||||
if not this function do nothing.
|
if not this function do nothing.
|
||||||
All change are made through a undo command append
|
All change are made through a undo command append
|
||||||
@@ -394,7 +394,7 @@ ConductorProperties SearchAndReplaceWorker::invalidConductorProperties()
|
|||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWorker::applyChange
|
@brief SearchAndReplaceWorker::applyChange
|
||||||
@param original : the original properties
|
@param original : the original properties
|
||||||
@param change : the change properties, to be merged with @original
|
@param change : the change properties, to be merged with original
|
||||||
@return a new conductor properties with the change applyed.
|
@return a new conductor properties with the change applyed.
|
||||||
*/
|
*/
|
||||||
ConductorProperties SearchAndReplaceWorker::applyChange(const ConductorProperties &original, const ConductorProperties &change)
|
ConductorProperties SearchAndReplaceWorker::applyChange(const ConductorProperties &original, const ConductorProperties &change)
|
||||||
@@ -443,7 +443,7 @@ QString SearchAndReplaceWorker::applyChange(const QString &original, const QStri
|
|||||||
@brief SearchAndReplaceWorker::replaceAdvanced
|
@brief SearchAndReplaceWorker::replaceAdvanced
|
||||||
@param diagram
|
@param diagram
|
||||||
@return the titleblock properties with the change applied,
|
@return the titleblock properties with the change applied,
|
||||||
according to the state of @m_advanced_struct
|
according to the state of m_advanced_struct
|
||||||
*/
|
*/
|
||||||
TitleBlockProperties SearchAndReplaceWorker::replaceAdvanced(Diagram *diagram)
|
TitleBlockProperties SearchAndReplaceWorker::replaceAdvanced(Diagram *diagram)
|
||||||
{
|
{
|
||||||
@@ -469,7 +469,7 @@ TitleBlockProperties SearchAndReplaceWorker::replaceAdvanced(Diagram *diagram)
|
|||||||
@brief SearchAndReplaceWorker::replaceAdvanced
|
@brief SearchAndReplaceWorker::replaceAdvanced
|
||||||
@param element
|
@param element
|
||||||
@return The diagram context with the change applied,
|
@return The diagram context with the change applied,
|
||||||
according to the state of @m_advanced_struct
|
according to the state of m_advanced_struct
|
||||||
*/
|
*/
|
||||||
DiagramContext SearchAndReplaceWorker::replaceAdvanced(Element *element)
|
DiagramContext SearchAndReplaceWorker::replaceAdvanced(Element *element)
|
||||||
{
|
{
|
||||||
@@ -494,7 +494,7 @@ DiagramContext SearchAndReplaceWorker::replaceAdvanced(Element *element)
|
|||||||
@brief SearchAndReplaceWorker::replaceAdvanced
|
@brief SearchAndReplaceWorker::replaceAdvanced
|
||||||
@param conductor
|
@param conductor
|
||||||
@return the conductor properties with the change applied,
|
@return the conductor properties with the change applied,
|
||||||
according to the state of @m_advanced_struct
|
according to the state of m_advanced_struct
|
||||||
*/
|
*/
|
||||||
ConductorProperties SearchAndReplaceWorker::replaceAdvanced(Conductor *conductor)
|
ConductorProperties SearchAndReplaceWorker::replaceAdvanced(Conductor *conductor)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -309,7 +309,7 @@ void SearchAndReplaceWidget::fillItemsList()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWidget::addElement
|
@brief SearchAndReplaceWidget::addElement
|
||||||
Add a tree widget item for @element
|
Add a tree widget item for element
|
||||||
@param element
|
@param element
|
||||||
*/
|
*/
|
||||||
void SearchAndReplaceWidget::addElement(Element *element)
|
void SearchAndReplaceWidget::addElement(Element *element)
|
||||||
@@ -434,7 +434,7 @@ void SearchAndReplaceWidget::search()
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWidget::setVisibleAllParents
|
@brief SearchAndReplaceWidget::setVisibleAllParents
|
||||||
Set visible all parents of @item until the invisible root item
|
Set visible all parents of item until the invisible root item
|
||||||
@param item
|
@param item
|
||||||
@param expend_parent
|
@param expend_parent
|
||||||
*/
|
*/
|
||||||
@@ -452,8 +452,8 @@ void SearchAndReplaceWidget::setVisibleAllParents(QTreeWidgetItem *item,
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWidget::nextItem
|
@brief SearchAndReplaceWidget::nextItem
|
||||||
@param item : find the next item from @item,
|
@param item : find the next item from item,
|
||||||
if @item is nullptr, start the search for the root of the tree
|
if item is nullptr, start the search for the root of the tree
|
||||||
@param flags
|
@param flags
|
||||||
@return the next item according to flag
|
@return the next item according to flag
|
||||||
or nullptr if there is not a next item
|
or nullptr if there is not a next item
|
||||||
@@ -485,8 +485,8 @@ QTreeWidgetItem *SearchAndReplaceWidget::nextItem(
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief SearchAndReplaceWidget::previousItem
|
@brief SearchAndReplaceWidget::previousItem
|
||||||
@param item : find the previous item from @item,
|
@param item : find the previous item from item,
|
||||||
if @item is nullptr, start the search for the root of the tree
|
if item is nullptr, start the search for the root of the tree
|
||||||
@param flags
|
@param flags
|
||||||
@return the previous item according to flag
|
@return the previous item according to flag
|
||||||
or nullptr if there is not a previous item
|
or nullptr if there is not a previous item
|
||||||
|
|||||||
@@ -174,7 +174,7 @@ namespace autonum
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief AssignVariables::formulaToLabel
|
@brief AssignVariables::formulaToLabel
|
||||||
Return the @formula with variable assigned
|
Return the formula with variable assigned
|
||||||
(ready to be displayed)
|
(ready to be displayed)
|
||||||
@param formula - the formula to work
|
@param formula - the formula to work
|
||||||
@param seqStruct - struct where is stocked int values
|
@param seqStruct - struct where is stocked int values
|
||||||
@@ -199,7 +199,7 @@ namespace autonum
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief AssignVariables::replaceVariable
|
@brief AssignVariables::replaceVariable
|
||||||
Replace the variables in @formula in form %{my-var}
|
Replace the variables in formula in form %{my-var}
|
||||||
to the corresponding value stored in dc
|
to the corresponding value stored in dc
|
||||||
@param formula
|
@param formula
|
||||||
@param dc
|
@param dc
|
||||||
@@ -354,7 +354,7 @@ namespace autonum
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief setSequentialToList
|
@brief setSequentialToList
|
||||||
Append all sequential of type @type owned by @context in list
|
Append all sequential of type type owned by context in list
|
||||||
@param list : list to have value inserted
|
@param list : list to have value inserted
|
||||||
@param context : numerotation context to retrieve value
|
@param context : numerotation context to retrieve value
|
||||||
@param type : type of sequential
|
@param type : type of sequential
|
||||||
@@ -379,7 +379,7 @@ namespace autonum
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief setFolioSequentialToHash
|
@brief setFolioSequentialToHash
|
||||||
Insert all value of @list in @hash with key @autoNumName
|
Insert all value of list in hash with key autoNumName
|
||||||
@param list : list to get values from
|
@param list : list to get values from
|
||||||
@param hash : hash to have values inserted
|
@param hash : hash to have values inserted
|
||||||
@param autoNumName : name to use as key of hash
|
@param autoNumName : name to use as key of hash
|
||||||
@@ -542,7 +542,7 @@ namespace autonum
|
|||||||
@param location
|
@param location
|
||||||
@return the prefix for an element represented by location,
|
@return the prefix for an element represented by location,
|
||||||
prefix can be null.
|
prefix can be null.
|
||||||
Search for a prefix only if @location represent
|
Search for a prefix only if location represent
|
||||||
an element embedded in a project
|
an element embedded in a project
|
||||||
*/
|
*/
|
||||||
QString elementPrefixForLocation(const ElementsLocation &location)
|
QString elementPrefixForLocation(const ElementsLocation &location)
|
||||||
|
|||||||
@@ -59,7 +59,8 @@ bool NumerotationContext::addValue(const QString &type, const QVariant &value, c
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::operator []
|
@brief NumerotationContext::operator []
|
||||||
@return the string at position @i
|
@param i
|
||||||
|
@return the string at position i
|
||||||
*/
|
*/
|
||||||
QString NumerotationContext::operator [] (const int &i) const {
|
QString NumerotationContext::operator [] (const int &i) const {
|
||||||
return (content_.at(i));
|
return (content_.at(i));
|
||||||
@@ -90,7 +91,8 @@ bool NumerotationContext::isEmpty() const {
|
|||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::itemAt
|
@brief NumerotationContext::itemAt
|
||||||
@return the content at position @i 1:type 2:value 3:increase
|
@param i
|
||||||
|
@return the content at position i 1:type 2:value 3:increase
|
||||||
*/
|
*/
|
||||||
QStringList NumerotationContext::itemAt(const int i) const {
|
QStringList NumerotationContext::itemAt(const int i) const {
|
||||||
return (content_.at(i).split("|"));
|
return (content_.at(i).split("|"));
|
||||||
@@ -114,7 +116,7 @@ QString NumerotationContext::validRegExpNumber() const {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::keyIsAcceptable
|
@brief NumerotationContext::keyIsAcceptable
|
||||||
@return true if @type is acceptable
|
@return true if type is acceptable
|
||||||
*/
|
*/
|
||||||
bool NumerotationContext::keyIsAcceptable(const QString &type) const {
|
bool NumerotationContext::keyIsAcceptable(const QString &type) const {
|
||||||
return (type.contains(QRegExp(validRegExpNum())));
|
return (type.contains(QRegExp(validRegExpNum())));
|
||||||
@@ -122,7 +124,7 @@ bool NumerotationContext::keyIsAcceptable(const QString &type) const {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::keyIsNumber
|
@brief NumerotationContext::keyIsNumber
|
||||||
@return true if @type represent a number
|
@return true if type represent a number
|
||||||
*/
|
*/
|
||||||
bool NumerotationContext::keyIsNumber(const QString &type) const {
|
bool NumerotationContext::keyIsNumber(const QString &type) const {
|
||||||
return (type.contains(QRegExp(validRegExpNumber())));
|
return (type.contains(QRegExp(validRegExpNumber())));
|
||||||
@@ -130,7 +132,7 @@ bool NumerotationContext::keyIsNumber(const QString &type) const {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::toXml
|
@brief NumerotationContext::toXml
|
||||||
Save the numerotation context in a QDomElement under the element name @str
|
Save the numerotation context in a QDomElement under the element name str
|
||||||
*/
|
*/
|
||||||
QDomElement NumerotationContext::toXml(QDomDocument &d, const QString& str) {
|
QDomElement NumerotationContext::toXml(QDomDocument &d, const QString& str) {
|
||||||
QDomElement num_auto = d.createElement(str);
|
QDomElement num_auto = d.createElement(str);
|
||||||
@@ -152,7 +154,7 @@ QDomElement NumerotationContext::toXml(QDomDocument &d, const QString& str) {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContext::fromXml
|
@brief NumerotationContext::fromXml
|
||||||
load numerotation context from @e
|
load numerotation context from e
|
||||||
*/
|
*/
|
||||||
void NumerotationContext::fromXml(QDomElement &e) {
|
void NumerotationContext::fromXml(QDomElement &e) {
|
||||||
clear();
|
clear();
|
||||||
@@ -163,7 +165,7 @@ void NumerotationContext::fromXml(QDomElement &e) {
|
|||||||
@brief NumerotationContext::replaceValue
|
@brief NumerotationContext::replaceValue
|
||||||
This class replaces the current NC field value with content
|
This class replaces the current NC field value with content
|
||||||
@param index of NC Item
|
@param index of NC Item
|
||||||
@param QString content to replace current value
|
@param content to replace current value
|
||||||
*/
|
*/
|
||||||
void NumerotationContext::replaceValue(int index, QString content) {
|
void NumerotationContext::replaceValue(int index, QString content) {
|
||||||
QString sep = "|";
|
QString sep = "|";
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ QString NumerotationContextCommands::toRepresentedString() {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumerotationContextCommands::setNumStrategy
|
@brief NumerotationContextCommands::setNumStrategy
|
||||||
apply the good strategy relative to @str
|
apply the good strategy relative to str
|
||||||
*/
|
*/
|
||||||
void NumerotationContextCommands::setNumStrategy(const QString &str) {
|
void NumerotationContextCommands::setNumStrategy(const QString &str) {
|
||||||
if (strategy_) delete strategy_;
|
if (strategy_) delete strategy_;
|
||||||
@@ -159,7 +159,7 @@ NumStrategy::~NumStrategy() {}
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumStrategy::nextString
|
@brief NumStrategy::nextString
|
||||||
@return the next value of @nc at position @i
|
@return the next value of nc at position i
|
||||||
*/
|
*/
|
||||||
NumerotationContext NumStrategy::nextString (const NumerotationContext &nc, const int i) const {
|
NumerotationContext NumStrategy::nextString (const NumerotationContext &nc, const int i) const {
|
||||||
QStringList strl = nc.itemAt(i);
|
QStringList strl = nc.itemAt(i);
|
||||||
@@ -182,7 +182,7 @@ NumerotationContext NumStrategy::nextNumber (const NumerotationContext &nc, cons
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief NumStrategy::previousNumber
|
@brief NumStrategy::previousNumber
|
||||||
@return the previous value of @nc at position @i
|
@return the previous value of nc at position i
|
||||||
*/
|
*/
|
||||||
NumerotationContext NumStrategy::previousNumber(const NumerotationContext &nc, const int i) const {
|
NumerotationContext NumStrategy::previousNumber(const NumerotationContext &nc, const int i) const {
|
||||||
QStringList strl = nc.itemAt(i);
|
QStringList strl = nc.itemAt(i);
|
||||||
|
|||||||
@@ -182,14 +182,14 @@ void AutoNumberingManagementW::on_m_apply_project_rb_clicked() {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
@brief AutoNumberingManagementW::on_buttonBox_clicked
|
@brief AutoNumberingManagementW::on_buttonBox_clicked
|
||||||
Action on @buttonBox clicked
|
Action on buttonBox clicked
|
||||||
@param button
|
@param button
|
||||||
*/
|
*/
|
||||||
void AutoNumberingManagementW::on_buttonBox_clicked(QAbstractButton *button) {
|
void AutoNumberingManagementW::on_buttonBox_clicked(QAbstractButton *button) {
|
||||||
//transform button to int
|
//transform button to int
|
||||||
int answer = ui -> buttonBox -> buttonRole(button);
|
int answer = ui -> buttonBox -> buttonRole(button);
|
||||||
switch (answer) {
|
switch (answer) {
|
||||||
//apply the context in the diagram displayed by @diagram_chooser.
|
//apply the context in the diagram displayed by diagram_chooser.
|
||||||
case QDialogButtonBox::ApplyRole:
|
case QDialogButtonBox::ApplyRole:
|
||||||
applyEnable(false);
|
applyEnable(false);
|
||||||
emit applyPressed();
|
emit applyPressed();
|
||||||
|
|||||||
Reference in New Issue
Block a user