Lines Matching refs:shape
29 #include "libavoid/shape.h"
78 ShapeRef *shape(void) const
168 ShapeRefList::iterator shape = shapeRefs.begin();
169 while (shape != shapeRefs.end())
171 ShapeRef *shapePtr = *shape;
172 db_printf("Deleting shape %u in ~Router()\n", shapePtr->id());
179 shape = shapeRefs.begin();
247 void Router::addShape(ShapeRef *shape)
249 // There shouldn't be remove events or move events for the same shape
253 ActionInfo(ShapeRemove, shape)) == actionList.end());
255 ActionInfo(ShapeMove, shape)) == actionList.end());
257 ActionInfo addInfo(ShapeAdd, shape);
273 void Router::removeShape(ShapeRef *shape)
275 // There shouldn't be add events events for the same shape already
279 ActionInfo(ShapeAdd, shape)) == actionList.end());
281 // Delete any ShapeMove entries for this shape in the action list.
283 actionList.end(), ActionInfo(ShapeMove, shape));
290 ActionInfo remInfo(ShapeRemove, shape);
304 void Router::moveShape(ShapeRef *shape, const double xDiff, const double yDiff)
306 Polygon newPoly = shape->polygon();
309 moveShape(shape, newPoly);
313 void Router::moveShape(ShapeRef *shape, const Polygon& newPoly,
316 // There shouldn't be remove events or add events for the same shape
320 ActionInfo(ShapeRemove, shape)) == actionList.end());
323 ActionInfo(ShapeAdd, shape)) != actionList.end())
329 ActionInfo moveInfo(ShapeMove, shape, newPoly, first_move);
331 // shape multiple times before rerouting connectors.
339 db_printf("warning: multiple moves requested for shape %d "
340 "within a single transaction.\n", (int) shape->id());
406 bool Router::shapeInQueuedActionList(ShapeRef *shape) const
409 ActionInfo(ShapeAdd, shape)) != actionList.end();
411 ActionInfo(ShapeRemove, shape)) != actionList.end();
413 ActionInfo(ShapeMove, shape)) != actionList.end();
455 ShapeRef *shape = actInf.shape();
459 unsigned int pid = shape->id();
461 // o Remove entries related to this shape's vertices
462 shape->removeFromGraph();
466 markConnectors(shape);
471 // Ignore this shape for visibility.
474 // around the shape until it leaves the connector.
475 shape->makeInactive();
492 // o Check all edges that were blocked by this shape.
493 checkAllBlockedEdges(actInf.shape()->id());
512 ShapeRef *shape = actInf.shape();
516 unsigned int pid = shape->id();
518 // Restore this shape for visibility.
519 shape->makeActive();
523 shape->setNewPoly(newPoly);
525 const Polygon& shapePoly = shape->polygon();
531 // o Check all visibility edges to see if this one shape
541 shapeVisSweep(shape);
545 shapeVis(shape);
681 // 'type' attached to the shape with the ID 'shapeId'.
700 // Returns a list of shape Ids of all the shapes attached to the
701 // shape with the ID 'shapeId' with connection type 'type'.
712 // Only if there is a shape attached to the other end.
720 // Only if there is a shape attached to the other end.
729 // resulting from shape movement have happened. It will alert
849 // o Check all visibility edges to see if this one shape
875 // and are inside the shape being added.
894 db_printf("\tRemoving newly blocked edge (by shape %3d)"
1058 void Router::markConnectors(ShapeRef *shape)
1093 VertInf *beginV = shape->firstVert();
1094 VertInf *endV = shape->lastVert()->lstNext;
1357 // The shape 0 ones are temporary and not considered.
1654 "inkscape:label=\"VisGraph-shape\""