[Paraview] Populating a servermanager list widget with string array

Utkarsh Ayachit utkarsh.ayachit at kitware.com
Thu Aug 21 09:32:07 EDT 2014


http://www.paraview.org/ParaView3/Doc/Nightly/www/cxx-doc/classvtkSMVectorProperty.html#af8cb120cc1a06704cdd1cc25122d2eca

On Thu, Aug 21, 2014 at 9:30 AM, Girish Ramesh <rgirish28 at gmail.com> wrote:
> Yes, I got it working. It was a simple repeat_command="1" which was missing.
> What does that do if I may ask? Does it call the getselection function
> repeatedly whenever there is an update? Thanks anyway!
>
>
> On 21 August 2014 15:21, Girish Ramesh <rgirish28 at gmail.com> wrote:
>>
>> Ok, now it is not segfaulting but it is also not loading the
>> DataArraySelection functions as none of the debug macros are triggered when
>> the plugin is loaded and any output statements that i have in the functions
>> are not printed out. This is confusing!
>>
>>
>> On 21 August 2014 15:16, Utkarsh Ayachit <utkarsh.ayachit at kitware.com>
>> wrote:
>>>
>>> I think the segfault is happening in SetUserEPK().
>>>
>>> On Thu, Aug 21, 2014 at 8:42 AM, Girish Ramesh <rgirish28 at gmail.com>
>>> wrote:
>>> > The Plugin loads fine according to the debugger, so it is something to
>>> > do
>>> > with the loading of the vtkDataArraySelector. I'm completely lost on
>>> > where
>>> > my code is messing up. I hope you can help Utkarsh. Thanks.
>>> >
>>> > Regards,
>>> > Girish
>>> >
>>> >
>>> > On 21 August 2014 14:35, Girish Ramesh <rgirish28 at gmail.com> wrote:
>>> >>
>>> >> This is the error that is printed out. I dunno what the problem is. I
>>> >> think it is to do with the vtkDataArraySelection being returned. It
>>> >> was
>>> >> atleast loading the ServerManager GUI before I added the function for
>>> >> returning the Selection. Any thoughts? Thank you and sorry for being a
>>> >> bother.
>>> >>
>>> >>
>>> >>
>>> >> -------------------
>>> >>
>>> >> *** glibc detected ***
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview:
>>> >> double free or corruption (!prev): 0x0000000000b6f720 ***
>>> >> ======= Backtrace: =========
>>> >> /lib64/libc.so.6(+0x76808)[0x2b6ce2c97808]
>>> >> /lib64/libc.so.6(cfree+0x6c)[0x2b6ce2c9c84c]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/paraview/ParaView-v4.1.0/Plugins/ReadUALGrid/libReadUALGrid.so(_ZN11ReadUALGrid7SetUserEPKc+0x21d)[0x2b6ced506fdb]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/paraview/ParaView-v4.1.0/Plugins/ReadUALGrid/libReadUALGrid.so(_Z18ReadUALGridCommandP26vtkClientServerInterpreterP13vtkObjectBasePKcRK21vtkClientServerStreamRS5_Pv+0x8ae)[0x2b6ced5088c1]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkClientServer-pv4.1.so.1(_ZN26vtkClientServerInterpreter19CallCommandFunctionEPKcP13vtkObjectBaseS1_RK21vtkClientServerStreamRS4_+0x158)[0x2b6cd58551c8]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkClientServer-pv4.1.so.1(_ZN26vtkClientServerInterpreter20ProcessCommandInvokeERK21vtkClientServerStreami+0x192)[0x2b6cd5859102]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkClientServer-pv4.1.so.1(_ZN26vtkClientServerInterpreter17ProcessOneMessageERK21vtkClientServerStreami+0x2b6)[0x2b6cd5858746]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkClientServer-pv4.1.so.1(_ZN26vtkClientServerInterpreter13ProcessStreamERK21vtkClientServerStream+0x1d)[0x2b6cd585880d]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN13vtkSIProperty14ProcessMessageER21vtkClientServerStream+0x3b)[0x2b6cd1e751bb]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN25vtkSIStringVectorProperty4PushERKNS_18vtkVectorOfStringsE+0x247)[0x2b6cd1e8aad7]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN25vtkSIStringVectorProperty17ReadXMLAttributesEP10vtkSIProxyP15vtkPVXMLElement+0x2c1)[0x2b6cd1e8b431]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN10vtkSIProxy15ReadXMLPropertyEP15vtkPVXMLElement+0x1a2)[0x2b6cd1e77832]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN10vtkSIProxy17ReadXMLAttributesEP15vtkPVXMLElement+0x18f)[0x2b6cd1e7649f]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN16vtkSISourceProxy17ReadXMLAttributesEP15vtkPVXMLElement+0x19)[0x2b6cd1e87809]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN10vtkSIProxy16CreateVTKObjectsEPN17paraview_protobuf7MessageE+0x6b2)[0x2b6cd1e76e12]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN16vtkSISourceProxy16CreateVTKObjectsEPN17paraview_protobuf7MessageE+0x65)[0x2b6cd1e89765]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN10vtkSIProxy4PushEPN17paraview_protobuf7MessageE+0x1d)[0x2b6cd1e7609d]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN16vtkPVSessionCore17PushStateInternalEPN17paraview_protobuf7MessageE+0x1f2)[0x2b6cd1e5ae32]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN16vtkPVSessionCore9PushStateEPN17paraview_protobuf7MessageE+0x37)[0x2b6cd1e592e7]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerImplementationCore-pv4.1.so.1(_ZN16vtkPVSessionBase9PushStateEPN17paraview_protobuf7MessageE+0x2d)[0x2b6cd1e56b2d]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerManagerCore-pv4.1.so.1(_ZN10vtkSMProxy16CreateVTKObjectsEv+0x363)[0x2b6cd195b663]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerManagerCore-pv4.1.so.1(_ZN16vtkSMSourceProxy16CreateVTKObjectsEv+0x15)[0x2b6cd199b7e5]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkPVServerManagerCore-pv4.1.so.1(_ZN24vtkSMSessionProxyManager13RegisterProxyEPKcS1_P10vtkSMProxy+0x532)[0x2b6cd19908f2]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqCore-pv4.1.so.1(_ZN15pqObjectBuilder19createProxyInternalERK7QStringS2_P8pqServerS2_S2_RK4QMapIS0_8QVariantE+0x3bb)[0x2b6ccf16451b]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqCore-pv4.1.so.1(_ZN15pqObjectBuilder12createSourceERK7QStringS2_P8pqServer+0x99)[0x2b6ccf160d09]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1(_ZN21pqSourcesMenuReaction12createSourceERK7QStringS2_+0xfa)[0x2b6cce6ec38a]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectPKS_iPPv+0x2bf)[0x2b6ce213d9bf]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1(_ZN23pqProxyGroupMenuManager9triggeredERK7QStringS2_+0x27)[0x2b6cce7042a7]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1(_ZN23pqProxyGroupMenuManager9triggeredEv+0x117)[0x2b6cce6db9a7]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObjectPKS_iPPv+0x2bf)[0x2b6ce213d9bf]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN7QAction9triggeredEb+0x32)[0x2b6ce116bda2]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN7QAction8activateENS_11ActionEventE+0x70)[0x2b6ce116bf90]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(+0x64b3b3)[0x2b6ce15a23b3]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(+0x6517c9)[0x2b6ce15a87c9]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN7QWidget5eventEP6QEvent+0x929)[0x2b6ce11c1a99]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN5QMenu5eventEP6QEvent+0x5b)[0x2b6ce15a9b0b]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent+0xac)[0x2b6ce1171fac]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN12QApplication6notifyEP7QObjectP6QEvent+0x3eb)[0x2b6ce11766db]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN16QCoreApplication14notifyInternalEP7QObjectP6QEvent+0x8e)[0x2b6ce21284de]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN19QApplicationPrivate14sendMouseEventEP7QWidgetP11QMouseEventS1_S1_PS1_R8QPointerIS0_Eb+0x14b)[0x2b6ce1172deb]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(+0x29677c)[0x2b6ce11ed77c]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(_ZN12QApplication15x11ProcessEventEP7_XEvent+0xaf1)[0x2b6ce11ec651]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(+0x2bb322)[0x2b6ce1212322]
>>> >>
>>> >> /usr/lib64/libglib-2.0.so.0(g_main_context_dispatch+0x24a)[0x2b6ce8dad60a]
>>> >> /usr/lib64/libglib-2.0.so.0(+0x3ee88)[0x2b6ce8db0e88]
>>> >>
>>> >> /usr/lib64/libglib-2.0.so.0(g_main_context_iteration+0x6c)[0x2b6ce8db103c]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE+0x66)[0x2b6ce2156ac6]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtGui.so.4(+0x2bafae)[0x2b6ce1211fae]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN10QEventLoop13processEventsE6QFlagsINS_17ProcessEventsFlagEE+0x2f)[0x2b6ce21270df]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE+0x138)[0x2b6ce2127368]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/qt/lib/libQtCore.so.4(_ZN16QCoreApplication4execEv+0x88)[0x2b6ce212c248]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview(main+0x185)[0x407ac5]
>>> >> /lib64/libc.so.6(__libc_start_main+0xe6)[0x2b6ce2c3fc16]
>>> >>
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview[0x407879]
>>> >> ======= Memory map: ========
>>> >> 00400000-008bb000 r-xp 00000000 00:19 102783069
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview
>>> >> 00abb000-00abc000 r--p 004bb000 00:19 102783069
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview
>>> >> 00abc000-00abd000 rw-p 004bc000 00:19 102783069
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/paraview
>>> >> 00abd000-01fc4000 rw-p 00000000 00:00 0
>>> >> [heap]
>>> >> 2b6cce41f000-2b6cce43e000 r-xp 00000000 fd:01 16791
>>> >> /lib64/ld-2.11.3.so
>>> >> 2b6cce43e000-2b6cce440000 rw-p 00000000 00:00 0
>>> >> 2b6cce63d000-2b6cce63e000 r--p 0001e000 fd:01 16791
>>> >> /lib64/ld-2.11.3.so
>>> >> 2b6cce63e000-2b6cce63f000 rw-p 0001f000 fd:01 16791
>>> >> /lib64/ld-2.11.3.so
>>> >> 2b6cce63f000-2b6cce640000 rw-p 00000000 00:00 0
>>> >> 2b6cce640000-2b6cce743000 r-xp 00000000 00:19 67479375
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1
>>> >> 2b6cce743000-2b6cce943000 ---p 00103000 00:19 67479375
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1
>>> >> 2b6cce943000-2b6cce94d000 r--p 00103000 00:19 67479375
>>> >>
>>> >> /pfs/work/kosl/sohpc/girish/paraview_plugin/staging/paraview/4.1/lib/paraview-4.1/libvtkpqApplicationComponents-pv4.1.so.1
>>> >> 2b6cce94d000-2b6cce950000 rw-p 0010d000 00:19 6
>>> >>
>>> >>
>>> >> On 21 August 2014 14:30, Utkarsh Ayachit <utkarsh.ayachit at kitware.com>
>>> >> wrote:
>>> >>>
>>> >>> I'd suggest looking at in the debugger and the tracking the segfault
>>> >>> down. Not sure where it could be going wrong.
>>> >>>
>>> >>> Utkarsh
>>> >>>
>>> >>> On Thu, Aug 21, 2014 at 8:25 AM, Girish Ramesh <rgirish28 at gmail.com>
>>> >>> wrote:
>>> >>> > Dear Utkarsh,
>>> >>> >
>>> >>> > Thank you for the email. I tried modelling it along the example
>>> >>> > mentioned.
>>> >>> > This is the code that I have written but it segfaults for no reason
>>> >>> > that is
>>> >>> > apparent to me.
>>> >>> >
>>> >>> > C++ Code:
>>> >>> >
>>> >>> > ReadUALGrid::ReadUALGrid()
>>> >>> > {
>>> >>> >   //this->FileName = NULL;
>>> >>> >   this->SetNumberOfInputPorts(0);
>>> >>> >   this->SetNumberOfOutputPorts(1);
>>> >>> >   this->trial=vtkSmartPointer<vtkDataArraySelection>::New();
>>> >>> >   this->trial->AddArray("hello");
>>> >>> >   this->trial->AddArray("world");
>>> >>> >   this->trial->EnableAllArrays();
>>> >>> > }
>>> >>> >
>>> >>> >
>>> >>> > }
>>> >>> >
>>> >>> > vtkDataArraySelection * ReadUALGrid::GetCPOListSelection(){
>>> >>> >
>>> >>> > return this->trial.GetPointer();
>>> >>> > }
>>> >>> >
>>> >>> >
>>> >>> > int ReadUALGrid::GetCPOListArrayStatus(char *name){
>>> >>> >
>>> >>> > return this->trial->GetArraySetting(name);
>>> >>> > }
>>> >>> >
>>> >>> > void ReadUALGrid::SetCPOListArrayStatus(const char * name, int
>>> >>> > status){
>>> >>> >
>>> >>> >         if (status){
>>> >>> >                 this->trial->EnableArray(name);
>>> >>> >         }
>>> >>> >         else{
>>> >>> >                 this->trial->DisableArray(name);
>>> >>> >         }
>>> >>> >
>>> >>> >
>>> >>> > }
>>> >>> >
>>> >>> >
>>> >>> > int ReadUALGrid::GetNumberOfCPOListArrays(){
>>> >>> >
>>> >>> >
>>> >>> > return this->trial->GetNumberOfArrays();
>>> >>> > }
>>> >>> >
>>> >>> >
>>> >>> > const char * ReadUALGrid::GetCPOListArrayName(int index){
>>> >>> >
>>> >>> > return this->trial->GetArrayName(index);
>>> >>> >
>>> >>> > }
>>> >>> >
>>> >>> >
>>> >>> > XML:
>>> >>> >
>>> >>> > <StringVectorProperty
>>> >>> >        name="CPOList"
>>> >>> >        label="CPOList"
>>> >>> >        command="SetCPOListArrayStatus"
>>> >>> >        number_of_elements="0"
>>> >>> >        number_of_elements_per_command="2"
>>> >>> >        element_types="2 0"
>>> >>> >        information_property="CPOListArrayStatus"
>>> >>> >        panel_visibility="default">
>>> >>> >
>>> >>> >        <ArraySelectionDomain name="array_list">
>>> >>> >         <RequiredProperties>
>>> >>> >         <Property function="ArrayList"
>>> >>> >                 name="CPOListArrayStatus"/>
>>> >>> >         </RequiredProperties>
>>> >>> >         </ArraySelectionDomain>
>>> >>> >         <Documentation>
>>> >>> >
>>> >>> >           This property specifies the CPO on the UAL Database.
>>> >>> >         </Documentation>
>>> >>> >      </StringVectorProperty>
>>> >>> >
>>> >>> >
>>> >>> >      <StringVectorProperty
>>> >>> >        name="CPOListArrayStatus"
>>> >>> >        information_only="1">
>>> >>> >         <ArraySelectionInformationHelper attribute_name="CPOList"/>
>>> >>> >      </StringVectorProperty>
>>> >>> >
>>> >>> >
>>> >>> > Any idea where I am making the mistake? Can I initialize a
>>> >>> > DataArraySelection that way? Thanks.
>>> >>> >
>>> >>> > Regards,
>>> >>> > Girish
>>> >>> >
>>> >>> >
>>> >>> > On 20 August 2014 22:49, Utkarsh Ayachit
>>> >>> > <utkarsh.ayachit at kitware.com>
>>> >>> > wrote:
>>> >>> >>
>>> >>> >> Try modeling this on "Point/Cell" array selection properties
>>> >>> >> provided
>>> >>> >> by readers (in readers.xml). You'd need to use the
>>> >>> >> ArraySelectionDomain, the StringListDomain won't work.
>>> >>> >>
>>> >>> >> e.g.
>>> >>> >>       <StringVectorProperty command="SetPointArrayStatus"
>>> >>> >>                             element_types="2 0"
>>> >>> >>                             information_property="PointArrayInfo"
>>> >>> >>                             label="Point Arrays"
>>> >>> >>                             name="PointArrayStatus"
>>> >>> >>                             number_of_elements="0"
>>> >>> >>                             number_of_elements_per_command="2"
>>> >>> >>                             repeat_command="1">
>>> >>> >>         <ArraySelectionDomain name="array_list">
>>> >>> >>           <RequiredProperties>
>>> >>> >>             <Property function="ArrayList"
>>> >>> >>                       name="PointArrayInfo" />
>>> >>> >>           </RequiredProperties>
>>> >>> >>         </ArraySelectionDomain>
>>> >>> >>         <Documentation>This property lists which point-centered
>>> >>> >> arrays
>>> >>> >> to
>>> >>> >>         read.</Documentation>
>>> >>> >>       </StringVectorProperty>
>>> >>> >>
>>> >>> >>
>>> >>> >>
>>> >>> >> On Wed, Aug 20, 2014 at 9:37 AM, Girish Ramesh
>>> >>> >> <rgirish28 at gmail.com>
>>> >>> >> wrote:
>>> >>> >> > Hi,
>>> >>> >> >
>>> >>> >> > I would like to use the panel_widget option in the servermanager
>>> >>> >> > XML
>>> >>> >> > with a
>>> >>> >> > String Array, but whenever I try to do it, it doesn't display
>>> >>> >> > anything.
>>> >>> >> > So,
>>> >>> >> > I'm wondering how it can be done even though it works with a
>>> >>> >> > normal
>>> >>> >> > StringVectorProperty for the default widget. Thank you. The XML
>>> >>> >> > and
>>> >>> >> > screenshot is given below.
>>> >>> >> >
>>> >>> >> > XML:
>>> >>> >> >
>>> >>> >> > <StringVectorProperty
>>> >>> >> >        name="CPOList"
>>> >>> >> >        label="CPOList"
>>> >>> >> >        command="SetCPOList"
>>> >>> >> >        number_of_elements="1"
>>> >>> >> >        panel_visibility="default"
>>> >>> >> >        panel_widget="list">
>>> >>> >> >        <StringListDomain name="array_list">
>>> >>> >> >         <RequiredProperties>
>>> >>> >> >         <Property function="ArrayList"
>>> >>> >> >                 name="CPOListInfo"/>
>>> >>> >> >         </RequiredProperties>
>>> >>> >> >         </StringListDomain>
>>> >>> >> >         <Documentation>
>>> >>> >> >           This property specifies the CPO on the UAL Database.
>>> >>> >> >         </Documentation>
>>> >>> >> >      </StringVectorProperty>
>>> >>> >> >
>>> >>> >> >
>>> >>> >> >      <StringVectorProperty
>>> >>> >> >        name="CPOListInfo"
>>> >>> >> >        label="CPOListInfo"
>>> >>> >> >        command="GetCPOList"
>>> >>> >> >        information_only="1">
>>> >>> >> >         <StringArrayHelper />
>>> >>> >> >      </StringVectorProperty>
>>> >>> >> >
>>> >>> >> > Screenshot of option working with default widget:
>>> >>> >> >
>>> >>> >> > https://imageshack.com/i/eyhM3mFKp
>>> >>> >> >
>>> >>> >> > Regards,
>>> >>> >> > Girish
>>> >>> >> >
>>> >>> >> > _______________________________________________
>>> >>> >> > 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://public.kitware.com/mailman/listinfo/paraview
>>> >>> >> >
>>> >>> >
>>> >>> >
>>> >>
>>> >>
>>> >
>>
>>
>


More information about the ParaView mailing list