![]() |
QElectroTech
0.8-dev
|
Namespaces | |
| Icons | |
Functions | |
| QString | license () |
| QString | qetCollectionToString (const QetCollection &c) |
| QET::qetCollectionToString. More... | |
| QetCollection | qetCollectionFromString (const QString &str) |
| QET::qetCollectionFromString. More... | |
| bool | lineContainsPoint (const QLineF &, const QPointF &) |
| bool | orthogonalProjection (const QPointF &, const QLineF &, QPointF *=nullptr) |
| bool | attributeIsAnInteger (const QDomElement &, const QString &, int *=nullptr) |
| bool | attributeIsAReal (const QDomElement &, const QString &, qreal *=nullptr) |
| QString | ElementsAndConductorsSentence (int elements=0, int conductors=0, int indi_texts=0, int images=0, int shapes=0, int element_text=0, int tables_count=0) |
| QET::ElementsAndConductorsSentence Permet de composer rapidement la proposition "x elements et y conducteurs" ou encore "x elements, y conducteurs et z champs de texte". More... | |
| QList< QDomElement > | findInDomElement (const QDomElement &, const QString &) |
| QList< QDomElement > | findInDomElement (const QDomElement &, const QString &, const QString &) |
| QList< QChar > | forbiddenCharacters () |
| QString | stringToFileName (const QString &) |
| QString | escapeSpaces (const QString &) |
| QString | unescapeSpaces (const QString &) |
| QString | joinWithSpaces (const QStringList &) |
| QStringList | splitWithSpaces (const QString &) |
| QString | diagramAreaToString (const QET::DiagramArea &) |
| QET::DiagramArea | diagramAreaFromString (const QString &) |
| qreal | round (qreal, qreal) |
| qreal | correctAngle (const qreal &) |
| bool | compareCanonicalFilePaths (const QString &, const QString &) |
| bool | writeXmlFile (QDomDocument &xml_doc, const QString &filepath, QString *error_message=nullptr) |
| bool | writeToFile (QDomDocument &xml_doc, QFile *file, QString *error_message=nullptr) |
| bool | eachStrIsEqual (const QStringList &qsl) |
| QET::eachStrIsEqual. More... | |
| QActionGroup * | depthActionGroup (QObject *parent=nullptr) |
| QET::depthActionGroup. More... | |
Variables | |
| const QString | version = "0.80" |
| QElectroTech version (as string, used to mark projects and elements XML documents) More... | |
| const QString | displayedVersion = "0.80-DEV" |
| QElectroTech displayed version. More... | |
This file provides useful functions and enums that may be used from anywhere else within the QElectroTech application.
This namespace is meant to delare icons used within the QElectroTech application.
| enum QET::Action |
This enums lists the various ways to handle a standard problem when copying or moving element items (collections, categories, elements).
| enum QET::DepthOption |
List the various kind of changes for the zValue.
| enum QET::DiagramArea |
| enum QET::Filtering |
| enum QET::ItemType |
| enum QET::OperationAreas |
List areas related to some common operations.
| enum QET::QetCollection |
| enum QET::ScalingMethod |
Supported types of interactive scaling, typically for a single element primitive.
enum used to specify the type of a length
| bool QET::attributeIsAnInteger | ( | const QDomElement & | e, |
| const QString & | nom_attribut, | ||
| int * | entier = nullptr |
||
| ) |
Permet de savoir si l'attribut nom_attribut d'un element XML e est bien un entier. Si oui, sa valeur est copiee dans entier.
| e | Element XML |
| nom_attribut | Nom de l'attribut a analyser |
| entier | Pointeur facultatif vers un entier |

| bool QET::attributeIsAReal | ( | const QDomElement & | e, |
| const QString & | nom_attribut, | ||
| qreal * | reel = nullptr |
||
| ) |
Permet de savoir si l'attribut nom_attribut d'un element XML e est bien un reel. Si oui, sa valeur est copiee dans reel.
| e | Element XML |
| nom_attribut | Nom de l'attribut a analyser |
| reel | Pointeur facultatif vers un double |

| bool QET::compareCanonicalFilePaths | ( | const QString & | first, |
| const QString & | second | ||
| ) |
| first | Un premier chemin vers un fichier |
| second | Un second chemin vers un fichier |

| qreal QET::correctAngle | ( | const qreal & | angle | ) |
| angle | Un angle quelconque |

| QActionGroup * QET::depthActionGroup | ( | QObject * | parent = nullptr | ) |
| parent |

| QET::DiagramArea QET::diagramAreaFromString | ( | const QString & | string | ) |
| string | une chaine representant un type de zone de schema |

| QString QET::diagramAreaToString | ( | const QET::DiagramArea & | diagram_area | ) |
| diagram_area | un type de zone de schema |

| bool QET::eachStrIsEqual | ( | const QStringList & | qsl | ) |
| qsl | list of string to compare |

| QString QET::ElementsAndConductorsSentence | ( | int | elements_count = 0, |
| int | conductors_count = 0, |
||
| int | texts_count = 0, |
||
| int | images_count = 0, |
||
| int | shapes_count = 0, |
||
| int | element_text_count = 0, |
||
| int | tables_count = 0 |
||
| ) |
QET::ElementsAndConductorsSentence Permet de composer rapidement la proposition "x elements et y conducteurs" ou encore "x elements, y conducteurs et z champs de texte".
| elements_count | nombre d'elements |
| conductors_count | nombre de conducteurs |
| texts_count | nombre de champs de texte |
| images_count | nombre d'images |
| shapes_count | |
| element_text_count | |
| tables_count |

| QString QET::escapeSpaces | ( | const QString & | string | ) |
| string | une chaine de caracteres |

| QList< QDomElement > QET::findInDomElement | ( | const QDomElement & | e, |
| const QString & | tag_name | ||
| ) |

| QList< QDomElement > QET::findInDomElement | ( | const QDomElement & | e, |
| const QString & | parent, | ||
| const QString & | children | ||
| ) |
Etant donne un element XML e, renvoie la liste de tous les elements children imbriques dans les elements parent, eux-memes enfants de l'elememt e
| e | Element XML a explorer |
| parent | tag XML intermediaire |
| children | tag XML a rechercher |
| QList< QChar > QET::forbiddenCharacters | ( | ) |

| QString QET::joinWithSpaces | ( | const QStringList & | string_list | ) |
Assemble une liste de chaines en une seule. Un espace separe chaque chaine. Les espaces et backslashes des chaines sont echappes.
| string_list | une liste de chaine |


| QString QET::license | ( | ) |

| bool QET::lineContainsPoint | ( | const QLineF & | line, |
| const QPointF & | point | ||
| ) |
| line | Un segment de droite |
| point | Un point |

| bool QET::orthogonalProjection | ( | const QPointF & | point, |
| const QLineF & | line, | ||
| QPointF * | intersection = nullptr |
||
| ) |
| point | Un point donne |
| line | Un segment de droite donnee |
| intersection | si ce pointeur est different de 0, le QPointF ainsi designe contiendra les coordonnees du projete orthogonal, meme si celui-ci n'appartient pas au segment de droite |


| QET::QetCollection QET::qetCollectionFromString | ( | const QString & | str | ) |
| str | string to convert |

| QString QET::qetCollectionToString | ( | const QetCollection & | c | ) |
| c | QetCollection value to convert |

| qreal QET::round | ( | qreal | x, |
| qreal | epsilon | ||
| ) |
Round x to the nearest multiple of the invert of epsilon. For instance, epsilon = 10 will round to 1/10 = 0.1

| QStringList QET::splitWithSpaces | ( | const QString & | string | ) |
| string | Une chaine de caracteres contenant des sous-chaines a extraire separees par des espaces non echappes. Les espaces des sous-chaines sont echappes. |


| QString QET::stringToFileName | ( | const QString & | name | ) |
Cette fonction transforme une chaine de caracteres (typiquement : un nom de schema, de projet, d'element) en un nom de fichier potable. Par nom de fichier potable, on entend un nom : ne comprenant pas de caracteres interdits sous Windows ne comprenant pas d'espace
| name | Chaine de caractere a transformer en nom de fichier potable |


| QString QET::unescapeSpaces | ( | const QString & | string | ) |
| string | une chaine de caracteres |

| bool QET::writeToFile | ( | QDomDocument & | xml_doc, |
| QFile * | file, | ||
| QString * | error_message = nullptr |
||
| ) |

| bool QET::writeXmlFile | ( | QDomDocument & | xml_doc, |
| const QString & | filepath, | ||
| QString * | error_message = nullptr |
||
| ) |
Export an XML document to an UTF-8 text file indented with 4 spaces, with LF end of lines and no BOM.
| xml_doc | An XML document to be exported |
| filepath | Path to the file to be written |
| error_message | If non-zero, will contain an error message explaining what happened when this function returns false. |

| const QString QET::displayedVersion = "0.80-DEV" |
QElectroTech displayed version.
| const QString QET::version = "0.80" |
QElectroTech version (as string, used to mark projects and elements XML documents)
1.8.18