Commit f7fb27e9 authored by Tavmjong Bah's avatar Tavmjong Bah Committed by Tavmjong Bah

GTK3: Give names to more widgets.

(bzr r14896)
parent 157c71ad
......@@ -23,6 +23,7 @@ ColorPreview::ColorPreview (guint32 rgba)
{
_rgba = rgba;
set_has_window(false);
set_name("ColorPreview");
}
void
......
......@@ -45,6 +45,7 @@ public:
AlternateIcons(Inkscape::IconSize size, gchar const *a, gchar const *b)
: _a(NULL), _b(NULL)
{
set_name("AlternateIcons");
if (a) {
_a = Gtk::manage(sp_icon_get_icon(a, size));
_a->set_no_show_all(true);
......@@ -94,6 +95,7 @@ private:
LayerSelector::LayerSelector(SPDesktop *desktop)
: _desktop(NULL), _layer(NULL)
{
set_name("LayerSelector");
AlternateIcons *label;
label = Gtk::manage(new AlternateIcons(Inkscape::ICON_SIZE_DECORATION,
......
......@@ -155,6 +155,7 @@ SelectedStyle::SelectedStyle(bool /*layout*/)
_unit_mis(NULL),
_sw_unit(NULL)
{
set_name("SelectedStyle");
_drop[0] = _drop[1] = 0;
_dropEnabled[0] = _dropEnabled[1] = false;
......
......@@ -124,6 +124,8 @@ StyleSwatch::StyleSwatch(SPCSSAttr *css, gchar const *main_tip)
#endif
_sw_unit(NULL)
{
set_name("StyleSwatch");
_label[SS_FILL].set_markup(_("Fill:"));
_label[SS_STROKE].set_markup(_("Stroke:"));
......
......@@ -793,6 +793,8 @@ void SPDesktopWidget::init( SPDesktopWidget *dtw )
gtk_label_set_markup (GTK_LABEL (dtw->select_status), _("<b>Welcome to Inkscape!</b> Use shape or freehand tools to create objects; use selector (arrow) to move or transform them."));
// space label 2 pixels from left edge
gtk_container_add (GTK_CONTAINER (dtw->select_status_eventbox), dtw->select_status);
// WHAT DOES THE FOLLOWING GTK_BOX DO?
#if GTK_CHECK_VERSION(3,0,0)
gtk_box_pack_start(GTK_BOX(dtw->statusbar),
gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0),
......@@ -800,6 +802,7 @@ void SPDesktopWidget::init( SPDesktopWidget *dtw )
#else
gtk_box_pack_start (GTK_BOX (dtw->statusbar), gtk_hbox_new(FALSE, 0), FALSE, FALSE, 2);
#endif
gtk_box_pack_start (GTK_BOX (dtw->statusbar), dtw->select_status_eventbox, TRUE, TRUE, 0);
gtk_widget_show_all (dtw->vbox);
......
......@@ -1411,6 +1411,7 @@ void setup_aux_toolbox(GtkWidget *toolbox, SPDesktop *desktop)
// converted to GtkActions and UIManager
GtkWidget* kludge = gtk_toolbar_new();
gtk_widget_set_name( kludge, "Kludge" );
g_object_set_data( G_OBJECT(kludge), "dtw", desktop->canvas);
g_object_set_data( G_OBJECT(kludge), "desktop", desktop);
dataHolders[aux_toolboxes[i].type_name] = kludge;
......@@ -1423,7 +1424,7 @@ void setup_aux_toolbox(GtkWidget *toolbox, SPDesktop *desktop)
} else {
sub_toolbox = aux_toolboxes[i].create_func(desktop);
}
gtk_widget_set_name( sub_toolbox, "SubToolBox" );
gtk_size_group_add_widget( grouper, sub_toolbox );
gtk_container_add(GTK_CONTAINER(toolbox), sub_toolbox);
......@@ -1441,6 +1442,7 @@ void setup_aux_toolbox(GtkWidget *toolbox, SPDesktop *desktop)
#if GTK_CHECK_VERSION(3,0,0)
GtkWidget* holder = gtk_grid_new();
gtk_widget_set_name( holder, "ToolbarHolder" );
gtk_grid_attach( GTK_GRID(holder), kludge, 2, 0, 1, 1);
#else
GtkWidget* holder = gtk_table_new( 1, 3, FALSE );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment