Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (2) </ [1] 2 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: Lua FLTK, comprehensive documentation?< Next Oldest | Next Newest >
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Jan. 29 2005,20:19 QUOTE

For the last couple of days I've been studying the documents from
http://lua-fltk.sourceforge.net/
http://www.lua.org/
http://www.fltk.org/
I've been learning a lot, but some things I assume would be simple don't seem to be covered, or are implemented differently between Lua and Lua-FLTK.  One example is writing to a file.  According to the Lua documentation, you can use io.output() and io.open() to specify an output file, but neither seem to work in Flua.  I was able to work around this by using execute() with Bash/echo to write a file, but it seems like I shouldn't have to do this.

I've also seen in flua example files the use of methods and objects not mentioned in the flua docs.

Does anyone know if there is more thorough documentation available which covers Lua-FLTK?  I find it frustrating to spend most of my time testing Lua code in Flua just to see whether or not that particular code is supported, and then often discoving that some of it is supported in Flua, but with a different syntax than what is used in Lua.

Thanks for any help.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
cbagger01 Offline





Group: Members
Posts: 4264
Joined: Oct. 2003
Posted: Jan. 29 2005,21:04 QUOTE

I don't know anything about either, but these guys may shed some light on the situation:

http://lua-users.org/

http://lua-users.org/wiki/ForTutorial

http://www.lua.org/pil/21.1.html
Back to top
Profile PM 
roberts Offline





Group: Members
Posts: 4983
Joined: Oct. 2003
Posted: Jan. 30 2005,07:03 QUOTE

I think the link for flua docs has been posted. Plus there are alot of gui samples there. flua is based on lua v4.0.1 and I found this quick reference helpful when using the lua only portion of the language.

http://www.zpeng.com/jenet/doc/lua_quick_ref4.pdf

I found the string library and the input/output library the most helpful.

There are alot of differences from v4.0.1 to v5.x.x.
lua is a very small easy to learn language and has very fast execution speed for a scripting language.

There are several samples of if already in DSL that I have written, also TOMSRTBT disk has more samples which are the same lua4 version. TOMS' site has a user contrib section where others have written lua4 programs.

But like any language, you need to keep using it, otherwise you soon forget.
I like the clean syntax of the language. There will be more lua and flua coming in future versions of DSL.

So try the quick reference, and then use google to search for more samples, just be sure it is lua v4.0.1
Back to top
Profile PM WEB 
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Jan. 30 2005,16:09 QUOTE

Thanks people.

The version may be a big part of my trouble.  I've been playing around with Lua 5, and using documentation from that version.

The example Flua files have helped me the most so far, particularly with syntax.  I began by seeing a lot of great features in the documents, and when I tried to use those features all I'd get were errors.  It seems that the Flua docs asume you already have a good understanding of Lua syntax.  At this point it's a bit confusing to understand why sometimes you'd use "box=", for example, when at other times you'd use "boxtype=".

The more I work with it, however, the more I enjoy it.  When I remember how it was when I first started doing Flash script, and then Bash script, i was stumbling with a lot of things that now are as simple as tying shoes...so that gives me hope =o)
Maybe eventually I'll even be doing real programming in C++, although so far I've been enjoying the fact that scripting allows you to accomplish tasks using no more than human-readable text files.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
reidar Offline





Group: Members
Posts: 92
Joined: Sep. 2004
Posted: Mar. 09 2005,15:22 QUOTE

Robert, the link above (to the quick reference for lua) doesn't leed me anywhere. Do you happen to have a copy somewhere, cause I would love to learn more about lua.

-r
Back to top
Profile PM 
9 replies since Jan. 29 2005,20:19 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (2) </ [1] 2 >/
reply to topic new topic new poll
Quick Reply: Lua FLTK

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code