![]() |
Qt 6.x
The Qt SDK
|
#include <qsvgnode_p.h>
Public Types | |
enum | Type { DOC , G , DEFS , SWITCH , ANIMATION , ARC , CIRCLE , ELLIPSE , IMAGE , LINE , PATH , POLYGON , POLYLINE , RECT , TEXT , TEXTAREA , TSPAN , USE , VIDEO } |
enum | DisplayMode { InlineMode , BlockMode , ListItemMode , RunInMode , CompactMode , MarkerMode , TableMode , InlineTableMode , TableRowGroupMode , TableHeaderGroupMode , TableFooterGroupMode , TableRowMode , TableColumnGroupMode , TableColumnMode , TableCellMode , TableCaptionMode , NoneMode , InheritMode } |
Static Protected Member Functions | |
static qreal | strokeWidth (QPainter *p) |
Protected Attributes | |
QSvgStyle | m_style |
Friends | |
class | QSvgTinyDocument |
Definition at line 29 of file qsvgnode_p.h.
Definition at line 54 of file qsvgnode_p.h.
enum QSvgNode::Type |
Enumerator | |
---|---|
DOC | |
G | |
DEFS | |
SWITCH | |
ANIMATION | |
ARC | |
CIRCLE | |
ELLIPSE | |
IMAGE | |
LINE | |
PATH | |
POLYGON | |
POLYLINE | |
RECT | |
TEXT | |
TEXTAREA | |
TSPAN | |
USE | |
VIDEO |
Definition at line 32 of file qsvgnode_p.h.
QT_BEGIN_NAMESPACE QSvgNode::QSvgNode | ( | QSvgNode * | parent = 0 | ) |
Definition at line 22 of file qsvgnode.cpp.
|
virtual |
Definition at line 29 of file qsvgnode.cpp.
void QSvgNode::appendStyleProperty | ( | QSvgStyleProperty * | prop, |
const QString & | id | ||
) |
Definition at line 45 of file qsvgnode.cpp.
References QSvgTinyDocument::addNamedStyle(), QSvgStyleProperty::ANIMATE_COLOR, QSvgStyleProperty::ANIMATE_TRANSFORM, QSvgStyle::animateColor, QSvgStyle::animateTransforms, QList< T >::append(), QSvgStyleProperty::COMP_OP, QSvgStyle::compop, document(), QSvgStyleProperty::FILL, QSvgStyle::fill, QSvgStyleProperty::FONT, QSvgStyle::font, QSvgStyleProperty::GRADIENT, QSvgStyle::gradient, m_style, QSvgStyleProperty::OPACITY, QSvgStyle::opacity, qDebug, QSvgStyleProperty::QUALITY, QSvgStyle::quality, QSvgStyleProperty::SOLID_COLOR, QSvgStyle::solidColor, QSvgStyleProperty::STROKE, QSvgStyle::stroke, QSvgStyleProperty::TRANSFORM, QSvgStyle::transform, QSvgStyleProperty::type(), QSvgStyleProperty::VIEWPORT_FILL, and QSvgStyle::viewportFill.
Referenced by parseBrush(), parseCompOp(), parseFont(), parseOpacity(), parsePen(), parseRenderingHints(), parseTransform(), and QSvgHandler::startElement().
void QSvgNode::applyStyle | ( | QPainter * | p, |
QSvgExtraStates & | states | ||
) | const |
Definition at line 99 of file qsvgnode.cpp.
References QSvgStyle::apply(), and m_style.
Referenced by QSvgTinyDocument::draw(), QSvgTinyDocument::draw(), QSvgArc::draw(), QSvgEllipse::draw(), QSvgImage::draw(), QSvgLine::draw(), QSvgPath::draw(), QSvgPolygon::draw(), QSvgPolyline::draw(), QSvgRect::draw(), QSvgUse::draw(), QSvgVideo::draw(), QSvgG::draw(), QSvgSwitch::draw(), transformedBounds(), and transformedBounds().
|
virtual |
Reimplemented in QSvgArc, QSvgEllipse, QSvgImage, QSvgLine, QSvgPath, QSvgPolygon, QSvgPolyline, QSvgRect, QSvgText, QSvgUse, and QSvgStructureNode.
Definition at line 185 of file qsvgnode.cpp.
Referenced by fastBounds(), and transformedBounds().
QSvgNode::DisplayMode QSvgNode::displayMode | ( | ) | const |
Definition at line 316 of file qsvgnode.cpp.
Referenced by QSvgTinyDocument::draw(), QSvgTinyDocument::draw(), QSvgG::draw(), and QSvgSwitch::draw().
QSvgTinyDocument * QSvgNode::document | ( | ) | const |
Definition at line 219 of file qsvgnode.cpp.
References DOC, parent(), and type().
Referenced by QSvgStructureNode::addChild(), appendStyleProperty(), QSvgStyle::apply(), QSvgAnimateColor::apply(), parseFont(), QSvgAnimateTransform::resolveMatrix(), QSvgStructureNode::scopeNode(), and styleProperty().
|
pure virtual |
Implemented in QSvgTspan, QSvgTinyDocument, QSvgAnimation, QSvgArc, QSvgEllipse, QSvgImage, QSvgLine, QSvgPath, QSvgPolygon, QSvgPolyline, QSvgRect, QSvgText, QSvgUse, QSvgVideo, QSvgG, QSvgDefs, and QSvgSwitch.
Referenced by QSvgTinyDocument::draw(), QSvgTinyDocument::draw(), QSvgUse::draw(), QSvgG::draw(), and QSvgSwitch::draw().
|
virtual |
Reimplemented in QSvgArc, QSvgEllipse, QSvgLine, QSvgPath, QSvgPolygon, QSvgPolyline, QSvgRect, and QSvgText.
Definition at line 180 of file qsvgnode.cpp.
References bounds().
Referenced by shouldDrawNode().
bool QSvgNode::isDescendantOf | ( | const QSvgNode * | parent | ) | const |
Definition at line 34 of file qsvgnode.cpp.
References parent().
Referenced by QSvgUse::bounds(), and QSvgUse::draw().
|
inline |
Definition at line 153 of file qsvgnode_p.h.
Referenced by QSvgTinyDocument::draw(), QSvgG::draw(), QSvgSwitch::draw(), and setVisible().
|
inline |
Definition at line 158 of file qsvgnode_p.h.
|
inline |
Definition at line 148 of file qsvgnode_p.h.
Referenced by createLinearGradientNode(), document(), QSvgTinyDocument::draw(), isDescendantOf(), QSvgStyleSelector::parentNode(), parseVisibility(), styleProperty(), transformedBounds(), and QSvgTinyDocument::transformForElement().
const QStringList & QSvgNode::requiredExtensions | ( | ) | const |
Definition at line 246 of file qsvgnode.cpp.
Referenced by QSvgSwitch::draw().
const QStringList & QSvgNode::requiredFeatures | ( | ) | const |
Definition at line 236 of file qsvgnode.cpp.
Referenced by QSvgSwitch::draw().
const QStringList & QSvgNode::requiredFonts | ( | ) | const |
Definition at line 276 of file qsvgnode.cpp.
Referenced by QSvgSwitch::draw().
const QStringList & QSvgNode::requiredFormats | ( | ) | const |
Definition at line 266 of file qsvgnode.cpp.
Referenced by QSvgSwitch::draw().
const QStringList & QSvgNode::requiredLanguages | ( | ) | const |
Definition at line 256 of file qsvgnode.cpp.
Referenced by QSvgSwitch::draw().
void QSvgNode::revertStyle | ( | QPainter * | p, |
QSvgExtraStates & | states | ||
) | const |
Definition at line 104 of file qsvgnode.cpp.
References m_style, and QSvgStyle::revert().
Referenced by QSvgTinyDocument::draw(), QSvgTinyDocument::draw(), QSvgArc::draw(), QSvgEllipse::draw(), QSvgImage::draw(), QSvgLine::draw(), QSvgPath::draw(), QSvgPolygon::draw(), QSvgPolyline::draw(), QSvgRect::draw(), QSvgUse::draw(), QSvgVideo::draw(), QSvgG::draw(), QSvgSwitch::draw(), and transformedBounds().
void QSvgNode::setDisplayMode | ( | DisplayMode | display | ) |
Definition at line 311 of file qsvgnode.cpp.
Referenced by parseOthers().
Definition at line 301 of file qsvgnode.cpp.
References i.
Referenced by parseCoreNode(), and parseStopNode().
void QSvgNode::setRequiredExtensions | ( | const QStringList & | lst | ) |
Definition at line 241 of file qsvgnode.cpp.
Referenced by parseCoreNode().
void QSvgNode::setRequiredFeatures | ( | const QStringList & | lst | ) |
Definition at line 231 of file qsvgnode.cpp.
Referenced by parseCoreNode().
void QSvgNode::setRequiredFonts | ( | const QStringList & | lst | ) |
Definition at line 271 of file qsvgnode.cpp.
Referenced by parseCoreNode().
void QSvgNode::setRequiredFormats | ( | const QStringList & | lst | ) |
Definition at line 261 of file qsvgnode.cpp.
Referenced by parseCoreNode().
void QSvgNode::setRequiredLanguages | ( | const QStringList & | lst | ) |
Definition at line 251 of file qsvgnode.cpp.
Referenced by parseCoreNode().
void QSvgNode::setVisible | ( | bool | visible | ) |
Definition at line 281 of file qsvgnode.cpp.
References isVisible(), and setVisible().
Referenced by parseVisibility(), and setVisible().
Definition at line 306 of file qsvgnode.cpp.
References str.
Referenced by parseCoreNode(), and parseStopNode().
bool QSvgNode::shouldDrawNode | ( | QPainter * | p, |
QSvgExtraStates & | states | ||
) | const |
Definition at line 329 of file qsvgnode.cpp.
References fastBounds(), QRectF::height(), qCWarning, qEnvironmentVariableIntValue(), QT_SVG_SIZE_LIMIT, type(), and QRectF::width().
Referenced by QSvgArc::draw(), QSvgEllipse::draw(), QSvgImage::draw(), QSvgLine::draw(), QSvgPath::draw(), QSvgPolygon::draw(), QSvgPolyline::draw(), and QSvgRect::draw().
Definition at line 321 of file qsvgnode.cpp.
References QPen::brush(), QPen::isCosmetic(), Qt::NoBrush, Qt::NoPen, QBrush::style(), QPen::style(), and QPen::widthF().
Referenced by QSvgArc::bounds(), QSvgEllipse::bounds(), QSvgLine::bounds(), QSvgPath::bounds(), QSvgPolygon::bounds(), QSvgPolyline::bounds(), and QSvgRect::bounds().
QSvgFillStyleProperty * QSvgNode::styleProperty | ( | const QString & | id | ) | const |
Definition at line 171 of file qsvgnode.cpp.
References document(), QSvgTinyDocument::namedStyle(), QString::remove(), and QString::startsWith().
QSvgStyleProperty * QSvgNode::styleProperty | ( | QSvgStyleProperty::Type | type | ) | const |
Definition at line 109 of file qsvgnode.cpp.
References QSvgStyleProperty::ANIMATE_COLOR, QSvgStyleProperty::ANIMATE_TRANSFORM, QSvgStyle::animateColor, QSvgStyle::animateTransforms, QSvgStyleProperty::COMP_OP, QSvgStyle::compop, QSvgStyleProperty::FILL, QSvgStyle::fill, QList< T >::first(), QSvgStyleProperty::FONT, QSvgStyle::font, QSvgStyleProperty::GRADIENT, QSvgStyle::gradient, QList< T >::isEmpty(), m_style, QSvgStyleProperty::OPACITY, QSvgStyle::opacity, parent(), QSvgStyleProperty::QUALITY, QSvgStyle::quality, QSvgStyleProperty::SOLID_COLOR, QSvgStyle::solidColor, QSvgStyleProperty::STROKE, QSvgStyle::stroke, QSvgStyleProperty::TRANSFORM, QSvgStyle::transform, QSvgStyleProperty::VIEWPORT_FILL, and QSvgStyle::viewportFill.
Referenced by parseBaseGradient(), QSvgGradientStyle::resolveStops_helper(), and styleFromUrl().
QRectF QSvgNode::transformedBounds | ( | ) | const |
Definition at line 190 of file qsvgnode.cpp.
References applyStyle(), Qt::FlatCap, QImage::Format_RGB32, i, QRectF::isEmpty(), Qt::NoBrush, parent(), QStack< T >::push(), QPen::setMiterLimit(), QList< T >::size(), Qt::SolidLine, Qt::SvgMiterJoin, and transformedBounds().
Referenced by transformedBounds(), and QSvgTinyDocument::viewBox().
|
virtual |
Definition at line 293 of file qsvgnode.cpp.
References applyStyle(), bounds(), rect, and revertStyle().
Referenced by QSvgUse::bounds(), QSvgTinyDocument::boundsOnElement(), and QSvgTinyDocument::draw().
|
pure virtual |
Implemented in QSvgAnimation, QSvgArc, QSvgEllipse, QSvgCircle, QSvgImage, QSvgLine, QSvgPath, QSvgPolygon, QSvgPolyline, QSvgRect, QSvgText, QSvgTspan, QSvgUse, QSvgVideo, QSvgG, QSvgDefs, QSvgSwitch, and QSvgTinyDocument.
Referenced by QSvgHandler::characters(), createLinearGradientNode(), document(), QSvgStyleSelector::nodeToName(), shouldDrawNode(), and QSvgHandler::startElement().
|
inline |
Definition at line 163 of file qsvgnode_p.h.
|
friend |
Definition at line 145 of file qsvgnode_p.h.
|
mutableprotected |
Definition at line 125 of file qsvgnode_p.h.
Referenced by appendStyleProperty(), applyStyle(), revertStyle(), styleProperty(), and QSvgTinyDocument::transformForElement().