summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7b8b4dc)
raw | patch | inline | side by side (parent: 7b8b4dc)
author | johanengelen <johanengelen@users.sourceforge.net> | |
Thu, 3 Jul 2008 21:50:03 +0000 (21:50 +0000) | ||
committer | johanengelen <johanengelen@users.sourceforge.net> | |
Thu, 3 Jul 2008 21:50:03 +0000 (21:50 +0000) |
src/display/curve.cpp | patch | blob | history |
diff --git a/src/display/curve.cpp b/src/display/curve.cpp
index ecccd2cb16817b5671342cee6c87bf713b2f4b3c..4276627b4ae99ccd72bfc41ec45cf0a76db7eb7d 100644 (file)
--- a/src/display/curve.cpp
+++ b/src/display/curve.cpp
* Increase _refcount of curve.
*
* \todo should this be shared with other refcounting code?
- * 2GEOMproof
*/
SPCurve *
SPCurve::ref()
{
- g_return_val_if_fail(this != NULL, NULL);
-
_refcount += 1;
return this;
* Decrease refcount of curve, with possible destruction.
*
* \todo should this be shared with other refcounting code?
- * 2GEOMproof
*/
SPCurve *
SPCurve::unref()
{
- g_return_val_if_fail(this != NULL, NULL);
-
_refcount -= 1;
if (_refcount < 1) {
SPCurve *
SPCurve::copy() const
{
- g_return_val_if_fail(this != NULL, NULL);
-
return SPCurve::new_from_foreign_bpath(_bpath);
}
SPCurve *
SPCurve::concat(GSList const *list)
{
- g_return_val_if_fail(list != NULL, NULL);
-
gint length = 0;
for (GSList const *l = list; l != NULL; l = l->next) {
GSList *
SPCurve::split() const
{
- g_return_val_if_fail(this != NULL, NULL);
-
guint p = 0;
GSList *l = NULL;
void
SPCurve::reset()
{
- g_return_if_fail(this != NULL);
-
_bpath->code = NR_END;
_end = 0;
_substart = 0;
void
SPCurve::moveto(NR::Point const &p)
{
- g_return_if_fail(this != NULL);
g_return_if_fail(!_moving);
_substart = _end;
void
SPCurve::lineto(gdouble x, gdouble y)
{
- g_return_if_fail(this != NULL);
g_return_if_fail(_hascpt);
if (_moving) {
void
SPCurve::curveto(gdouble x0, gdouble y0, gdouble x1, gdouble y1, gdouble x2, gdouble y2)
{
- g_return_if_fail(this != NULL);
g_return_if_fail(_hascpt);
g_return_if_fail(!_moving);
@@ -746,7 +729,6 @@ SPCurve::curveto(gdouble x0, gdouble y0, gdouble x1, gdouble y1, gdouble x2, gdo
void
SPCurve::closepath()
{
- g_return_if_fail(this != NULL);
g_return_if_fail(_hascpt);
g_return_if_fail(!_posSet);
g_return_if_fail(!_moving);
void
SPCurve::closepath_current()
{
- g_return_if_fail(this != NULL);
g_return_if_fail(_hascpt);
g_return_if_fail(!_posSet);
g_return_if_fail(!_closed);
NArtBpath const *
SPCurve::last_bpath() const
{
- g_return_val_if_fail(this != NULL, NULL);
-
if (_end == 0) {
return NULL;
}
NR::Point
SPCurve::penultimate_point() const
{
- g_return_val_if_fail(this != NULL, NR::Point(0, 0));
-
if (_end < 2) {
return _movePos;
}
SPCurve::append(SPCurve const *curve2,
bool use_lineto)
{
- g_return_if_fail(this != NULL);
g_return_if_fail(curve2 != NULL);
if (curve2->is_empty())
SPCurve *
SPCurve::append_continuous(SPCurve const *c1, gdouble tolerance)
{
- g_return_val_if_fail(this != NULL, NULL);
g_return_val_if_fail(c1 != NULL, NULL);
g_return_val_if_fail(!_closed, NULL);
g_return_val_if_fail(!c1->_closed, NULL);
void
SPCurve::backspace()
{
- g_return_if_fail(this != NULL);
-
if ( is_empty() )
return;