Class TerminalStripLayoutPattern can be save/load from xml

Add a new class TerminalStripLayoutPatternXml used to
save / load a TerminalStripLayoutPattern class into a xml.

Also create the namespace QETSVG used to read/write some
svg element / attribute to xml. This class is used by the
class TerminalStripLayoutPatternXml.
This commit is contained in:
joshua
2025-06-05 23:04:56 +02:00
parent 2c1b840f9c
commit 95e401a266
8 changed files with 547 additions and 2 deletions

View File

@@ -94,6 +94,12 @@ namespace QETXML
QDomElement qGraphicsItemPosToXml(QGraphicsItem *item, QDomDocument &document);
bool qGraphicsItemPosFromXml(QGraphicsItem *item, const QDomElement &xml_elmt);
void orientationToAttribute(const Qt::Orientation &orientation, QDomElement &element);
Qt::Orientation orientationFromAttribute(const QDomElement &element, Qt::Orientation def_value = Qt::Vertical);
void alignmentToAttribute(const Qt::Alignment &alignment, QDomElement &element);
Qt::Alignment alignmentFromAttribute (const QDomElement &element);
QString boolToString(bool value);
bool boolFromString(const QString &value,
bool default_value = true,