I can now change the display panel for all sources/filters relating to
a view. Is there a way to set the display panel depending on the
source or filter?<br>
<br>
Thanks for all the help so far,<br>
Paul<br><br><div><span class="gmail_quote">On 03/01/2008, <b class="gmail_sendername">Clinton Stimpson</b> <<a href="mailto:clinton@elemtech.com">clinton@elemtech.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Paul Edwards wrote:<br>> Does this mean that I don't need to edit the main Paraview code?<br>That's correct. You can do this in a plugin.<br>> Do you have any examples of a plugin which does this?<br>The closest example is ParaView3/Examples/Plugins/GUIView. But what you
<br>want is different enough that it may not help much.<br>> If not, I would be happy to make one, but I'm still a little confused<br>> as to how to implement it. So far I have a plugin for the server and<br>> one for the client, adding a reader and panel to paraview. Below is
<br>> my CMake file:<br>><br>> 8<----------------------------------------------------------------<br>> FIND_PACKAGE(ParaView REQUIRED)<br>> INCLUDE(${PARAVIEW_USE_FILE})<br>><br>><br>> QT4_WRAP_CPP(MOC_SRCS
pqMyPanel.h)<br>> QT4_WRAP_UI(UIC_SRCS pqMyPanel.ui )<br>><br>> ADD_PARAVIEW_OBJECT_PANEL(IFACES IFACE_SRCS CLASS_NAME pqMyPanel<br>> XML_NAME MyReader XML_GROUP sources)<br>><br>>
<br>> ADD_PARAVIEW_PLUGIN(MyReaderSMPlugin "1.0"<br>> SERVER_MANAGER_XML vtkMyReader.xml<br>> SERVER_MANAGER_SOURCES vtkMyReader.cxx)<br>> ADD_PARAVIEW_PLUGIN(MyReaderGUIPlugin "
1.0"<br>> GUI_INTERFACES ${IFACES}<br>> GUI_RESOURCE_FILES pqMyReader.xml<br>> SOURCES pqMyPanel.cxx ${MOC_SRCS} ${UIC_SRCS}<br>> ${IFACE_SRCS})
<br>> ---------------------------------------------------------------->8<br>><br>> Is there a macro to add a display panel so the file can be auto<br>> generated, or do I need to create my own subclass for pqPlugin and
<br>> manually add it as one of the interfaces?<br>As Utkarsh said, you create your own implementation of<br>pqDisplayPanelInterface, not pqPlugin.<br>There's an ADD_PARAVIEW_DISPLAY_PANEL macro that you can follow as an
<br>example. Since you need to make your own pqDisplayPanelInterface, you<br>can't call that macro.<br>Your implementation of pqDisplayPanelInterface needs to be give to<br>ADD_PARAVIEW_PLUGIN's GUI_INTERFACES argument so it can put it in the
<br>pqPlugin implementation it creates.<br><br>Clint<br><br>> On 03/01/2008, *Utkarsh Ayachit* <<a href="mailto:utkarsh.ayachit@kitware.com">utkarsh.ayachit@kitware.com</a><br>> <mailto:<a href="mailto:utkarsh.ayachit@kitware.com">
utkarsh.ayachit@kitware.com</a>>> wrote:<br>><br>> Hi Paul,<br>><br>> In your plugin, you need to implement the pqDisplayPanelInterface<br>> (just<br>> what the pqStandardDisplayPanels in
pqDisplayProxyEditorWidget.cxx<br>> does)<br>> and the register it with the plugin manager. If you look at<br>> pqDisplayProxyEditorWidget::updatePanel, you'll see that it checks for<br>> all pqDisplayPanelInterface implementations registered and asks
<br>> them to<br>> create the panel for the source.<br>><br>> Utkarsh<br>><br>><br>> Robert Maynard wrote:<br>> ><br>> > Last time I asked the same question, I was told I would have to
<br>> include<br>> > the xmlName of my class to the conditional statement, and recompile<br>> > paraview to get custom display panels like TextSource to work.<br>> ><br>> > On Jan 3, 2008 9:12 AM, Paul Edwards <
<a href="mailto:paul.m.edwards@gmail.com">paul.m.edwards@gmail.com</a><br>> <mailto:<a href="mailto:paul.m.edwards@gmail.com">paul.m.edwards@gmail.com</a>><br>> > <mailto: <a href="mailto:paul.m.edwards@gmail.com">
paul.m.edwards@gmail.com</a><br>> <mailto:<a href="mailto:paul.m.edwards@gmail.com">paul.m.edwards@gmail.com</a>>>> wrote:<br>> ><br>> > I am trying to provide a custom display panel for a plugin I
<br>> have<br>> > created. The plugin is for a new source which is a subclass of<br>> > vtkMultiBlockPLOT3DReader (the plot3d file is generated from<br>> inputs<br>> > selected in the object panel) and I would like to customize the
<br>> > display options for my users.<br>> ><br>> > I can see this is done for "TextSource" and<br>> "TimeToTextConverter"<br>> > but when looking through the code (
pqObjectBuilder.cxx, line<br>> 400)<br>> > there is a conditional statement to check specifically for these<br>> > sources. Does this mean that it is not possible from a<br>> plugin? (Or
<br>> > am I looking in the wrong place here?)<br>> ><br>> > Any help would be appreciated, thanks in advance,<br>> > Paul<br>> ><br>> > PS Great software ;)
<br>> ><br>> > _______________________________________________<br>> > ParaView mailing list<br>> > <a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a> <mailto:
<a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a>><br>> <mailto:<a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a> <mailto:<a href="mailto:ParaView@paraview.org">ParaView@paraview.org
</a>>><br>> > <a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a><br>> ><br>> ><br>> ><br>> ><br>> ------------------------------------------------------------------------
<br>> ><br>> > _______________________________________________<br>> > ParaView mailing list<br>> > <a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a> <mailto:<a href="mailto:ParaView@paraview.org">
ParaView@paraview.org</a>><br>> > <a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a><br>> <<a href="http://www.paraview.org/mailman/listinfo/paraview">
http://www.paraview.org/mailman/listinfo/paraview</a>><br>><br>><br>> ------------------------------------------------------------------------<br>><br>> _______________________________________________<br>
> ParaView mailing list<br>> <a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a><br>> <a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a>
<br>><br><br></blockquote></div><br>