On 08/29/2011 05:20 PM, Lex Trotman wrote:
[...]
Well, I don't think there is anything wrong with looking at GTK-3 but it *is* too early to remove support for GTK-2. I've not looked at what changed for GTK-3, can we support both without much work (after gtkbuilder is incorporated)? Lots of #ifdefs would be bad.
Until the snag with the deprecated widgets used in the Glade generated code, the changes were extremely trivial and wouldn't at all break the current GTK+ version support. All of them were documented in the migration guide[1].
A quick list of the changes I had to make: - Update Scintilla since it now supports GTK+ 3. - Replace a few direct member accesses with accessor functions. - Switch from using GtkComboBoxEntry to GtkComboBox. - Replace GtkNotebookPage with gpointer. - Fix use of GDK_<keynamehere> and include of gdkkeysyms.h. - Add some alternate #ifdef'd code for "Height-for-width" layout in the GeanyWrapLabel widget[2]
The last two are the only ones that require some version checking/different code handling. Actually, some of the changes should probably be made even without thinking of GTK+ 3, since they are considered good practice even with GTK+ 2.
[1] http://developer.gnome.org/gtk3/3.0/migrating.html [2] http://developer.gnome.org/gtk3/3.0/ch25s02.html#id1525688
Cheers, Matthew Brush