Skip to content

Commit

Permalink
v10.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
mpeura committed Jan 16, 2025
1 parent f78156e commit 0597664
Show file tree
Hide file tree
Showing 10 changed files with 535 additions and 260 deletions.
22 changes: 18 additions & 4 deletions src/drain/image/TreeSVG.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -302,11 +302,25 @@ void NodeSVG::updateAlign(){
}
}

if (anchorHorz.empty()){
this->unlink("data-alignAnchor");
this->unlink("data-anchor");
this->unlink("data-anchorHorz");
this->unlink("data-anchorVert");

if (anchorHorz.empty() && anchorVert.empty()){
return;
}
else {
this->link("data-alignAnchor", anchorHorz);

if (anchorHorz == anchorVert){
this->link("data-anchor", anchorHorz);
return;
}

if (!anchorHorz.empty()){
this->link("data-anchorHorz", anchorHorz);
}

if (!anchorVert.empty()){
this->link("data-anchorVert", anchorVert);
}

}
Expand Down
11 changes: 11 additions & 0 deletions src/drain/image/TreeSVG.h
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,17 @@ class NodeSVG: public NodeXML<svg::tag_t>, public AlignAdapterSVG {
inline virtual
~NodeSVG(){};

inline
bool isAbstract(){
return typeIs(
svg::tag_t::STYLE,
svg::tag_t::DESC,
svg::tag_t::METADATA,
svg::tag_t::SCRIPT,
svg::tag_t::TITLE,
svg::tag_t::TSPAN
);
}

/// Copy data from a node. (Does not copy subtree.)
inline
Expand Down
Loading

0 comments on commit 0597664

Please sign in to comment.