44 QSvgHandler(QIODevice *device, QtSvg::Options options = {},
45 QtSvg::AnimatorType type = QtSvg::AnimatorType::Automatic);
46 QSvgHandler(
const QByteArray &data, QtSvg::Options options = {},
47 QtSvg::AnimatorType type = QtSvg::AnimatorType::Automatic);
48 QSvgHandler(QXmlStreamReader *
const data, QtSvg::Options options = {},
49 QtSvg::AnimatorType type = QtSvg::AnimatorType::Automatic);
52 QIODevice *device()
const;
53 QSvgDocument *document()
const;
55 inline bool ok()
const {
56 return document() != 0 && !xml->hasError();
59 inline QString errorString()
const {
return xml->errorString(); }
60 inline int lineNumber()
const {
return xml->lineNumber(); }
62 void setDefaultCoordinateSystem(QSvgUtils::LengthType type);
63 QSvgUtils::LengthType defaultCoordinateSystem()
const;
65 void pushColor(
const QColor &color);
68 QColor currentColor()
const;
70#ifndef QT_NO_CSSPARSER
71 void setInStyle(
bool b);
74 QSvgCssHandler &cssHandler();
77 void setAnimPeriod(
int start,
int end);
78 int animationDuration()
const;
80 inline QPen defaultPen()
const
81 {
return m_defaultPen; }
83 QtSvg::Options options()
const;
84 QtSvg::AnimatorType animatorType()
const;
85 bool trustedSourceMode()
const;
88 bool startElement(
const QStringView localName,
const QXmlStreamAttributes &attributes);
89 bool endElement(
const QStringView localName);
90 bool characters(
const QStringView str);
91 bool processingInstruction(
const QStringView target,
const QStringView data);
97 QStack<QSvgNode *> m_nodes;
102 QList<QSvgNode *> m_toBeResolved;
111 QStack<CurrentNode> m_skipNodes;
114
115
116
117 QStack<QSvgText::WhitespaceMode> m_whitespaceMode;
119 QSvgRefCounter<QSvgStyleProperty> m_style;
121 QSvgUtils::LengthType m_defaultCoords;
123 QStack<QColor> m_colorStack;
124 QStack<
int> m_colorTagCount;
128 QXmlStreamReader *
const xml;
129#ifndef QT_NO_CSSPARSER
131 QSvgCssHandler m_cssHandler;
134 void resolvePaintServers(QSvgNode *node,
int nestedDepth = 0);
139
140
141
142 const bool m_ownsReader;
144 const QtSvg::Options m_options;
145 const QtSvg::AnimatorType m_animatorType;