Hello,
The ifdef of the file gtkdefines.inc is wrong. it defines the GTK_2_8 and GTK_2_10 symbols only if we do not use unix. What is the reason for that ?
I think it should be enabled on both Unix and non unix support.
Ido

Mailing lists / lazarus / 2008-11
17 messages · 11 people · –
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
Hello,
The ifdef of the file gtkdefines.inc is wrong. it defines the GTK_2_8 and GTK_2_10 symbols only if we do not use unix. What is the reason for that ?
I think it should be enabled on both Unix and non unix support.
Ido
Can I change the location of the define statements ?
ik wroteCan I change the location of the define statements ?
I assume that by activating the ifdef our minimum Gtk version will go up, and in that case no, don't change the ifdef.
On Linux you will usually have the gtk library which comes with the system, and installing a newer pre-compiled one will usually be impossible because that would also require updating glibc, which would require a complex update of the entire system (to the point of being less work formatting the / partition and installing a newer version of your distro).
So, it's a very big hassle for linux users requiring newer versions of anything. The constant upgrade in Qt versions is already a big problem for me, and I wouldn't like gtk to join in.
On Windows you just distribute the .dll with your program, so it's easy to guarantee that the correct gtk will be in place.
I have a code for bidi that I wrote a while ago that uses the define of GTK_2_8 but it was broken when someone moved the defines to a non unix IFDEF !
The moving of the define broke code. and the BiDi code uses GTK 2.8 based functions (that prior to that versions we had different functions that are depercated).
So I must have this define, or we should extract the functions regardless of the GTK_2_8 symbol, and then we will not require the define.
Ido
Sorry, you are probably wrong. GTK_2_8 was never defined for unixes (or it was ocasional).
But maybe you passed -dGTK_2_8 to compile LCL before?
Best regards,
Paul Ishenin.
I guess, but I can't find it.
So what can we do in order to make it work with GTK_2_8 symbol other then adding the -dGTK_2_8 ?
Ido
ik wroteI guess, but I can't find it. So what can we do in order to make it work with GTK_2_8 symbol other then adding the -dGTK_2_8 ?
Isn't that enougth?
The default is 2.6+
If you wish to use 2.8 specific features then compile LCL with the define
You are missing the point (And 2.6 is very old version of GTK. GTK 2.14 is the latest).
The point is that in order for BiDi to work with Lazarus (specially with menus) we must have the define enabled by default. I'm trying to make Lazarus to support Bi-Directional UI, and this is a blocker (if I need to tell everyone who needs it to recompile lazarus and LCL with such define) and I'm very frustrated from Lazarus after seeing that it is not simple enough to achieve such tasks.
Please note that for now Lazarus is not useful for BiDi support at all.
Ido
Even debian stable is having 2.8, as far as I can see, so maybe things are changing slowly.
You could try to dynamically load the needed 2.8 functions and turn on bidi support if it 2.8 is not available.
Vincent
On Sat, Nov 8, 2008 at 8:17 PM, Felipe Monteiro de Carvalho You are missing the point…
ik wroteYou are missing the point (And 2.6 is very old version of GTK. GTK 2.14 is the latest).
So you want to increase the minimum default requirement?
I agree with 2.8 (let's wait to see if Mattias and Marc also agree), but certainly not with the latest 2.14.
Even debian stable is having 2.8, as far as I can see, so maybe things are changing…
And Ubuntu 7.10 (2 releases old) comes with 2.12. I don't know what Ubuntu 8.04 or 8.10 ships with.
Regards,
- Graeme -
_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
2008/11/8 Graeme Geldenhuys :
8.10 is on 2.14.4.
henry
On Sat, Nov 8, 2008 at 9:59 PM, Vincent Snijders And Ubuntu 7.10 (2 releases old) comes…
And Ubuntu 7.10 (2 releases old) comes with 2.12. I don't know what Ubuntu 8.04 or 8.10 ships with.
8.10 comes with 2.14.4
So you want to increase the minimum default requirement? I agree with 2.8 (let's wait to…
I see no problem with 2.8 as minimum.
Mattias
I think if we are going to do that, some form of compatibility test on startup with a little message box saying (Your GTK version is x.x and the minimum we require is y.y, please upgrade to use this software) is a good idea. Firefox did this at one point and I found it much more informative than it simply refusing to run or bombing out.
Even if it were implemented as a unit you inserted in the beginning of your uses clause and therefore optional, I _think_ it'd be a good idea. (I have been wrong before though)
Brad
Please everyone, don't duplicate effort. I've started a "gtkext" unit in packages/gtk2/src/gtkext which adds [all] 2.8+ stuff in a way which can be checked.
It works like this:
Say you got a new calls for componentX in 2.8 and also some other new calls in 2.10. You add these calls as dynamic loadable in a .inc file (named after the component) and add a Available_ComponentName_Version (e.g Available_GtkButton_2_12) function for EACH version in which a new thing is loadable. You also make Load and Free calls for the lib's syms and add those to init/fini of gtk2ext.pp.
I've already added some stuff, so please instead of bickering here, add your missing stuff in and use it from gtkext.
We'll eventually need also a "gdkext" probably tho.
On Sat, 8 Nov 2008 19:53:16 -0200 I see no problem with 2.8 as minimum. Mattias
Me neither.
Marc