diff options
| author | Diederik van Lierop <mail@diedenrezi.nl> | 2011-06-26 20:00:36 +0000 |
|---|---|---|
| committer | Diederik van Lierop <mail@diedenrezi.nl> | 2011-06-26 20:00:36 +0000 |
| commit | bdf703831ff93438d49324ab842052ccaf390a5d (patch) | |
| tree | f98f378da026d6c5699b0565e2735c02f4f1620c /src/attributes.cpp | |
| parent | Documentation. Tutorials translation update. (diff) | |
| download | inkscape-bdf703831ff93438d49324ab842052ccaf390a5d.tar.gz inkscape-bdf703831ff93438d49324ab842052ccaf390a5d.zip | |
- Add a third group of snap sources/targets, called ¨others¨ (before we had only ¨bounding box¨ and nodes (see bug #788178)
- Fix the display of the snap source
- Fix snapping of guides to other guides & grids
(bzr r10372)
Diffstat (limited to 'src/attributes.cpp')
| -rw-r--r-- | src/attributes.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/attributes.cpp b/src/attributes.cpp index 118a90482..334c3447c 100644 --- a/src/attributes.cpp +++ b/src/attributes.cpp @@ -94,6 +94,7 @@ static SPStyleProp const props[] = { {SP_ATTR_INKSCAPE_SNAP_GLOBAL, "inkscape:snap-global"}, {SP_ATTR_INKSCAPE_SNAP_BBOX, "inkscape:snap-bbox"}, {SP_ATTR_INKSCAPE_SNAP_NODES, "inkscape:snap-nodes"}, + {SP_ATTR_INKSCAPE_SNAP_OTHERS, "inkscape:snap-others"}, {SP_ATTR_INKSCAPE_SNAP_FROM_GUIDE, "inkscape:snap-from-guide"}, {SP_ATTR_INKSCAPE_SNAP_CENTER, "inkscape:snap-center"}, {SP_ATTR_INKSCAPE_SNAP_GRIDS, "inkscape:snap-grids"}, @@ -495,6 +496,7 @@ sp_attribute_lookup(gchar const *key) propdict = g_hash_table_new(g_str_hash, g_str_equal); for (i = 1; i < n_attrs; i++) { g_assert(props[i].code == static_cast< gint >(i) ); + // If this g_assert fails, then the sort order of SPAttributeEnum does not match the order in props[]! g_hash_table_insert(propdict, const_cast<void *>(static_cast<void const *>(props[i].name)), GINT_TO_POINTER(props[i].code)); |
