Logo Search packages:      
Sourcecode: inkscape version File versions

gdouble sp_knot_distance ( SPKnot knot,
NR::Point p,
guint  state 
)

Return distance of point to knot's position; unused.

Definition at line 526 of file knot.cpp.

References NR::L2(), and SPKnot::pos.

{
    g_return_val_if_fail(knot != NULL, 1e18);
    g_return_val_if_fail(SP_IS_KNOT(knot), 1e18);

    gdouble distance = NR::L2(*p - knot->pos);

    g_signal_emit(knot,
                  knot_signals[DISTANCE], 0,
                  p,
                  state,
                  &distance);

    return distance;
}


Generated by  Doxygen 1.6.0   Back to index