majo_vlas
(majo vlas)
January 28, 2020, 11:15am
1
I am trying to make a custom application with Qt that is similar to ParaView but removing many things and adding others.
I’ve been playing with https://gitlab.kitware.com/paraview/paraview/tree/master/Examples/CustomApplications/Clone1
And I would like this custom application to come with some macros and a couple of custom filters that I made since installation.
Where does ParaView get the macros and filters and where is it in the code?
Thank you!
Any help on where is a good place to start is welcome!
mwestphal
(Mathieu Westphal (Kitware))
January 28, 2020, 12:12pm
2
Macros are added in custom applications the same way as in ParaView, through the Macros menu.
Filters are added in custom application the same way as they are added ParaView, through Plugins, but you can load them statically, see here : https://kitware.github.io/paraview-docs/latest/cxx/PluginHowto.html : Plugins in Static Applications
majo_vlas
(majo vlas)
January 28, 2020, 2:08pm
3
Okay, it looks like I can do it with the filters but I also hoped my clients didn’t have to load 10 macros when they installed the program for the first time.
It’s not possible with the macros?
mwestphal
(Mathieu Westphal (Kitware))
January 28, 2020, 2:47pm
4
You can automatically install the macros in the right directory so they are loaded automatically, but it is already the case with ParaView.
majo_vlas
(majo vlas)
January 28, 2020, 5:58pm
5
I’m sorry I don’t understand.
I would to avoid going to the Macros menu > Add new macro and search the macro for every macro that I have.
Are you saying that there is a directory that I can put my macros and avoid the “Add new macro” part?
Any idea what this directory is or where can I get the information?
Thanks!
mwestphal
(Mathieu Westphal (Kitware))
January 29, 2020, 3:37am
6
Yes, there is directories :
%CONFIG%/ParaView/Macros
%PARAVIEW_EXECUTABLE_DIR%/Macros
%PARAVIEW_EXECUTABLE_DIR%/../Macros
majo_vlas
(majo vlas)
February 6, 2020, 12:57am
7
I have discovered that if I put the macros in /Users/user/.config/ParaView/Macros
and open the ParaView installation, I see them in the toolbar.
But if I open the build of Clone1, they are not there. Therefore, I suppose the Clone1 build takes macros from another place.
Any idea where?
I also tried to find the other paths
%PARAVIEW_EXECUTABLE_DIR%/Macros
%PARAVIEW_EXECUTABLE_DIR%/ .. /Macros
But I did not find them anywhere.
mwestphal
(Mathieu Westphal (Kitware))
February 6, 2020, 2:07am
8
Remplace ApplicationName by your application name defined in your CMakeLists.txt