[Paraview] Plugin XML - property as astring

Michael Jackson mike.jackson at bluequartz.net
Sat Jun 12 04:03:30 EDT 2010


If I am understanding you correctly the filter that you wrote has a  
parameter named "DebutNomMai" and you want to set that value to  
"tata" (or something else the user selects).

If this is the case then you need to add the following to your filter  
class:

     vtkSetStringMacro( DebutNomMai )
     vtkGetStringMacro( DebutNomMai )

Then the xml will look like this:

<StringVectorProperty
         name="DebutNomMai"
         command="SetDebutNomMai"
         number_of_elements="1"
         default_values_delimiter=""
         default_values="tata">
       </StringVectorProperty>

That should work.
___________________________________________________________
Mike Jackson                      www.bluequartz.net
Principal Software Engineer       mike.jackson at bluequartz.net
BlueQuartz Software               Dayton, Ohio


On Jun 12, 2010, at 7:43 AM, Aurélien Marsan wrote:

> default_values="DebutNomMai; 'tata' "
>
> I don't think so.
>
> When I don't put the quote marks around "tata", an error occurs.
> ---> tata is not defined.
>
> The command is "SetParameter", and the filter try to execute
> DebutNomMai = tata
>
> ... Or I misunderstand something ?
>
> > <StringVectorProperty
> >        name="DebutNomMai"
> >        command="SetParameter"
> >        number_of_elements="2"
> >        default_values_delimiter=";"
> >        default_values="DebutNomMai;'tata'">
> >      </StringVectorProperty>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview



More information about the ParaView mailing list