Editing Properties Of Writers: Difference between revisions

From ParaQ Wiki
Jump to navigationJump to search
(New page: There is currently no way to configure a writer before saving data in ParaView 3. For example, you may want to tell the writer whether or not to write out ghost cells or whether or not to ...)
 
No edit summary
Line 1: Line 1:
There is currently no way to configure a writer before saving data in ParaView 3. For example, you may want to tell the writer whether or not to write out ghost cells or whether or not to write out all the timesteps.
There is currently no way to configure a writer when saving data in ParaView 3. For example, you may want to tell the writer whether or not to write out ghost cells or whether to write out all the timesteps or just the current one.


Fortunately, the functionality is almost all implemented to support editing a writer's properties. The pqAutoGeneratedObjectPanel class enables editing of a pqProxy's properties via automatically generated Qt widgets based on the property types. Thus, any properties defined in writers.xml for a given writer will be editable from this interface (except for the filename and input proxy).  
Fortunately, much of the functionality we need to support editing a writer's properties is already implemented. The pqAutoGeneratedObjectPanel class enables editing of a pqProxy's properties via automatically generated Qt widgets based on the property types. Thus, any writer's properties defined in writers.xml will be editable from this interface (except for the filename and input proxy which we won't allow).  


What's left to do is write a pqWriter class that inherits from pqProxy. pqServerManagerObserver will create a pqWriter object when  a proxy is registered in the server manager that is a member of the "writers" group. pqMainWindowCore could be notified of this and create the pqAutoGeneratedObjectPanel in a new QDialg box.
What's left to do is to write a pqWriter class that inherits from pqProxy. When the pqWriterFactory creates and registers the writer proxy that can read the given data, pqServerManagerObserver will create a pqWriter object and emit a signal that tells pqMainWindowCore to create the pqAutoGeneratedObjectPanel (in its own dialog box instead of in the object inspector) for the pqWriter.
 
I think this is the most flexible solution. We leverage the work that's already been done to link properties with editable Qt widgets. And we'd be able to support new writers in the future with no problem.

Revision as of 17:42, 11 June 2007

There is currently no way to configure a writer when saving data in ParaView 3. For example, you may want to tell the writer whether or not to write out ghost cells or whether to write out all the timesteps or just the current one.

Fortunately, much of the functionality we need to support editing a writer's properties is already implemented. The pqAutoGeneratedObjectPanel class enables editing of a pqProxy's properties via automatically generated Qt widgets based on the property types. Thus, any writer's properties defined in writers.xml will be editable from this interface (except for the filename and input proxy which we won't allow).

What's left to do is to write a pqWriter class that inherits from pqProxy. When the pqWriterFactory creates and registers the writer proxy that can read the given data, pqServerManagerObserver will create a pqWriter object and emit a signal that tells pqMainWindowCore to create the pqAutoGeneratedObjectPanel (in its own dialog box instead of in the object inspector) for the pqWriter.

I think this is the most flexible solution. We leverage the work that's already been done to link properties with editable Qt widgets. And we'd be able to support new writers in the future with no problem.