Hi Bertram,

The "Delay" actor in your model has a _icon attribute that sets the icon.
I suspect that this model was copy and pasted from a Ptolemy model.

>  <entity name="Delay" class="ptolemy.domains.sdf.lib.SampleDelay">
>         <property name="initialOutputs" class="ptolemy.data.expr.Parameter" 
> value="{1}">
>         </property>
>         <property name="_icon" class="ptolemy.vergil.icon.BoxedValueIcon">
>             <property name="attributeName" 
> class="ptolemy.kernel.util.StringAttribute" value="initialOutputs">
>             </property>
>             <property name="displayWidth" class="ptolemy.data.expr.Parameter" 
> value="20">
>             </property>
>         </property>
>         <property name="_location" class="ptolemy.kernel.util.Location" 
> value="[340.0, 70.0]">
>         </property>
>     </entity>

The "SampleDelay" actor xml is below.  Presumably it is getting
its icon from a SVG file somewhere.

>     <entity name="SampleDelay" class="ptolemy.domains.sdf.lib.SampleDelay">
>         <property name="initialOutputs" class="ptolemy.data.expr.Parameter" 
> value="{0}">
>         </property>
> <property name="KeplerDocumentation" 
> class="ptolemy.vergil.basic.KeplerDocumentationAttribute">
> <property name="description" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
> <property name="author" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>Steve 
> Neuendorffer, Edward A. Lee</configure></property>
> <property name="version" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
> <property name="userLevelDocumentation" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>&lt;p&gt;The 
> SampleDelay actor outputs a set of tokens that are used as initial input 
> values when a workflow starts up. The actor is used to break dependency 
> cycles created by  loops in SDF models. &lt;/p&gt;&#10;&#10;&lt;p&gt;Feedback 
> loops, created when an actor cycles its own output into its input port, can 
> create &quot;deadlock&quot; errors under an SDF Director. The deadlock errors 
> occur because the actor depends on its own output value as an initial input. 
> To fix this problem, use a SampleDelay actor to inject an initial value into 
> the workflow.&lt;/p&gt;&#10;&#10;&lt;p&gt;Specify an array of initial values 
> with the initialOutputs parameter. By default, the actor produces a single 
> integer token, {0}.&lt;/p&gt;</configure></property>
> <property name="port:output" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>An output port 
> that broadcasts the initial tokens.</configure></property>
> <property name="port:input" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>An input port 
> that accepts tokens of any type.</configure></property>
> <property name="prop:initialOutputs" 
> class="ptolemy.kernel.util.ConfigurableAttribute"><configure>The values 
> produced when the workflow is initialized. The value must be an array token, 
> and defaults to an array that contains a single integer token, 
> {0}.</configure></property>
> </property>        <property name="entityId" 
> class="org.kepler.moml.NamedObjId" 
> value="urn:lsid:kepler-project.org:actor:365:1">
>         </property>
>         <property name="class" class="ptolemy.kernel.util.StringAttribute" 
> value="ptolemy.domains.sdf.lib.SampleDelay">
>             <property name="id" class="ptolemy.kernel.util.StringAttribute" 
> value="urn:lsid:kepler-project.org:class:1131:1">
>             </property>
>         </property>
>         <property name="semanticType00" class="org.kepler.sms.SemanticType" 
> value="urn:lsid:localhost:onto:1:1#ControlActor">
>         </property>
>         <property name="semanticType11" class="org.kepler.sms.SemanticType" 
> value="urn:lsid:localhost:onto:2:1#WorkflowControl">
>         </property>
>         <property name="_location" class="ptolemy.kernel.util.Location" 
> value="[315.0, 175.0]">
>         </property>
>     </entity>

I tried searching for SampleDelay and dragging in the actor and it got
the right Kepler icon.

I also tried opening up a Ptolemy model that has a SampleDelay actor and it
got the right Kepler icon.

In Kepler, I don't think the user can edit the icon from the UI.  In Ptolemy,
there is an icon editor.

_Christopher


On 6/21/10 10:11 AM, Bertram Ludaescher wrote:
> Hi everybody:
>
> The attached workflow / screenshot has two different instances of the
> very same Delay actor,
> one looks like a microwave (just see for yourselves ;-) and one displays
> the sequence of delay tokens ('1' in this case).
>
> Does anybody know how one can control which icon is used?
> (that is the generic Kepler one/microwave, or the original Ptolemy one?)
>
> Looking at the MOML file, I see that the actor code is the same but some
> of the attributes are different.
> But can a user change the icon appearance? (or even a developer?)
>
> thanks
>
> Bertram
>
>
>
> _______________________________________________
> Kepler-users mailing list
> Kepler-users at kepler-project.org
> http://mercury.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users

-- 
Christopher Brooks, PMP                       University of California
CHESS Executive Director                      US Mail: 337 Cory Hall
Programmer/Analyst CHESS/Ptolemy/Trust        Berkeley, CA 94720-1774
ph: 510.643.9841 fax:510.642.2718             (Office: 545Q Cory)
home: (F-Tu) 707.665.0131 cell: 707.332.0670

Reply via email to