From: Ira W. Snyder Date: Wed, 16 Jan 2008 20:16:42 +0000 (-0800) Subject: [Window] Add positioning capability X-Git-Url: https://www.irasnyder.com/gitweb/?p=tilda-gobject.git;a=commitdiff_plain;h=540a3b2f08673c226860cc6a08ed0f15a057da35 [Window] Add positioning capability The TildaWindow class had the capability to set the x-position and y-position properties, but they had no effect. This adds the appropriate gtk_window_move() calls so the position is set up correctly. --- diff --git a/tilda-window.c b/tilda-window.c index 3455112..158d33a 100644 --- a/tilda-window.c +++ b/tilda-window.c @@ -310,11 +310,13 @@ tilda_window_set_property (GObject *object, case TILDA_WINDOW_X_POSITION: self->x_position = g_value_get_int (value); + gtk_window_move (GTK_WINDOW(self->window), self->x_position, self->y_position); g_print ("window x position: %d\n", self->x_position); break; case TILDA_WINDOW_Y_POSITION: self->y_position = g_value_get_int (value); + gtk_window_move (GTK_WINDOW(self->window), self->x_position, self->y_position); g_print ("window y position: %d\n", self->y_position); break; @@ -494,6 +496,10 @@ tilda_window_constructor (GType type, gtk_container_add (GTK_CONTAINER(self->window), self->notebook); gtk_widget_show (self->notebook); + // FIXME: Remove these, and replace with reads from the config system + g_object_set (G_OBJECT(self), "key", "F2", NULL); + g_object_set (G_OBJECT(self), "x-position", 0, "y-position", 0, NULL); + tilda_window_add_term (self); tilda_window_add_term (self); gtk_widget_show_all (self->window);