[kepler-users] Port parameter like "combo box" - do we have something like this in Kepler

Christopher Brooks cxh at eecs.berkeley.edu
Wed Sep 24 11:50:29 PDT 2014


I may be confused here, but doesn't ChoiceStyle do this?

http://ptolemy.eecs.berkeley.edu/ptolemyII/ptII8.0/ptII/doc/codeDoc/ptolemy/actor/gui/style/ChoiceStyle.html

(BTW - About dynamic comboboxes, see: 
https://lists.eecs.berkeley.edu/sympa/arc/ptolemy-hackers/2008-07/msg00010.html)



$PTII/bin/vergil 
http://ptolemy.eecs.berkeley.edu/ptolemyII/ptII8.0/ptII/doc/codeDoc/ptolemy/actor/gui/style/ChoiceStyle.html 
uses it in the AudioCapture actor:




SoundSpectrum.xml contains:
> <entity name="AudioCapture" 
> class="ptolemy.actor.lib.javasound.AudioCapture">
>         <property name="sampleRate" 
> class="ptolemy.actor.parameters.SharedParameter" value="8000">
>             <property name="style" 
> class="ptolemy.actor.gui.style.ChoiceStyle">
>                 <property name="8000" 
> class="ptolemy.kernel.util.StringAttribute" value="8000">
>                 </property>
>                 <property name="11025" 
> class="ptolemy.kernel.util.StringAttribute" value="11025">
>                 </property>
>                 <property name="22050" 
> class="ptolemy.kernel.util.StringAttribute" value="22050">
>                 </property>
>                 <property name="44100" 
> class="ptolemy.kernel.util.StringAttribute" value="44100">
>                 </property>
>                 <property name="48000" 
> class="ptolemy.kernel.util.StringAttribute" value="48000">
>                 </property>
>             </property>
>         </property>
The way this appears in the model is that 
$PTII/ptolemy/actor/lib/javasound/javasound.xml has similar code so that 
in Vergil, when the actor is dragged in, the choices appear.

I'm not sure how this would work in Kepler.

_Christopher

On 9/24/14 11:36 AM, Ben Leinfelder wrote:
> Hi Michal,
> For use at runtime, you can present a combobox dialog that prompts for a selection and then outputs the selected value. Take a look at the Python examples distributed with Kepler to see if this will be useful for you.
> -ben
>
> On Sep 24, 2014, at 11:28 AM, Michal Owsiak <michal.owsiak at man.poznan.pl> wrote:
>
>> Hello Kepler team,
>>
>> I am looking for something that resembles combo box inside workflow.
>>
>> The idea here is that I define the parameter with values: {"a", "b", "c" } and then, I choose from one of these by right-click or click.
>>
>> Question here is. Do we have something like this in Kepler.
>>
>> Our approach, now, follows:
>>
>> a = "some value"
>> b = "some value b"
>> c = "some completely different value"
>> actual_parameter = a|b|c
>>
>> This way, we can determine the value of the parameter while still making everything pretty much consistent.
>>
>> However, this requires to edit the value and requires numerous parameters on canvas. If you have few of them with lots of options they can consume most of the workflow canvas.
>>
>> So, question is: do we have some sort of combo box as parameter inside Kepler.
>>
>> Thanks for the info
>>
>> Michal
>>
>> -- 
>> Michal Owsiak <michal.owsiak at man.poznan.pl>
>>
>> Institute of Bioorganic Chemistry PAS
>> Poznan Supercomputing and Networking Center
>> Noskowskiego 12/14, 61-704 Poznan, POLAND
>>
>> Phone: 00 48 61 858 21 81
>>
>> http://www.man.poznan.pl
>> _______________________________________________
>> Kepler-users mailing list
>> Kepler-users at kepler-project.org
>> http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users
> _______________________________________________
> Kepler-users mailing list
> Kepler-users at kepler-project.org
> http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users


-- 
Christopher Brooks, PMP                       University of California
Academic Program Manager & Software Engineer  US Mail: 337 Cory Hall
CHESS/iCyPhy/Ptolemy/TerraSwarm               Berkeley, CA 94720-1774
cxh at eecs.berkeley.edu, 707.332.0670           (Office: 545Q Cory)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nceas.ucsb.edu/kepler/pipermail/kepler-users/attachments/20140924/908be99b/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cbhbacce.png
Type: image/png
Size: 125019 bytes
Desc: not available
URL: <http://lists.nceas.ucsb.edu/kepler/pipermail/kepler-users/attachments/20140924/908be99b/attachment-0001.png>


More information about the Kepler-users mailing list