Re: Looking for Implementation Advice
hello list, i want to give only one advance i.e first u select both rows or coulumns then after u may give them in colour i.e very easy okay that u for your quoery bye; kiran kumar general operator On 10/4/05, Mike Doub <[EMAIL PROTECTED]> wrote: > > Hello List, > > I am looking for implementation advice on how best to solve a problem > displaying a graphical representation of a matrix of data. > > I have a variable that is set up with each line representing a row of > information, and each item of the line a value. There are a variable > number > of lines and values. I typically expect about 50 lines and 24 values. > > Something like this (as you can see I am thinking of using arrays with > split > and combine): > > Label1|0,0,1,3,5,6... > Label2|1,4,6,7,2,0... > Label3|5,4,4,3,-1,1... > . > . > . > > The graphic that I was envisioning was a group of small squares that would > contain colors, green for 0 and higher, orange for -1, red for -2 add > below. > The label would be next to each row of boxes. I would also like the user > to > be able to hover over one of the boxes and be able to see the actual > value. > > I have multiple data sets to be displayed. Initially I was thinking that I > would have one of this graphic per card, but having this as part of a > scrolling field would be nice. Anyway let's keep it simple and just assume > that it will be on each card. > > I am a bit stumped at how to: > 1) Build this graphical thing dynamically to accommodate difference > numbers > of rows and columns > 2) How to connect the appearance of each box to the data, both to set the > color and to get the hovering effect. > > I am totally open to suggestions at this point in how to better layout the > data and to build this graphical control. > > Thank you in advance for pointing me in a direction. > > Regards, > Mike > > > > > > ___ > use-revolution mailing list > use-revolution@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-revolution > ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: Looking for Implementation Advice
On 10/4/05, chandapu kiran kumar <[EMAIL PROTECTED]> wrote: > > hello list, > i want to give only one advance i.e first u select both rows or coulumns > then after u may give them in colour i.e very easy okay that u for your > quoery bye; > kiran kumar > general operator > > On 10/4/05, Mike Doub <[EMAIL PROTECTED]> wrote: > > > > Hello List, > > > > I am looking for implementation advice on how best to solve a problem > > displaying a graphical representation of a matrix of data. > > > > I have a variable that is set up with each line representing a row of > > information, and each item of the line a value. There are a variable > > number > > of lines and values. I typically expect about 50 lines and 24 values. > > > > Something like this (as you can see I am thinking of using arrays with > > split > > and combine): > > > > Label1|0,0,1,3,5,6... > > Label2|1,4,6,7,2,0... > > Label3|5,4,4,3,-1,1... > > . > > . > > . > > > > The graphic that I was envisioning was a group of small squares that > > would > > contain colors, green for 0 and higher, orange for -1, red for -2 add > > below. > > The label would be next to each row of boxes. I would also like the user > > to > > be able to hover over one of the boxes and be able to see the actual > > value. > > > > I have multiple data sets to be displayed. Initially I was thinking that > > I > > would have one of this graphic per card, but having this as part of a > > scrolling field would be nice. Anyway let's keep it simple and just > > assume > > that it will be on each card. > > > > I am a bit stumped at how to: > > 1) Build this graphical thing dynamically to accommodate difference > > numbers > > of rows and columns > > 2) How to connect the appearance of each box to the data, both to set > > the > > color and to get the hovering effect. > > > > I am totally open to suggestions at this point in how to better layout > > the > > data and to build this graphical control. > > > > Thank you in advance for pointing me in a direction. > > > > Regards, > > Mike > > > > > > > > > > > > ___ > > use-revolution mailing list > > use-revolution@lists.runrev.com > > Please visit this url to subscribe, unsubscribe and manage your > > subscription preferences: > > http://lists.runrev.com/mailman/listinfo/use-revolution > > > > ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: Looking for Implementation Advice
Mike Doub wrote: Hello List, I am looking for implementation advice on how best to solve a problem displaying a graphical representation of a matrix of data. I have a variable that is set up with each line representing a row of information, and each item of the line a value. There are a variable number of lines and values. I typically expect about 50 lines and 24 values. Something like this (as you can see I am thinking of using arrays with split and combine): Label1|0,0,1,3,5,6... Label2|1,4,6,7,2,0... Label3|5,4,4,3,-1,1... . . . The graphic that I was envisioning was a group of small squares that would contain colors, green for 0 and higher, orange for -1, red for -2 add below. The label would be next to each row of boxes. I would also like the user to be able to hover over one of the boxes and be able to see the actual value. I have multiple data sets to be displayed. Initially I was thinking that I would have one of this graphic per card, but having this as part of a scrolling field would be nice. Anyway let's keep it simple and just assume that it will be on each card. I am a bit stumped at how to: 1) Build this graphical thing dynamically to accommodate difference numbers of rows and columns 2) How to connect the appearance of each box to the data, both to set the color and to get the hovering effect. I am totally open to suggestions at this point in how to better layout the data and to build this graphical control. Thank you in advance for pointing me in a direction. Hi Mike - I'll point in a number of directions :-) I'd probably do #3 myself, assuming the 50 lines x 24 values is a realistic estimate, and that the max size you need to handle isn't too much larger than that. I can see three ways to get the colored squares - though there are probably dozens of other ways. 1. Use the "imageSource" for each character. Create images (either in your stack, or as PNG files) each a square of a different color. Set the text of the field to be something like Label 1 ABCD Lab 2 AADEC etc. Set the images source of each character to the appropriate PNG or image. 2. (similar) Do the same but instead of using imageSource for each character, use htmlText : set both color and bgcolor of each character in turn to the relevant color value as needed. (e.g. some code vaguely like: set the itemdel to TAB repeat with tLine = 1 to the number of lines in fld "Field" put the number of chars in item 2 of line tLine of fld "Field" into tNum repeat with tChar = 1 to tNum put char tChar of item 2 of line tLine of fld "Field" into tt put "" & tt & "" into tHtml set the htmlText of char tChar of item 2 of line tLine of fld "Field" to tHtml end repeat end repeat where the array "theColor" has been set up ahead of time. 3. Use a number of buttons, all square. Create a "template" button, with all the right characteristics (square, no border, etc. and hidden) Then for each value in each line create a new button (clone the template one), set its position, set its color according to the value, and then make it visible. [obviously, re-use buttons as needed] For the "hover" value, in case 3 you can simply set the tooltip of each button to the actual value. For cases 1 or 2, I think you'd need to do your own tracking of the mouse using a mouseMove handler and timer, then using mouse co-ords (or mouseChunk ??) to determine which char is the relevant one, and pop up the right value (maybe by setting the tooltip for the field - worth looking into whether you could do that). Hmmm - it would be nice if there was a tooltip event, which would trigger a handler "pre-appearance" to allow you to adjust the text. Would that be a worthwhile enhancement request ? -- Alex Tweedly http://www.tweedly.net -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.344 / Virus Database: 267.11.8/114 - Release Date: 28/09/2005 ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
RE: Looking for Implementation Advice
Thanks Alex, I appreciate your input. I was thinking about dynamically creating some array of objects, but I did not made to connection to put the data in the object itself. It is so obvious now. Setting the tool tip property is really clever. How would you recommend managing setting up the locations of the buttons? Do I just pick an x,y location on the stack and just start making incrementing the coordinates? I guess I need to do some experimenting. I am wondering if it is possible to create a group, make it invisible, create all of the buttons in the group, set the location of the group, and then make the group visible. Thanks again, you helped me solve the big problem of connecting the data. Regards, Mike -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Alex Tweedly Sent: Tuesday, October 04, 2005 5:14 PM To: How to use Revolution Subject: Re: Looking for Implementation Advice Mike Doub wrote: >Hello List, > >I am looking for implementation advice on how best to solve a problem >displaying a graphical representation of a matrix of data. > >I have a variable that is set up with each line representing a row of >information, and each item of the line a value. There are a variable number >of lines and values. I typically expect about 50 lines and 24 values. > >Something like this (as you can see I am thinking of using arrays with split >and combine): > >Label1|0,0,1,3,5,6... >Label2|1,4,6,7,2,0... >Label3|5,4,4,3,-1,1... >. >. >. > >The graphic that I was envisioning was a group of small squares that would >contain colors, green for 0 and higher, orange for -1, red for -2 add below. >The label would be next to each row of boxes. I would also like the user to >be able to hover over one of the boxes and be able to see the actual value. > >I have multiple data sets to be displayed. Initially I was thinking that I >would have one of this graphic per card, but having this as part of a >scrolling field would be nice. Anyway let's keep it simple and just assume >that it will be on each card. > >I am a bit stumped at how to: >1) Build this graphical thing dynamically to accommodate difference numbers >of rows and columns >2) How to connect the appearance of each box to the data, both to set the >color and to get the hovering effect. > >I am totally open to suggestions at this point in how to better layout the >data and to build this graphical control. > >Thank you in advance for pointing me in a direction. > > Hi Mike - I'll point in a number of directions :-) I'd probably do #3 myself, assuming the 50 lines x 24 values is a realistic estimate, and that the max size you need to handle isn't too much larger than that. I can see three ways to get the colored squares - though there are probably dozens of other ways. 1. Use the "imageSource" for each character. Create images (either in your stack, or as PNG files) each a square of a different color. Set the text of the field to be something like Label 1 ABCD Lab 2 AADEC etc. Set the images source of each character to the appropriate PNG or image. 2. (similar) Do the same but instead of using imageSource for each character, use htmlText : set both color and bgcolor of each character in turn to the relevant color value as needed. (e.g. some code vaguely like: > set the itemdel to TAB > repeat with tLine = 1 to the number of lines in fld "Field" > put the number of chars in item 2 of line tLine of fld "Field" > into tNum > repeat with tChar = 1 to tNum > put char tChar of item 2 of line tLine of fld "Field" into tt > put "" & tt & "" into tHtml > set the htmlText of char tChar of item 2 of line tLine of fld > "Field" to tHtml > end repeat > end repeat > where the array "theColor" has been set up ahead of time. 3. Use a number of buttons, all square. Create a "template" button, with all the right characteristics (square, no border, etc. and hidden) Then for each value in each line create a new button (clone the template one), set its position, set its color according to the value, and then make it visible. [obviously, re-use buttons as needed] For the "hover" value, in case 3 you can simply set the tooltip of each button to the actual value. For cases 1 or 2, I think you'd need to do your own tracking of the mouse using a mouseMove handler and timer, then using mouse co-ords (or mouseChunk ??) to determine which char is the relevant one, and pop up the right value (maybe by setting the tooltip for the field - worth looking into whether you could do that). Hmmm - it would be nice if there was a tooltip event, which would trigger a handler "
Re: Looking for Implementation Advice
Mike Doub wrote: How would you recommend managing setting up the locations of the buttons? Depends on whether your app is going to have resizeable windows or not, and whether you're going to put it in a scrolling group, and what else scrolls, and Do I just pick an x,y location on the stack and just start making incrementing the coordinates? I guess I need to do some experimenting. The way I usually start something like this is to create a graphic (just a box), and make it be the size (and location) I want to put the fancy graphics into. If I want to, I control it through the geometry manager (or my own geometry management). Then I can calculate co-ords for the text and boxes relative to that (and even use the size if I decide I want to let the individual parts stretch). Then once I can see something "done", I might get keep the box as a background, or hide it, or remove it and use co-ords from the group instead, or I am wondering if it is possible to create a group, make it invisible, create all of the buttons in the group, set the location of the group, and then make the group visible. Should be - though the time to create and make visible a few hundred buttons shouldn't be huge anyway. And the time to make existing buttons visible and/or change their location should be even quicker. (Warning - the time to delete them can be surprisingly large - so be wary of deleting and recreating them). In some ways, as a user, I quite like to see something happen - so having them appear as you go may be OK. If you prefer not to, use lockscreen and unlockscreen to make them all just "appear" at once. -- Alex Tweedly http://www.tweedly.net -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.344 / Virus Database: 267.11.10/119 - Release Date: 04/10/2005 ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution