diff --git a/src/selcue.cpp b/src/selcue.cpp
index d8d624e9410e65a844302d8cf97804e54dae0e78..67c9712d1f14b2a73b6f34417bb642ce1357022b 100644 (file)
--- a/src/selcue.cpp
+++ b/src/selcue.cpp
#include "text-editing.h"
#include "sp-text.h"
#include "sp-flowtext.h"
-#include "prefs-utils.h"
+#include "preferences.h"
#include "selcue.h"
Inkscape::SelCue::SelCue(SPDesktop *desktop)
}
_text_baselines.clear();
- gint mode = prefs_get_int_attribute ("options.selcue", "value", MARK);
+ Inkscape::Preferences *prefs = Inkscape::Preferences::get();
+ gint mode = prefs->getInt("/options/selcue/value", MARK);
if (mode == NONE) {
return;
}
g_return_if_fail(_selection != NULL);
- int prefs_bbox = prefs_get_int_attribute("tools", "bounding_box", 0);
- SPItem::BBoxType bbox_type = (prefs_bbox ==0)?
+ int prefs_bbox = prefs->getBool("/tools/bounding_box");
+ SPItem::BBoxType bbox_type = !prefs_bbox ?
SPItem::APPROXIMATE_BBOX : SPItem::GEOMETRIC_BBOX;
for (GSList const *l = _selection->itemList(); l != NULL; l = l->next) {
SPItem *item = (SPItem *) l->data;
- boost::optional<NR::Rect> const b = sp_item_bbox_desktop(item, bbox_type);
+ Geom::OptRect const b = sp_item_bbox_desktop(item, bbox_type);
SPCanvasItem* box = NULL;
"stroke_color", 0x000000ff,
NULL);
sp_canvas_item_show(box);
- SP_CTRL(box)->moveto(NR::Point(b->min()[NR::X], b->max()[NR::Y]));
+ SP_CTRL(box)->moveto(Geom::Point(b->min()[Geom::X], b->max()[Geom::Y]));
sp_canvas_item_move_to_z(box, 0); // just low enough to not get in the way of other draggable knots