lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

> So, I think I could use Lua to my benefit here.  Is Lua well suited to
> this type of task?
        Yes!  We used Lua (version 2.3 at that time) to develop a bind
to IUP (an interface toolkit) where we have many definitions of interface
elements.  Something like this (I'm not at the develop team anymore, so I'm
probably using wrong function names, but for the example this is enough):

ok_button = IupButton { title = "Ok", bgcolor = WHITE }
cancel_button = IupButton { title = "Cancel", bgcolor = WHITE }
dialog = IupDialog { ok_button, cancel_button; title = "Confirmation", }

	I had also used Lua to make an interface for a (FORTRAN) program
which have ugly configuration files.  The system offers some dialog boxes
with the options of the configuration file.  After selecting the options
the user could start the Fortran program that will process the configuration
file and the input data files.  This activation could be done by just
pressing a button: at that moment, the interface will generate the
configuration file and execute the program.
	Despite the advantage of using a visual interface instead of a
big text file with no explicit default values, the interface system had
the ability to convert from Celsius to Fahrenheit or to Kelvin and many
other conversions of Chemical scales, also it could verify ranges of
values so the Fortran program would never be started with a wrong
configuration file.

	Hope that this will help you!