GNOME Bugzilla – Bug 170479
please use gtk_dialog_set_alternative_button_order()
Last modified: 2006-04-06 20:23:53 UTC
Since Gnumeric requires GTK+ 2.6 now, it would be nice if it would set each dialog's alternate button order. This UI nit would help gnumeric fit in a bit better on Win32 and for our KDE friends. Thanks. http://developer.gnome.org/doc/API/2.0/gtk/GtkDialog.html#gtk-alternative-dialog-button-order
We are using glade for most if not all dialogs. So does it allow to set alternative button orders?
I don't know the answer to this question. I do know that at some point, gnumeric does: GtkWidget * dialog = glade_xml_get_widget("dialog"); At that point, you can set the alternative button order in C code. I wouldn't punt this to the glade folks. It's easy enough to do outside of glade, and likely just as maintainable.
I'm having a hard time seeing us doing this for every dialog in C code, at least not if the C code if different from dialog to dialog. We'd be coding blind and the first time someone adds a button things would be wrong. If, on the other hand, you could write us a gnm_frob_button_order function that inspected the dialog and made up a reasonable alternate order, then things would be different.
Interestingly, the gtk+ api for this is quite broken: you can either way until the dialog is mapped and set the order then (--> flicker) or you can get it wrong, i.e., use the wrong GdkScreen's settings. See bug 170743.
Since bug 170748 has been fixed, this is now doable.
Here is an incomplete list of dialogs that stick out. Most would get bye if they swapped the positions of the "OK/Action" and "Cancel/Close" buttons. File->Properties Edit->Replace Edit->Manage Sheets View->New View View->Zoom Insert->Cells Insert->Define Names Insert->Hyperlink
Fixed in the development version. The fix will be available in the next major release. Thank you for your bug report.