#include "ui/tools/dynamic-base.h"
#include "config.h"
#include "message-context.h"
#include "streq.h"
#include "preferences.h"
#include "display/sp-canvas-item.h"
#include "desktop.h"
namespace Inkscape {
namespace UI {
namespace Tools {
, accumulated(NULL)
, currentshape(NULL)
, currentcurve(NULL)
, point1()
, point2()
, npoints(0)
, cur(0, 0)
, vel(0, 0)
, vel_max(0)
, acc(0, 0)
, ang(0, 0)
, last(0, 0)
, del(0, 0)
, xtilt(0)
, ytilt(0)
, dragging(false)
, usepressure(false)
, usetilt(false)
, mass(0.3)
, drag(DRAG_DEFAULT)
, angle(30.0)
, width(0.2)
, vel_thin(0.1)
, flatness(0.9)
, tremor(0)
, cap_rounding(0)
, is_drawing(false)
, abs_width(false)
{
}
DynamicBase::~DynamicBase() {
if (this->accumulated) {
this->accumulated = 0;
}
while (this->segments) {
}
if (this->currentcurve) {
this->currentcurve = 0;
}
if (this->cal1) {
this->cal1 = 0;
}
if (this->cal2) {
this->cal2 = 0;
}
if (this->currentshape) {
sp_canvas_item_destroy(this->currentshape);
this->currentshape = 0;
}
}
// ignore preset modifications
return;
}
if (path == "mass") {
} else if (path == "wiggle") {
} else if (path == "angle") {
} else if (path == "width") {
} else if (path == "thinning") {
} else if (path == "tremor") {
} else if (path == "flatness") {
} else if (path == "usepressure") {
} else if (path == "usetilt") {
} else if (path == "abs_width") {
} else if (path == "cap_rounding") {
}
}
/* Get normalized point */
return Geom::Point(( v[Geom::X] - drect.min()[Geom::X] ) / max, ( v[Geom::Y] - drect.min()[Geom::Y] ) / max);
}
/* Get view point */
return Geom::Point(n[Geom::X] * max + drect.min()[Geom::X], n[Geom::Y] * max + drect.min()[Geom::Y]);
}
}
}
}
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :