summaryrefslogtreecommitdiffstats
path: root/src/snapped-point.cpp
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-05-15 18:08:17 +0000
committerTed Gould <ted@gould.cx>2010-05-15 18:08:17 +0000
commit2d8c2dfd832ce207aef3895e702bff4098ab7136 (patch)
tree642a37c6e3ca05d5e991ffe868f03c9cc58e51bc /src/snapped-point.cpp
parentMerge from trunk (diff)
parentMinor tweaks to text toolbar. (diff)
downloadinkscape-2d8c2dfd832ce207aef3895e702bff4098ab7136.tar.gz
inkscape-2d8c2dfd832ce207aef3895e702bff4098ab7136.zip
Updating to trunk
(bzr r8254.1.54)
Diffstat (limited to 'src/snapped-point.cpp')
-rw-r--r--src/snapped-point.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/snapped-point.cpp b/src/snapped-point.cpp
index 089aa4323..508ec8f62 100644
--- a/src/snapped-point.cpp
+++ b/src/snapped-point.cpp
@@ -164,6 +164,15 @@ bool Inkscape::SnappedPoint::isOtherSnapBetter(Inkscape::SnappedPoint const &oth
}
}
+ // When snapping to a constraint line only, which is not really a snap but merely a projection
+ // to the constraint line, then give this snap a very low priority. Basically, any other snap will do
+ if (other_one.getTarget() == SNAPTARGET_CONSTRAINT) {
+ dist_other += NR_HUGE/2;
+ }
+ if (getTarget() == SNAPTARGET_CONSTRAINT) {
+ dist_this += NR_HUGE/2;
+ }
+
// If it's closer
bool c1 = dist_other < dist_this;
// or, if it's for a snapper with "always snap" turned on, and the previous wasn't