EuGTK - a GTK3 Library for Euphoria 4.x

A fast and easy-to-use 'toolkit' for GTK3 and Euphoria on Linux, Windows and OS X.

Euphoria is a fast interpreted language (several times faster than Python, for example), free and open source, with the option to automatically translate your Euphoria code into C, and then compile it to an executable, which runs even faster.

I've had good results running Euphoria on the Raspberry Pi 3, a cheap ($37.00) and tiny
(about the size of a pack of cigarettes) computer which is running Linux. See screenshot below.

The latest versions of Euphoria can be downloaded from OpenEuphoria.org.

The latest version of EuGTK will be at the DOWNLOAD link below.

Euphoria and the EuGTK library are free to use (GPL3) for any purpose. Extensive html docs are included with the downloads. Please take the time to read them.

Euphoria itself runs in text mode in a terminal; EuGTK adds a GUI, which can be built manually, with simple code as shown in the screenshot above, or designed using Glade.



Here's proof that Euphoria isn't a 'toy' programming language. The program on the right downloads/edits web pages, as well as downloading and running Euphoria programs those web pages link to. This is just over 500 lines of code, and took one day to write, (and two to test:)
Platforms

Linux
is the native platform for GTK. The needed GTK3 libraries are usually installed as part of the distro, or can be added with a simple apt-get command. No setup is required, just drag the demos folder from the .gz, and drop it into your home folder.

New with version 4.9.0: I have tested EuGTK with Windows 7 and the 64-bit version of the Gtk libraries for Windows. Sorry, I do not have a 32-bit Windows installation to test. If you know enough about Windows to be writing your own programs, you can probably make this work. (Until next week, when the latest required update breaks things again.)
Instructions for downloading the necessary GTK libraries for Windows are included in the readme.

OS X is also reported to work.
First, install MacPorts, and then the GTK3 library with this command "sudo port install gtk3".
That should eventually install the library to /opt/local/lib/libgtk-3.dylib.

EuGTK will automatically detect and use the appropriate libraries.

All you need is a plain text editor to write Euphoria programs, but EuGTK versions 4.8 and up have support for designing your user-interface  with Glade, and then writing a bit of 'glue' code in Euphoria to handle user events. This now works extremely well, allowing you to write very complex programs with very little hand-coding. You'll need the latest version of Glade (tested with 3.16.1) glade.gnome.org.

To download current version of the EuGTK wrapper and demo programs, click link below

Questions about EuGTK can be asked on the Euphoria Forum: http://openeuphoria.org/forum/index.wc

Download Links:

 EuGTK 4.12.2 latest Feb 1, 2017

StartingGlade.tar.gz   May 19, 2015   472k       

Just a quick-start introduction to using Glade with Euphoria and GTK3, for details, read the docs that come with EuGTK!          

Pete Eberlein's cross-platform WEE editor, written in Euphoria, uses EuGTK fo52k the Linux/OS X GUI. Download it here:  https://github.com/peberlein/WEE/


 Contents of EuGTK
  1. GtkEngine.e
  2. GtkEnums.e
  3. GtkPrinter.e
  4. GtkCairo.e
  5. GtkSourceView.plugin
  6. GtkWebKit.plugin
  7. other small support libraries

Plus more than 250 demos, including several simple games, simple web server, plus extensive html documentation. 

Requirements:

libgtk.3.8.0 or better.

Euphoria 4.0.5 or better. I recommend Euphoria 4.1 Beta 2: OpenEuphoria.org

Text editor -  any plain text editor will do, but try this useful cross-platform WEE editor written in Euphoria:
https://github.com/peberlein/WEE/

GTK docs - almost mandatory! You won't get far unless you have access to these.
Below: EuGTK running on Raspberry Pi 3, over lan to a Mint desktop.





© 2016 by Irv Mullins
Comments