### Author Topic: Updating WZGUILib  (Read 82548 times)

0 Members and 1 Guest are viewing this topic.

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #60 on: April 07, 2012, 02:49:31 pm »
wow, its been a while.
any way this is the place where i release my information so here is some information:
In V3 there will be a tabcontrol, yes a tabcontrol. here is an image of it in development.

Also if you have any questions or comments post them here

<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### Nick

• LV9 Veteran (Next: 1337)
• Posts: 1166
• Rating: +161/-3
• You just got omnom'd
##### Re: Updating WZGUILib
« Reply #61 on: April 07, 2012, 02:52:55 pm »
wow ö that's really nice.. so you can click on them with the mouse? great maybe you could give it a slightly different color and a little more alignement so it does not stick to the borders, but this is cool

if you would want me to help with some of the design or different styles, i would be glad to help you with this
« Last Edit: April 07, 2012, 02:55:55 pm by Nick »

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #62 on: April 07, 2012, 03:03:13 pm »
that would be great...
it isnt clickable yet due to the fact i just started about 30 min. ago and was just working on drawing it out
here is the current code for the tabcontrol and the table that is used to make the tabs
like i said it is in the very beginning stages and it will change alot befor i release v3
Code: [Select]
tabcontrol = class()function tabcontrol:init(x, y, width, height, tabcpntr, parent) self.x = x + parent.x self.y = y + parent.y self.xoff = x self.yoff = y self.width = width self.height = height self.parent = parent self.controls = {} self.tabcollection = tabcpntr self.curtab = startingtab self.tabcount = table.maxn(self.tabcollection) table.insert(parent.controls, self)endfunction tabcontrol:paint(gc) stroff = gc:getStringWidth("SOF") - 6 gc:setColorRGB(unpack(color.white)) gc:fillRect(self.x, self.y, self.width, self.height) gc:setColorRGB(unpack(color.black)) gc:drawRect(self.x, self.y, self.width, self.height) gc:drawRect(self.x, self.y - stroff, self.width, stroff) gc:setFont("sansserif", "r", 6) local y = self.y - 8 local x = self.x + 2 for _, bb in pairs(self.tabcollection) do bb.x = x bb.y = y bb.width = gc:getStringWidth(bb.text) bb.height = gc:getStringHeight(bb.text) if bb.selected then gc:setColorRGB(unpack(color.Bdark)) gc:fillRect(bb.x - 2, bb.y - 2, bb.width + 2, bb. height - 4) gc:setColorRGB(unpack(color.black)) end gc:drawRect(bb.x - 2, bb.y - 2, bb.width + 2, bb.height - 4) gc:drawString(bb.text, x, y, "middle") x = x + 5 + bb.width endendfunction tabcontrol:checkClick(x, y)endfunction tabcontrol:clicked(x, y)endfunction tabcontrol:getCurTab() for _, tabs in pairs(self.tabcollection) do if tabs.selected then return tabs end endend
Table:
Code: [Select]
 Tabs = {tab4 = {text = "Tab3", selected = false}, tab2 = {text = "Tab1", selected = true}, tab3 = {text = "Tab2", selected = false}, tab1 = {text = "Tab4", selected = false}}

i will be working on making a 3D style pack for release with V3, but only once i get the last bug eraticated from the form class
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### Nick

• LV9 Veteran (Next: 1337)
• Posts: 1166
• Rating: +161/-3
• You just got omnom'd
##### Re: Updating WZGUILib
« Reply #63 on: April 07, 2012, 03:04:44 pm »
I'll check it out in a while (this evening).

what do you mean with 3D? with gradients and stuff?

Oh and there's one thing i've seen on some places, what's that "for __," part? i mean, what does that __ sign to?
« Last Edit: April 07, 2012, 03:05:41 pm by Nick »

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #64 on: April 07, 2012, 03:24:42 pm »
ive never been realy able to figure it out what the _ sign does, i know my code loops through a table and uses values in them, i also know that it doesnt seem to want to go in order, if you knoticed my code for the tab table where tab1 is assigned the text "tab4". ive tried googleing it but without much luck

its just a false 3D, drawn with lines
if you have V2 in the buttons there is an opt3D paramater, it will be removed in 3 so poeple will be able to use a style pack
also go to cemetech to get the newest version, which is v2.1 beta
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### Nick

• LV9 Veteran (Next: 1337)
• Posts: 1166
• Rating: +161/-3
• You just got omnom'd
##### Re: Updating WZGUILib
« Reply #65 on: April 07, 2012, 03:37:34 pm »
I'm going to design a style that fits the nspire, isn't hard to port (without a lot of gradients) and a nice look ok? but just in photoshop, then you just have to tell me how to write it to your needs or do it yourself.

Also, i noticed that boxes are only activated when you select them by pressing the titlebar. Couldn't you change that somehow so that it gets selected by pressing the entire form?

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #66 on: April 07, 2012, 05:07:07 pm »
i am planning to work on that to make the form active,
and sounds great, just post it here
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### hoffa

• LV6 Super Member (Next: 500)
• Posts: 322
• Rating: +131/-13
##### Re: Updating WZGUILib
« Reply #67 on: April 07, 2012, 05:14:18 pm »
Oh and there's one thing i've seen on some places, what's that "for __," part? i mean, what does that __ sign to?
It's a convention (used in Python among others), it's no special character. Usually if we don't care about the variable we're looping with, it's better just to use "_" to explicitly show it's not important.

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #68 on: April 07, 2012, 06:19:19 pm »
that makes sence....
also tabs are clickable and can hold controls of their own

here are some pics:
« Last Edit: April 07, 2012, 06:33:02 pm by jwalker »
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### Nick

• LV9 Veteran (Next: 1337)
• Posts: 1166
• Rating: +161/-3
• You just got omnom'd
##### Re: Updating WZGUILib
« Reply #69 on: April 08, 2012, 02:45:40 am »
wonderful! and there's one other thing. If you have a long title (or a short titlebar), and the title comes further than the red/green buttons, will it be covered by them or will they cover the buttons? or is there just enough space to make it all fit?

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #70 on: April 08, 2012, 09:36:14 am »
that is something i have been meaning to work on, but since you cant drag windows to make them bigger or smaller, i havnt implemented it, it has been up to the programmer to make sure thier title is the right size. what this would do is determine if the maximize/minimize button is too close to the title, the title would display less charachters with a ".." after it.
Also i fixed the Fullscreen patamater bug and i made the windows clickable in other places than the title bar to activate them. you can only move a window by clicking the title bar.
The file i uploaded is what ive been testing 3d object creation and right now only buttons and textboxes have a "3D" look.

this includes all of the new features i listed above
« Last Edit: April 08, 2012, 10:38:04 am by jwalker »
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #71 on: April 08, 2012, 10:59:02 pm »
even though this is double posting.... its been quite a while sooooo

V2.1 is now released, it has to be approved on Ti-Calc and Omnimaga and Cemetech, also i noticed a v1 version on Ti-Planet that needs to be updated so, if you are like an admin on Ti-Planet, or the person who uploaded it would you please update it, i would but i didnt upload it so i dont think i can. The only reason im asking is that this is a MAJOR upgrade from v1. also in v2.1 i fixed the fullscreen patamater issue and also have made the body of the form clickable so you can activate it without clicking the titlebar

also ive included tabcontrol beta

also unicode support and listboxes, which i worked on today, will be released in V3
V3 will be released AFTER the new OS update. I will release 2 versions, one for 3.1 and one for 3.2, due to the fact many probably wont upgrade to 3.2 so we can have ndless
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

• Editor
• LV10 31337 u53r (Next: 2000)
• Posts: 1708
• Rating: +229/-17
##### Re: Updating WZGUILib
« Reply #72 on: April 09, 2012, 05:04:38 am »
( nice update btw ! )
« Last Edit: April 09, 2012, 05:05:04 am by adriweb »
My calculator programs
TI-Nspire Lua programming : Tutorials  |  API Documentation

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #73 on: April 09, 2012, 09:42:48 am »
Thanks, i think i finaly have a realy good Version.
I think i finaly have it bug free too

Also i have been requested to seperate the controls into seperate files, so i did, also i plan to write a "Programming with WZ" thing soon
« Last Edit: April 09, 2012, 09:49:53 am by jwalker »
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads

#### jwalker

• LV7 Elite (Next: 700)
• Posts: 660
• Rating: +13/-0
• Almost everything I have released includes a 'WZ'
##### Re: Updating WZGUILib
« Reply #74 on: April 11, 2012, 07:20:07 am »
Well, since it has been out for a while... Is there any comments, any ideas, any controls you would like to see?
<a href="http://www.nerdtests.com/ft_cg.php?im">
<img src="http://www.nerdtests.com/images/ft/cg.php?val=9612" alt="My computer geek score is greater than 41% of all people in the world! How do you compare? Click here to find out!"> </a>

Support Casio-Scene against the attacks of matt @ matpac.co.uk ! For more information: Casio-Scene shuts down & Matt actions threads