Re; Custom Widget Technique Question
Len Morgan wrote: I'm working on a new project and I'd like some advice on how to create controls to use on a graphical process display. This will display a water pipeline system with all it's tanks, pipe, valves, ... Len, In addition to the comments by Richard Gaskin and Roger Guay, there is a stack by Glenn Fisher - Flow Analysis - posted on RevOnline that you should check out, if you haven't already. You might also be interested in my stack Dynamic Simulation v.2 and stacks by Roger Guay, also at RevOnline. I am also interested in simulation of pipelines and other flow systems, and have a simulator under development. Download the app at www.SimzLab.com - open SimzLab and go to course PureWaterLab, Division D3, Lab L2, then click the Simulations button. See the unit palette on the right side - these are groups which can be added to the flowsheet, where the script copies the group in the palette to the flowsheet. This was developed before Rev 3.5 behaviors, so the scripts are in library stacks. Please keep us informed of your developments in this area. Rich Herz h...@ucsd.edu ___ 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: Custom Widget Technique Question
Len et al, I have worked on similar projects/problems and am very interested in sharing thoughts such as this very valuable information from Richard Gaskin. I use his ideas throughout, but beyond this and for a project very similar to what you propose, I came up with the following solution, which seems to work very well for simulations that are not too complex. I define and build two different kind of objects: Control objects and Flow objects. For example, a valve would be a Control and a pipe would be a Flow. (Obviously you could have many different types of Controls and Flows.) Next build a 2-dim truth table (this could be an array) with Controls at the top and Flows in the first column. wherever an x appears, that flow is activated when the corresponding control is activated. IOW, anytime a control is activated, the truth table is queried to determine which flows to animate. As for the animation, I make extensive use of custom properties by calling the cAnimation of an object. For example I have a radial gage object whose cAnimation is FRadGage t1 where FRadGage is a function at the stack level that moves a pointer graphic of the control, and t1 is the animation target value for the simulation. Good luck and I hope this helps! Roger Guay On Sep 13, 2009, at 11:00 AM, use-revolution-requ...@lists.runrev.com wrote: Check out the new Behaviors in v3.5. This will let you use a button script that you could put anywhere (I tend to put mine in a library or a substack, depending on whether I plan to reuse them in other apps or not), and then assign the behavior of your template group to that button script. From then on it's really easy, since all your code is in one place. Using getProp and setProp you can adjust any number of things within the group from a single property setting. And if you use v3.5's new selectGroupedControls property for groups, you can keep your layout work clean since the pointer tool will treat the group as a single object, regardless of the setting of the global property of the same name. Use copy grpDescriptor to destinationStackDescriptor to add copies of groups to your layout. Keep us posted on how this goes. I love simulations, and would love to see what you come up with. -- Richard Gaskin Fourth World ___ 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
Custom Widget Technique Question
I'm working on a new project and I'd like some advice on how to create custom controls to use on a graphical process display. This will display a water pipeline system with all it's tanks, pipe, valves, flow/pressure meters etc. One of the items I have to display is a water tank and I need to display how much water is in it as both a number and a graphical representation of the water level. I've got the gist of the drawing managed but I'm going to have to have several of these and I don't want to hand create them every time so I'm looking to make a water tank custom control. I need to put it somewhere, send it a current level which would update the numeric display and set the water level. I'd also like to size them so I could have big ones and small ones. That's a long introduction to my actual question. I know I can make a group of the various parts and script the updating and possibly sizing using behavior scripts but once I've created it, where to I put it? Do I create a stack with this group on it and then clone it where I need it? Do I copy and paste (via script)? I can't add it to the Rev graphic object pallet like the datagrid is now. This is not the only custom control I'm going to need so I'm looking for a generic way to handle this kind of thing. In the end, the program will not only have a display of our pipeline but I'd also like to have a separate design program to create the system diagrams in case any other pipelines want to use the program. len morgan ___ 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: Custom Widget Technique Question
Len, this sounds really cool: I'm working on a new project and I'd like some advice on how to create custom controls to use on a graphical process display. This will display a water pipeline system with all it's tanks, pipe, valves, flow/pressure meters etc. One of the items I have to display is a water tank and I need to display how much water is in it as both a number and a graphical representation of the water level. I've got the gist of the drawing managed but I'm going to have to have several of these and I don't want to hand create them every time so I'm looking to make a water tank custom control. I need to put it somewhere, send it a current level which would update the numeric display and set the water level. I'd also like to size them so I could have big ones and small ones. That's a long introduction to my actual question. I know I can make a group of the various parts and script the updating and possibly sizing using behavior scripts but once I've created it, where to I put it? Do I create a stack with this group on it and then clone it where I need it? Do I copy and paste (via script)? I can't add it to the Rev graphic object pallet like the datagrid is now. This is not the only custom control I'm going to need so I'm looking for a generic way to handle this kind of thing. In the end, the program will not only have a display of our pipeline but I'd also like to have a separate design program to create the system diagrams in case any other pipelines want to use the program. Check out the new Behaviors in v3.5. This will let you use a button script that you could put anywhere (I tend to put mine in a library or a substack, depending on whether I plan to reuse them in other apps or not), and then assign the behavior of your template group to that button script. From then on it's really easy, since all your code is in one place. Using getProp and setProp you can adjust any number of things within the group from a single property setting. And if you use v3.5's new selectGroupedControls property for groups, you can keep your layout work clean since the pointer tool will treat the group as a single object, regardless of the setting of the global property of the same name. Use copy grpDescriptor to destinationStackDescriptor to add copies of groups to your layout. Keep us posted on how this goes. I love simulations, and would love to see what you come up with. -- Richard Gaskin Fourth World Revolution training and consulting: http://www.fourthworld.com Webzine for Rev developers: http://www.revjournal.com ___ 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: Custom Widget Technique Question
If you haven't seen Scott Rossi's work, you should. He's created some amazing controls. Buy or use for inspiration. http://www.tactilemedia.com/ click software; click TMGauge - Stephen Barncard San Francisco http://houseofcubes.com/disco.irev 2009/9/12 Len Morgan len-mor...@crcom.net I'm working on a new project and I'd like some advice on how to create custom controls to use on a graphical process display. This will display a water pipeline system with all it's tanks, pipe, valves, flow/pressure meters etc. One of the items I have to display is a water tank and I need to display how much water is in it as both a number and a graphical representation of the water level. I've got the gist of the drawing managed but I'm going to have to have several of these and I don't want to hand create them every time so I'm looking to make a water tank custom control. I need to put it somewhere, send it a current level which would update the numeric display and set the water level. I'd also like to size them so I could have big ones and small ones. That's a long introduction to my actual question. I know I can make a group of the various parts and script the updating and possibly sizing using behavior scripts but once I've created it, where to I put it? Do I create a stack with this group on it and then clone it where I need it? Do I copy and paste (via script)? I can't add it to the Rev graphic object pallet like the datagrid is now. This is not the only custom control I'm going to need so I'm looking for a generic way to handle this kind of thing. In the end, the program will not only have a display of our pipeline but I'd also like to have a separate design program to create the system diagrams in case any other pipelines want to use the program. len morgan ___ 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: Custom Widget Technique Question
Thank you for this Richard. This is the kind of information I was looking for. Perhaps I can provide a library of process control custom controls as a library like some people supply custom icon libraries. I'll keep you posted on what I come up with. len Richard Gaskin wrote: Using getProp and setProp you can adjust any number of things within the group from a single property setting. And if you use v3.5's new selectGroupedControls property for groups, you can keep your layout work clean since the pointer tool will treat the group as a single object, regardless of the setting of the global property of the same name. Use copy grpDescriptor to destinationStackDescriptor to add copies of groups to your layout. Keep us posted on how this goes. I love simulations, and would love to see what you come up with. -- Richard Gaskin Fourth World Revolution training and consulting: http://www.fourthworld.com Webzine for Rev developers: http://www.revjournal.com ___ 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