index 60845b6bb96f1bb0edd2d6f301013801968df87b..6b37b65d4bb68cfab8e7913a6967ad1089297848 100644 (file)
--- a/src/dialogs/xml-tree.cpp
+++ b/src/dialogs/xml-tree.cpp
w = prefs_get_int_attribute(prefs_path, "w", 0);
h = prefs_get_int_attribute(prefs_path, "h", 0);
}
w = prefs_get_int_attribute(prefs_path, "w", 0);
h = prefs_get_int_attribute(prefs_path, "h", 0);
}
+
+ if (x<0) x=0;
+ if (y<0) y=0;
+
if (x != 0 || y != 0) {
gtk_window_move((GtkWindow *) dlg, x, y);
} else {
if (x != 0 || y != 0) {
gtk_window_move((GtkWindow *) dlg, x, y);
} else {
NULL,
_("New element node"),
NULL,
NULL,
_("New element node"),
NULL,
- sp_icon_new( GTK_ICON_SIZE_LARGE_TOOLBAR,
+ sp_icon_new( Inkscape::ICON_SIZE_LARGE_TOOLBAR,
INKSCAPE_STOCK_ADD_XML_ELEMENT_NODE ),
G_CALLBACK(cmd_new_element_node),
NULL);
INKSCAPE_STOCK_ADD_XML_ELEMENT_NODE ),
G_CALLBACK(cmd_new_element_node),
NULL);
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("New text node"), NULL,
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("New text node"), NULL,
- sp_icon_new( GTK_ICON_SIZE_LARGE_TOOLBAR,
+ sp_icon_new( Inkscape::ICON_SIZE_LARGE_TOOLBAR,
INKSCAPE_STOCK_ADD_XML_TEXT_NODE ),
G_CALLBACK(cmd_new_text_node),
NULL);
INKSCAPE_STOCK_ADD_XML_TEXT_NODE ),
G_CALLBACK(cmd_new_text_node),
NULL);
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Duplicate node"), NULL,
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Duplicate node"), NULL,
- sp_icon_new( GTK_ICON_SIZE_LARGE_TOOLBAR,
+ sp_icon_new( Inkscape::ICON_SIZE_LARGE_TOOLBAR,
INKSCAPE_STOCK_DUPLICATE_XML_NODE ),
G_CALLBACK(cmd_duplicate_node),
NULL);
INKSCAPE_STOCK_DUPLICATE_XML_NODE ),
G_CALLBACK(cmd_duplicate_node),
NULL);
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Delete node"), NULL,
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Delete node"), NULL,
- sp_icon_new( GTK_ICON_SIZE_LARGE_TOOLBAR,
+ sp_icon_new( Inkscape::ICON_SIZE_LARGE_TOOLBAR,
INKSCAPE_STOCK_DELETE_XML_NODE ),
G_CALLBACK(cmd_delete_node), NULL );
INKSCAPE_STOCK_DELETE_XML_NODE ),
G_CALLBACK(cmd_delete_node), NULL );
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Delete attribute"), NULL,
button = gtk_toolbar_append_item(GTK_TOOLBAR(toolbar),
NULL, _("Delete attribute"), NULL,
- sp_icon_new( GTK_ICON_SIZE_LARGE_TOOLBAR,
+ sp_icon_new( Inkscape::ICON_SIZE_LARGE_TOOLBAR,
INKSCAPE_STOCK_DELETE_XML_ATTRIBUTE ),
(GCallback) cmd_delete_attr, NULL);
INKSCAPE_STOCK_DELETE_XML_ATTRIBUTE ),
(GCallback) cmd_delete_attr, NULL);
}
current_desktop = desktop;
if (desktop) {
}
current_desktop = desktop;
if (desktop) {
- sel_changed_connection = SP_DT_SELECTION(desktop)->connectChanged(&on_desktop_selection_changed);
+ sel_changed_connection = sp_desktop_selection(desktop)->connectChanged(&on_desktop_selection_changed);
document_replaced_connection = desktop->connectDocumentReplaced(&on_document_replaced);
document_replaced_connection = desktop->connectDocumentReplaced(&on_document_replaced);
- set_tree_document(SP_DT_DOCUMENT(desktop));
+ set_tree_document(sp_desktop_document(desktop));
} else {
set_tree_document(NULL);
}
} else {
set_tree_document(NULL);
}
return NULL;
}
return NULL;
}
- return SP_DT_SELECTION(current_desktop)->singleRepr();
+ return sp_desktop_selection(current_desktop)->singleRepr();
}
}
return;
}
return;
}
- Inkscape::Selection *selection = SP_DT_SELECTION(current_desktop);
+ Inkscape::Selection *selection = sp_desktop_selection(current_desktop);
SPObject *object;
if (repr) {
SPObject *object;
if (repr) {
repr = sp_repr_parent(repr);
} // end of while loop
repr = sp_repr_parent(repr);
} // end of while loop
- object = SP_DT_DOCUMENT(current_desktop)->getObjectByRepr(repr);
+ object = sp_desktop_document(current_desktop)->getObjectByRepr(repr);
} else {
object = NULL;
}
} else {
object = NULL;
}
if (current_desktop)
sel_changed_connection.disconnect();
if (current_desktop)
sel_changed_connection.disconnect();
- sel_changed_connection = SP_DT_SELECTION(dt)->connectChanged(&on_desktop_selection_changed);
+ sel_changed_connection = sp_desktop_selection(dt)->connectChanged(&on_desktop_selection_changed);
set_tree_document(doc);
}
set_tree_document(doc);
}