Skip to content

adriweb/BetterLuaAPI-for-TI-Nspire

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

BetterLuaAPI for TI-Nspire.

Made by Adrien "Adriweb" Bertrand.

Thanks to Jim Bauwens, John Powers, Levak, LDStudios

How to use :

Copy in your code the functions you want and start using them, that's all ! :-) Please also write in your code/readme something like "[a part of] BetterLuaAPI by Adriweb was used"... Since this is all written in Nspire-Lua, it requires you to run any OS 3.x on your calculator. The latest OS updates are available on TI's Website.

New functions/things brought by BetterLuaAPI :

  • device table : informations about the user's device (apiversion ? , hasColor ? , isCalc ? , type of calc ? , current language ? )-
  • Colors table (can be used for setColor)
  • copyTable(table) (copies a table into another)
  • deepcopy(table) (deep-copies a table into another)
  • test(arg) (returns 1 if arg true or 0 if arg false)
  • screenRefresh() same as platform.window:invalidate() but shorter
  • pww() same as platform.window:width() but shorter
  • pwh() same as platform.window:height() but shorter
  • gc:drawPoint(x, y)
  • gc:drawCircle(x, y, radius)
  • gc:fillCircle(x, y, radius)
  • gc:fillGradientCircle(x, y, radius, color1Tbl, color2Tbl)
  • gc:fillGradientRect(x, y, w, h, color1Tbl, color2, direction) (direction can be 1 or 2)
  • gc:drawCenteredString(str)
  • gc:drawXCenteredString(str,y)
  • gc:setColor(theColor) (string or table of RGB)
  • gc:verticalBar(x)
  • gc:horizontalBar(y)
  • gc:drawSquare(x,y,l)
  • gc:drawRoundRect(x,y,width,height,radius)
  • gc:fillRoundRect(x,y,wd,ht,radius)
  • gc:clearWindow(theColor)

Notes :

More information about Lua programming on the TI-Nspire : Inspired-Lua and TI Calculators in general : TI-Planet.org

Contact : adrienbertrand @ msn . com

About

Improves the existing lua api for the Ti-Nspire

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages