-/* This function is used to adjust the border around the text in a button. */
-static GtkWidget *
-AddTextButton(gchar *button_text)
-{
- GtkWidget *button;
- GtkWidget *label;
- GtkWidget *label_window;
-
- /*
- * The GtkLabel widget is one of a few GTK+ widgets that don't create
- * their own window to render themselves into. Instead, they draw
- * themselves directly onto their parents window. This means that in
- * order to set a property for a GtkLabel widget, you need to change the
- * property of its parent, i.e. the object that you pack it into.
- * Another solution (short term workaround) is to put the label widget
- * inside another widget that does get its own window, like the
- * 'ViewPort' or 'EventBox' widget.
- */
-
- /*
- * Using workaround described above to set the border width of 'label'
- * widget.
- */
- label_window = gtk_event_box_new();
-
- /* Creating our label. */
- label = gtk_label_new(button_text);
-
- /* Adding label widget to label_window widget. */
- gtk_container_add(GTK_CONTAINER(label_window), label);
-
- /*
- * Changing border width of the label widget by way of label_window
- * widget.
- */
- gtk_container_set_border_width(GTK_CONTAINER(label_window),
- BUTTON_TEXT_BORDER);
-
- /* Create the button. */
- button = gtk_button_new();
-
- /* Adding label to button. */
- gtk_container_add(GTK_CONTAINER(button), label_window);
-
- return button;
-}