Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
This would make quite some code obsolete and so could be removed. Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2 (and in the long term makes getting compatible with GTK3 easier, but really, later :D). Though I'd like to do this step some time later. Also we could rely on GIO which came with GLib 2.16 which should remove some #ifdefs.
I think the current minimum of GTK 2.8 can be increased as GTK 2.12 is already about three years old already.
Any objections?
Regards, Enrico
2011/5/4 Enrico Tröger enrico.troeger@uvena.de:
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
This would make quite some code obsolete and so could be removed. Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2 (and in the long term makes getting compatible with GTK3 easier, but really, later :D). Though I'd like to do this step some time later. Also we could rely on GIO which came with GLib 2.16 which should remove some #ifdefs.
I think the current minimum of GTK 2.8 can be increased as GTK 2.12 is already about three years old already.
Any objections?
Hi Enrico,
I definitely support that. Last time I was using Glade 2 I had to modify some system header files because Glade was using some obsolete interfaces that apparently nobody else used/tested. And this will be getting worse I'm afraid. Apart from that the UI of Glade 2 is pretty ugly.
There will still be two options for people on older systems:
1. Use older version of Geany (these people will have to use old versions of all other software anyway so they are used to it)
2. Compile a newer version of GTK themselves. This is what I do at work on SLES 9 (which ships with GTK 2.4). Basically you have to compile pkgconfig, freetype, fontconfig, glib, pixman, cairo, pango, atk and finally gtk. About 3 hours of work (of which 2.5 hours is browsing the web while waiting until it gets compiled).
Porting to GTK 3 is pretty straightforward but it really depends how many GTK2-specific things Geany uses. I can have a look at it once a GTK3-compatible Scintilla is used by Geany.
Cheers,
Jiri
Le 04/05/2011 23:40, Jiří Techet a écrit :
[...] Last time I was using Glade 2 I had to modify some system header files because Glade was using some obsolete interfaces that apparently nobody else used/tested.
That's not completely true, the fix can be done in Glade2 code rather than GTK headers. We even have a patch: http://download.geany.org/glade-2.12.2-build-fixes.patch :)
Though, I agree that's a PITA, and that Galde3 is ways better :)
Cheers, Colomban
On Thu, May 5, 2011 at 00:44, Colomban Wendling lists.ban@herbesfolles.org wrote:
Le 04/05/2011 23:40, Jiří Techet a écrit :
[...] Last time I was using Glade 2 I had to modify some system header files because Glade was using some obsolete interfaces that apparently nobody else used/tested.
That's not completely true, the fix can be done in Glade2 code rather than GTK headers. We even have a patch: http://download.geany.org/glade-2.12.2-build-fixes.patch :)
Good to know, the patch really fixes the compilation errors. Maybe there should be a link to it here
http://geany.org/manual/dev/hacking.html#glade
under the Glade section (or the tarball could already provide the patched version).
Jiri
On Thu, 5 May 2011 13:55:58 +0200, Jiří wrote:
On Thu, May 5, 2011 at 00:44, Colomban Wendling lists.ban@herbesfolles.org wrote:
Le 04/05/2011 23:40, Jiří Techet a écrit :
[...] Last time I was using Glade 2 I had to modify some system header files because Glade was using some obsolete interfaces that apparently nobody else used/tested.
That's not completely true, the fix can be done in Glade2 code rather than GTK headers. We even have a patch: http://download.geany.org/glade-2.12.2-build-fixes.patch :)
Good to know, the patch really fixes the compilation errors. Maybe there should be a link to it here
Done in SVN. Thanks for the hint.
The online HTML version (link above) will be updated tonight.
Regards, Enrico
On Wed, 4 May 2011 23:40:17 +0200, Jiří wrote:
- Compile a newer version of GTK themselves. This is what I do at
work on SLES 9 (which ships with GTK 2.4). Basically you have to compile pkgconfig, freetype, fontconfig, glib, pixman, cairo, pango, atk and finally gtk. About 3 hours of work (of which 2.5 hours is browsing the web while waiting until it gets compiled).
Haha.
Porting to GTK 3 is pretty straightforward but it really depends how many GTK2-specific things Geany uses. I can have a look at it once a GTK3-compatible Scintilla is used by Geany.
I'm most afraid of GSEAL. Probably we'll need to have a bunch of wrapper functions because not all of the suggested accessor functions are available on older GTK versions. But this is probably just a little work to write these wrappers, nothing difficult to solve (I hope :D).
Regards, Enrico
Le 08/05/2011 17:47, Enrico Tröger a écrit :
On Wed, 4 May 2011 23:40:17 +0200, Jiří wrote:
[...]
Porting to GTK 3 is pretty straightforward but it really depends how many GTK2-specific things Geany uses. I can have a look at it once a GTK3-compatible Scintilla is used by Geany.
I'm most afraid of GSEAL. Probably we'll need to have a bunch of wrapper functions because not all of the suggested accessor functions are available on older GTK versions. But this is probably just a little work to write these wrappers, nothing difficult to solve (I hope :D).
Yeah, sealed members might be the most important work from our side, but faking accessors is quite easy (though boring to do). Basically, something like
#if ! GTK_CHECK_VERSION(the-version, that-introduced, the-accessor) #define gtk_some_accessor(w) ((w)->member) #endif
The difficulties comes from:
1) finding the actual GTK version that introduced the accessor 2) the amount of accessors to fake
But before worrying, maybe trying to build with -DGSEAL_ENABLE is the right thing to do ^^
Cheers, Colomban
On 05/04/11 14:00, Enrico Tröger wrote:
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
This would make quite some code obsolete and so could be removed. Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2 (and in the long term makes getting compatible with GTK3 easier, but really, later :D). Though I'd like to do this step some time later. Also we could rely on GIO which came with GLib 2.16 which should remove some #ifdefs.
I think the current minimum of GTK 2.8 can be increased as GTK 2.12 is already about three years old already.
I think it's a good idea. If it helps I would be willing to scour a few of the source files and remove obsolete code. Just let me know.
It'd be great to switch to GtkBuilder some time, since Glade 2 is pretty much DOA now (as Jiri mentionned, requires system header modifications to build) and it's painful to use it. IMO, doing that switch will be quite a big task, but will make working on Geany's UI *much* easier. The only downside is that Geany will have to ship with a separate XML file for the UI, but it's not such a big deal.
Cheers, Matthew Brush
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
None from me, more the contrary :)
This would make quite some code obsolete and so could be removed.
Yep, that'd be good.
Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2
Well, not completely sure about this, even though I like GtkBuilder and Glade3 (it's soooo nicer than Glade2 :p): GtkBuilder was *introduced* in 2.12, which means the code is quite young with this release, maybe having important issues. I don't mean we shouldn't try to use it, but simply that it may be a problem because some important fixes might have happened in a newer release.
(and in the long term makes getting compatible with GTK3 easier, but really, later :D).
Honestly it shouldn't be that hard to support GTK3 at some point since AFAIK we don't rely on the things that have largely changed in GTK3 (size allocation, Cairo rendering, ...).
Though I'd like to do this step some time later.
Wise, one step at a time ^^
Also we could rely on GIO which came with GLib 2.16 which should remove some #ifdefs.
That'd be good, to. The more code paths, the more bugs, etc.
I think the current minimum of GTK 2.8 can be increased as GTK 2.12 is already about three years old already.
Any objections?
Again, no. Let's wait for Nick's answer... :D
Cheers, Colomban
On Thu, 05 May 2011 00:40:43 +0200, Colomban wrote:
Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2
Well, not completely sure about this, even though I like GtkBuilder and Glade3 (it's soooo nicer than Glade2 :p): GtkBuilder was *introduced* in 2.12, which means the code is quite young with this release, maybe having important issues. I don't mean we shouldn't try to use it, but simply that it may be a problem because some important fixes might have happened in a newer release.
Good point. But there is probably one way to find it out: test it :). Seriously, I think we could try to get a rough converted version and then test it on GTK 2.12.0 (or .x) to check how it works. But not today and tomorrow.
(and in the long term makes getting compatible with GTK3 easier, but really, later :D).
Honestly it shouldn't be that hard to support GTK3 at some point since AFAIK we don't rely on the things that have largely changed in GTK3 (size allocation, Cairo rendering, ...).
Yeah. I guess the most obvious change will be GSEAL as mentioned in another post in this thread.
Regards, Enrico
Le 08/05/2011 17:50, Enrico Tröger a écrit :
On Thu, 05 May 2011 00:40:43 +0200, Colomban wrote:
Also, it would make it easier to migrate to using Glade 3 with GtkBuilder instead of Glade 2
Well, not completely sure about this, even though I like GtkBuilder and Glade3 (it's soooo nicer than Glade2 :p): GtkBuilder was *introduced* in 2.12, which means the code is quite young with this release, maybe having important issues. I don't mean we shouldn't try to use it, but simply that it may be a problem because some important fixes might have happened in a newer release.
Good point. But there is probably one way to find it out: test it :). Seriously, I think we could try to get a rough converted version and then test it on GTK 2.12.0 (or .x) to check how it works. But not today and tomorrow.
Yeah of course, I'm not saying we shouldn't try it, but simply that we should do it with some care. If it appears it works seamlessly, I'd be really happy :)
Cheers, Colomban
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Cheers, Colomban
On Mon, 13 Jun 2011 16:45:38 +0200, Colomban wrote:
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Yeah, I'd say let's go!
Regards, Enrico
On Mon, 13 Jun 2011 17:26:06 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
On Mon, 13 Jun 2011 16:45:38 +0200, Colomban wrote:
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Yeah, I'd say let's go!
I second this.
Cheers, Frank
Le 13/06/2011 18:55, Frank Lanitz a écrit :
On Mon, 13 Jun 2011 17:26:06 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
On Mon, 13 Jun 2011 16:45:38 +0200, Colomban wrote:
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Yeah, I'd say let's go!
I second this.
Okay, let's do then :) However, I just realized that GTK 2.12 [1] depends on GLib 2.14, not 2.16 [2] as you suggested so... do we depend on GLib 2.14 (as GTK 2.12) or 2.16 (to get GIO in)?
Cheers, Colomban
PS: Also just for the record, [3].
[1] GTK+ 2.12.0, 2007-09-14 (bebbf23f22645b2b2c44da1a52da31cc076fcd21) [2] GLib 2.16.0, 2008-04-10 (e2a4ed3287671f498d6ab87337ad31b13d781fcb) [3] GTK+ 2.14.0, 2008-09-04 (10b98d572c2007a7aef19b9c74b4c97bc17a9ac3)
On Mon, 13 Jun 2011 19:38:23 +0200, Colomban wrote:
Le 13/06/2011 18:55, Frank Lanitz a écrit :
On Mon, 13 Jun 2011 17:26:06 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
On Mon, 13 Jun 2011 16:45:38 +0200, Colomban wrote:
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Yeah, I'd say let's go!
I second this.
Okay, let's do then :) However, I just realized that GTK 2.12 [1] depends on GLib 2.14, not 2.16 [2] as you suggested so... do we depend on GLib 2.14 (as GTK 2.12) or 2.16 (to get GIO in)?
I wanted GLib 2.16 because of GIO to get rid of #ifdefs. And based on Debian Lenny's GTK/Glib versions, I suggested the combination of GTK 2.12 and GLib 2.16 although they were not released in the same cycle.
Btw, Nick is using GTK 2.12, so unless there is a super cool fancy feature in GTK 2.14 we cannot miss, I'd say 2.12 is ok for now.
Regards, Enrico
Le 13/06/2011 19:45, Enrico Tröger a écrit :
On Mon, 13 Jun 2011 19:38:23 +0200, Colomban wrote:
Le 13/06/2011 18:55, Frank Lanitz a écrit :
On Mon, 13 Jun 2011 17:26:06 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
On Mon, 13 Jun 2011 16:45:38 +0200, Colomban wrote:
Le 04/05/2011 23:00, Enrico Tröger a écrit :
Hi,
any objections in increasing the GTK minimum requirement of Geany to GTK 2.12 (and GLib 2.16)?
[...]
Any new on the subject? Should we go on an start moving?
Yeah, I'd say let's go!
I second this.
Okay, let's do then :) However, I just realized that GTK 2.12 [1] depends on GLib 2.14, not 2.16 [2] as you suggested so... do we depend on GLib 2.14 (as GTK 2.12) or 2.16 (to get GIO in)?
I wanted GLib 2.16 because of GIO to get rid of #ifdefs. And based on Debian Lenny's GTK/Glib versions, I suggested the combination of GTK 2.12 and GLib 2.16 although they were not released in the same cycle.
Fine for me, just wanted to check what you meant exactly. An I agree that having GIO in is one of the important thing to get rid of many #ifedfs.
Btw, Nick is using GTK 2.12, so unless there is a super cool fancy feature in GTK 2.14 we cannot miss, I'd say 2.12 is ok for now.
No, I don't know of anything special that would make depending on 2.14 so much better. 2.12's fine.
I'll then do the bump soon.
Cheers, Colomban