fixed scope of gtk_widget_get_allocation and gtk_widget_set_can_default