summaryrefslogtreecommitdiffstats
path: root/src/conn-avoid-ref.cpp
diff options
context:
space:
mode:
authorAbhishek Sharma Public <spyzerdotabhishek0at-signgmaildotcom>2010-06-29 18:05:42 +0000
committerAbhishek Sharma Public <spyzerdotabhishek0at-signgmaildotcom>2010-06-29 18:05:42 +0000
commit8867de5daf309e4cdd3fce177b408618490be4f3 (patch)
tree19a528d472e7a63f9cab97daa5c979d977db821b /src/conn-avoid-ref.cpp
parentminor fix in Dutch translation of win32 installer (diff)
downloadinkscape-8867de5daf309e4cdd3fce177b408618490be4f3.tar.gz
inkscape-8867de5daf309e4cdd3fce177b408618490be4f3.zip
This is the first c++ification commit from me. It handles sp-line, sp-polyline, sp-item and marks the onset of document c++ification as well. Users can check performace increase with [/usr/bin/time -v inkscape_binary_with_commandline_options].
(bzr r9546.1.1)
Diffstat (limited to 'src/conn-avoid-ref.cpp')
-rw-r--r--src/conn-avoid-ref.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/conn-avoid-ref.cpp b/src/conn-avoid-ref.cpp
index 88c84a84c..21df27637 100644
--- a/src/conn-avoid-ref.cpp
+++ b/src/conn-avoid-ref.cpp
@@ -387,14 +387,14 @@ Geom::Point SPAvoidRef::getConnectionPointPos(const int type, const int id)
{
g_assert(item);
Geom::Point pos;
- const Geom::Matrix& transform = sp_item_i2doc_affine(item);
+ const Geom::Matrix& transform = item->i2doc_affine();
// TODO investigate why this was asking for the active desktop:
SPDesktop *desktop = inkscape_active_desktop();
if ( type == ConnPointDefault )
{
// For now, just default to the centre of the item
- Geom::OptRect bbox = item->getBounds(sp_item_i2doc_affine(item));
+ Geom::OptRect bbox = item->getBounds(item->i2doc_affine());
pos = (bbox) ? bbox->midpoint() : Geom::Point(0, 0);
}
else
@@ -504,7 +504,7 @@ static Avoid::Polygon avoid_item_poly(SPItem const *item)
g_assert(desktop != NULL);
double spacing = desktop->namedview->connector_spacing;
- Geom::Matrix itd_mat = sp_item_i2doc_affine(item);
+ Geom::Matrix itd_mat = item->i2doc_affine();
std::vector<Geom::Point> hull_points;
hull_points = approxItemWithPoints(item, itd_mat);