void Picture::InsertAfter (Iterator i, Graphic* g) { invalidateCachesGraphic(g); Elem(i)->Prepend(new UList(g)); setParent(g, this); uncacheExtent(); uncacheParents(); }
void Line::SetOriginal (Coord x0, Coord y0, Coord x1, Coord y1) { _x0 = x0; _y0 = y0; _x1 = x1; _y1 = y1; uncacheExtent(); }
int Vertices::SetOriginal (const Coord* x, const Coord* y) { MultiLineObj* mlo = MultiLineObj::make_pts(x, y, count()); Unref(_pts); _pts = mlo; Resource::ref(_pts); uncacheExtent(); return count(); }
Picture::~Picture () { while (!_kids->IsEmpty()) { UList* cur = _kids->First(); _kids->Remove(cur); Graphic* g = graphic(cur); delete g; delete cur; } delete _kids; uncacheExtent(); }
void Picture::Remove (Iterator& i) { UList* doomed = Elem(i); Graphic* g = graphic(doomed); Next(i); unsetParent(g); _kids->Remove(doomed); delete doomed; uncacheExtent(); uncacheParents(); }
void Picture::Prepend (Graphic* g0, Graphic* g1, Graphic* g2, Graphic* g3) { if (g3 != nil) { invalidateCachesGraphic(g3); _kids->Prepend(new UList(g3)); setParent(g3, this); } if (g2 != nil) { invalidateCachesGraphic(g2); _kids->Prepend(new UList(g2)); setParent(g2, this); } if (g1 != nil) { invalidateCachesGraphic(g1); _kids->Prepend(new UList(g1)); setParent(g1, this); } invalidateCachesGraphic(g0); _kids->Prepend(new UList(g0)); setParent(g0, this); uncacheExtent(); uncacheParents(); }
void Graphic::invalidateCaches() { uncacheParents(); uncacheExtent(); uncacheChildren(); }
void Picture::cacheExtent (float l, float b, float cx, float cy, float tol) { if (_caching) { uncacheExtent(); _extent = new Extent(l, b, cx, cy, tol); } }
void Picture::Remove (Graphic* g) { unsetParent(g); _kids->Delete(g); uncacheExtent(); uncacheParents(); }
void Vertices::SetOriginal (MultiLineObj* mlo) { Unref(_pts); _pts = mlo; Resource::ref(_pts); uncacheExtent(); }
Vertices::~Vertices () { uncacheExtent(); Unref(_pts); }
void Point::SetOriginal (Coord x, Coord y) { _x = x; _y = y; uncacheExtent(); }