diff options
| author | Abhishek Sharma Public <spyzerdotabhishek0at-signgmaildotcom> | 2010-06-29 18:05:42 +0000 |
|---|---|---|
| committer | Abhishek Sharma Public <spyzerdotabhishek0at-signgmaildotcom> | 2010-06-29 18:05:42 +0000 |
| commit | 8867de5daf309e4cdd3fce177b408618490be4f3 (patch) | |
| tree | 19a528d472e7a63f9cab97daa5c979d977db821b /src/desktop-style.cpp | |
| parent | minor fix in Dutch translation of win32 installer (diff) | |
| download | inkscape-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/desktop-style.cpp')
| -rw-r--r-- | src/desktop-style.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/desktop-style.cpp b/src/desktop-style.cpp index 26f29d172..19a45a285 100644 --- a/src/desktop-style.cpp +++ b/src/desktop-style.cpp @@ -121,7 +121,7 @@ sp_desktop_apply_css_recursive(SPObject *o, SPCSSAttr *css, bool skip_lines) // Scale the style by the inverse of the accumulated parent transform in the paste context. { - Geom::Matrix const local(sp_item_i2doc_affine(SP_ITEM(o))); + Geom::Matrix const local(SP_ITEM(o)->i2doc_affine()); double const ex(local.descrim()); if ( ( ex != 0. ) && ( ex != 1. ) ) { @@ -416,7 +416,7 @@ stroke_average_width (GSList const *objects) if (!SP_IS_ITEM (l->data)) continue; - Geom::Matrix i2d = sp_item_i2d_affine (SP_ITEM(l->data)); + Geom::Matrix i2d = (SP_ITEM(l->data))->i2d_affine (); SPObject *object = SP_OBJECT(l->data); @@ -717,7 +717,7 @@ objects_query_strokewidth (GSList *objects, SPStyle *style_res) noneSet &= style->stroke.isNone(); - Geom::Matrix i2d = sp_item_i2d_affine (SP_ITEM(obj)); + Geom::Matrix i2d = SP_ITEM(obj)->i2d_affine (); double sw = style->stroke_width.computed * i2d.descrim(); if (prev_sw != -1 && fabs(sw - prev_sw) > 1e-3) @@ -935,7 +935,7 @@ objects_query_fontnumbers (GSList *objects, SPStyle *style_res) if (!style) continue; texts ++; - size += style->font_size.computed * Geom::Matrix(sp_item_i2d_affine(SP_ITEM(obj))).descrim(); /// \todo FIXME: we assume non-% units here + size += style->font_size.computed * Geom::Matrix(SP_ITEM(obj)->i2d_affine()).descrim(); /// \todo FIXME: we assume non-% units here if (style->letter_spacing.normal) { if (!different && (letterspacing_prev == 0 || letterspacing_prev == letterspacing)) @@ -1381,7 +1381,7 @@ objects_query_blur (GSList *objects, SPStyle *style_res) if (!style) continue; if (!SP_IS_ITEM(obj)) continue; - Geom::Matrix i2d = sp_item_i2d_affine (SP_ITEM(obj)); + Geom::Matrix i2d = SP_ITEM(obj)->i2d_affine (); items ++; |
