Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2003-10

GTK problem

5 messages · 4 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Peter Huesser

Hello

I am just learning gtk and try to translate the examples in the "GTK+2.0 Tutorial" from Tony Gale and Ian Main to fpc. In chapter 7 there is a simple button example which uses the "gtk_image_new_from_file" function to load a xpm file. This function is included in the gtk2 release but fpc does not find it. I guess the gtk interface from fpc is not up to date with the newer releases of gtk (I am using fpc version 1.0.10). Is this correct ? If yes what release does fpc relay on and are there any plans to make the newer gtk features available ?

Thank's for any help

Pedro

Marco van de Voort
to Peter Huesser
Show quoted text 10 lines
Hello I am just learning gtk and try to translate the examples in the "GTK+2.0 Tutorial" from Tony Gale and Ian Main to fpc. In chapter 7 there is a simple button example which uses the "gtk_image_new_from_file" function to load a xpm file. This function is included in the gtk2 release but fpc does not find it. I guess the gtk interface from fpc is not up to date with the newer releases of gtk (I am using fpc version 1.0.10). Is this correct ? If yes what release does fpc relay on and are there any plans to make the newer gtk features available ?

Yes. FPC uses GTK 1.2, also because that is still the prime target of Lazarus.

Lazarus (lazarus.freepascal.org) is migrating to GTK2 however. Most GTK experts are on the lazarus maillists.

Vincent Snijders
Show quoted text 5 lines
-----Oorspronkelijk bericht----- Van: Peter Huesser Hello I am just learning gtk and try to translate the examples in the

"GTK+2.0

Tutorial" from Tony Gale and Ian Main to fpc. In chapter 7 there is a simple button example which uses the "gtk_image_new_from_file"

function to

load a xpm file. This function is included in the gtk2 release but fpc does not find it. I guess the gtk interface from fpc is not up to date with the newer releases of gtk (I am using fpc version 1.0.10). Is

this

correct ? If yes what release does fpc relay on and are there any

plans to

make the newer gtk features available?

You should probably use the gtk2 for pascal units, which can be found at http://gtk2forpascal.sourceforge.net/, instead of the gtk units that came with fpc 1.0.10. Those units are for gtk 1.2.

Regards,
Vincent Snijders.

Michael Van Canneyt
to Peter Huesser: Hello I am just learning gtk and try to translate the examples in the "GTK+2.0 Tutorial"…
Peter Huesser wrote
Hello I am just learning gtk and try to translate the examples in the "GTK+2.0 Tutorial" from Tony Gale and Ian Main to fpc. In chapter 7 there is a simple button example which uses the "gtk_image_new_from_file" function to load a xpm file. This function is included in the gtk2 release but fpc does not find it. I guess the gtk interface from fpc is not up to date with the newer releases of gtk (I am using fpc version 1.0.10). Is this correct ? If yes what release does fpc relay on and are there any plans to make the newer gtk features available ?

The gtk units provided by FPC are for version 1.X of GTK only.

The GTK 2 units are hosted on Sourceforge.
http://sourceforge.net/projects/gtk2forpascal/

Michael.