Archive for July, 2008

Compiling standalone PHP-GTK2 applications on windows using PriadoBlender

Monday, July 21st, 2008

If you’ve been wondering how to compile standalone PHP-GTK2 applications on windows using PriadoBlender, I’ve just written an article explaining the details.

Important Note: For now, PriadoBlender only works with the Gnope version of PHP-GTK (which is running PHP-GTK2 alpha version with PHP v5.1.4 and GTK+ v2.6.9). I’m sure the author of PriadoBlender will upgrade the program soon to work with PHP-GTK v2.0.

/kksou

http://www.kksou.com/php-gtk2
The place for php-gtk2 sample codes

Setting the background color of GtkButton

Wednesday, July 16th, 2008

I’ve written a sample code that shows how to set the background color of a GtkButton.

Sample Code 23: How to set the background color of GtkButton?

Some of you have written to me that the code does not work on your machine. The fix is as follows:

  1. Assuming you’re using the latest php-gtk v2.0.1
  2. Go to [php-gtk root folder]/etc/gtk-2.0 and open the file gtkrc in your favorite editor.
  3. Comment out lines 45, 46 and 47 as follows:
  4. #engine "wimp"
    
    #{
    
    #}
  5. Save and close the file.

Now try running the sample code again. Did it work this time?

/kksou

http://www.kksou.com/php-gtk2
The place for php-gtk2 sample codes