Eu/Xwindows

new topic     » topic index » view thread      » older message » newer message

--Boundary_(ID_2FpIKOjQKBjXnemAgZkqXg)
Content-type: text/plain; CHARSET=US-ASCII
Content-transfer-encoding: 8bit

I have been experimenting with Euphoria and X, using a small (free) GUI library
from Australia, GraphApp. It is supposed to work on Windows, Linux, and
Macintosh. (see attached info file). I found this in the latest issue of Linux
Journal, "Graphical Toolkits for LInux Programs" by Patrick Lambert.
The toolkit can be downloaded from http://www.cs.usyd.edu.au/~loki/

The toolkit compiles to a static library, a single file (147k) which should make
distribution easy. So far, I have had little trouble wrapping the library
functions so Euphoria can use them in a sensible manner, but some of the more
complex stuff is still to come.  Example program follows:

-- Pizza

include dll.e
include machine.e
include appwrap.e

atom libw -- handle to the graphapp library
atom win, label, button -- widgets
atom pepperoni, sausage, anchovy -- controls (checkboxes)
atom coke, pepsi, beer -- controls (radio buttons)

win = new_window("Pizza Order System",{10,10,400,300},0)
label = new_label("Enter your order now",{20,20,200,30},0)
--toppings
 pepperoni = new_checkbox("Pepperoni",{10,50,100,20},0)
 sausage = new_checkbox("Sausage",{10,75,100,20},0)
 anchovy = new_checkbox("Anchovy",{10,100,100,20},0)
--beverage
 coke = new_radiobutton("Coke",{120,50,100,20},NULL)
 pepsi = new_radiobutton("Pepsi",{120,75,100,20},NULL)
 beer = new_radiobutton("Beer",{120,100,100,20},NULL)

button = new_button("OK",{10,200,80,30},0)
show(win)

Not too complex, I think, but there's still a long way to go.

Irv

--Boundary_(ID_2FpIKOjQKBjXnemAgZkqXg)
Content-type: text/html; name=about.htm

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu