Posted 11 February 2012 - 01:06 AM
I'd like for the next version of Redworks to have all programs ascii adjust to any screen size a user has. I played around with the syntax, but i'm a pure noob at getting it to work. Any snippets or examples of how i should do it, please submit.
Heres a quick program for example. How would i have this Fit to any GUI size a user has.
Heres a quick program for example. How would i have this Fit to any GUI size a user has.
Spoiler
term.setCursorBlink( false )
function clear()
term.clear()
term.setCursorPos(1,1)
end
function topBar()
print(" **"..os.version() .."0 [+] Redworks "..redworks.version().."**")
end
function mainMenu()
redworks.showWindow(7,4,36,10,"Redworks Control Panel","n 1.XXXXX 4.XXXXX 7.XXXXXnn 2.XXXXX 5.XXXXX 8.XXXXXnn 3.XXXXX 6.XXXXX 9.XXXXX")
end
function bottomBar()
term.setCursorPos(1,17)
print("PC-ID# " .. os.getComputerID())
term.setCursorPos(18,17)
print("[".. redworks.getUser().."]")
term.setCursorPos(40,17)
print("["..textutils.formatTime( os.time(), false ).."]")
end
clear()
topBar()
mainMenu()
bottomBar()
term.setCursorPos(1,9)
print"PREVnn<---"
term.setCursorPos(46,9)
print"NEXT"
print"nn--->"
while true do
bottomBar()
fault, event, param1, param2, param3 = pcall(os.pullEvent)
if fault == false then
elseif event == "key" and param1 == 2 then
clear()
break end
end