Skip to content
Snippets Groups Projects
Commit 3eb3d320 authored by Pospelov, Gennady's avatar Pospelov, Gennady
Browse files

COde cleanup in widgetbox GUI examples

parent 7b9e3c7d
No related branches found
No related tags found
No related merge requests found
Showing
with 126 additions and 51 deletions
......@@ -112,32 +112,33 @@ SimulationRegistry::SimulationRegistry()
// GUI examples
registerItem(
"gui_isgisaxs01", StandardSimulations::gui_IsGISAXS01,
"gui_CylinderAndPrisms", StandardSimulations::gui_CylinderAndPrisms,
"GUI: Mixture of cylinders and prisms without interference");
registerItem(
"gui_isgisaxs04_1DDL", StandardSimulations::gui_IsGISAXS041DDL,
"gui_Interference1DParaCrystal", StandardSimulations::gui_Interference1DParaCrystal,
"GUI: IsGISAXS04 example, 1DDL structure factor");
registerItem(
"gui_isgisaxs04_2DDL", StandardSimulations::gui_IsGISAXS042DDL,
"gui_Interference2DParaCrystal", StandardSimulations::gui_Interference2DParaCrystal,
"GUI: IsGISAXS04 example, 2DDL structure factor");
registerItem(
"gui_isgisaxs11", StandardSimulations::gui_IsGISAXS11,
"gui_CoreShellParticles", StandardSimulations::gui_CoreShellParticles,
"GUI: Core shell nanoparticles");
registerItem(
"gui_isgisaxs06a", StandardSimulations::gui_IsGISAXS06L1,
"gui_Interference2DSquareLattice", StandardSimulations::gui_Interference2DSquareLattice,
"GUI: 2D lattice with disorders");
registerItem(
"gui_isgisaxs06b", StandardSimulations::gui_IsGISAXS06L2,
"gui_Interference2DCenteredLattice", StandardSimulations::gui_Interference2DCenteredLattice,
"GUI: 2D lattice centered");
registerItem(
"gui_isgisaxs07", StandardSimulations::gui_IsGISAXS07,
"GUI: Mixture of fixed particles");
"gui_RotatedPyramids", StandardSimulations::gui_RotatedPyramids,
"GUI: Rotated pyramids");
registerItem(
"gui_multiple_layouts", StandardSimulations::gui_MultipleLayouts,
"GUI: Mixture of Cylinders and Prisms using Multiple Layouts");
......
......@@ -471,7 +471,7 @@ Simulation *StandardSimulations::Ripple1()
// -----------------------------------------------------------------------------
Simulation *StandardSimulations::gui_IsGISAXS01()
Simulation *StandardSimulations::gui_CylinderAndPrisms()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs01");
......@@ -490,7 +490,7 @@ Simulation *StandardSimulations::gui_IsGISAXS01()
}
Simulation *StandardSimulations::gui_IsGISAXS041DDL()
Simulation *StandardSimulations::gui_Interference1DParaCrystal()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs04_1DDL");
......@@ -507,7 +507,7 @@ Simulation *StandardSimulations::gui_IsGISAXS041DDL()
return result;
}
Simulation *StandardSimulations::gui_IsGISAXS042DDL()
Simulation *StandardSimulations::gui_Interference2DParaCrystal()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs04_2DDL");
......@@ -524,7 +524,7 @@ Simulation *StandardSimulations::gui_IsGISAXS042DDL()
return result;
}
Simulation *StandardSimulations::gui_IsGISAXS11()
Simulation *StandardSimulations::gui_CoreShellParticles()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs11");
......@@ -541,7 +541,7 @@ Simulation *StandardSimulations::gui_IsGISAXS11()
return result;
}
Simulation *StandardSimulations::gui_IsGISAXS06L1()
Simulation *StandardSimulations::gui_Interference2DSquareLattice()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs06a");
......@@ -558,7 +558,7 @@ Simulation *StandardSimulations::gui_IsGISAXS06L1()
return result;
}
Simulation *StandardSimulations::gui_IsGISAXS06L2()
Simulation *StandardSimulations::gui_Interference2DCenteredLattice()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs06b");
......@@ -575,7 +575,7 @@ Simulation *StandardSimulations::gui_IsGISAXS06L2()
return result;
}
Simulation *StandardSimulations::gui_IsGISAXS07()
Simulation *StandardSimulations::gui_RotatedPyramids()
{
SampleBuilderFactory factory;
SampleBuilder_t builder = factory.createBuilder("isgisaxs09b");
......
......@@ -48,13 +48,13 @@ Simulation *PolarizedDWBAMagCylinders2();
Simulation *LayerWithRoughness();
Simulation *Ripple2();
Simulation *Ripple1();
Simulation *gui_IsGISAXS01();
Simulation *gui_IsGISAXS041DDL();
Simulation *gui_IsGISAXS042DDL();
Simulation *gui_IsGISAXS11();
Simulation *gui_IsGISAXS06L1();
Simulation *gui_IsGISAXS06L2();
Simulation *gui_IsGISAXS07();
Simulation *gui_CylinderAndPrisms();
Simulation *gui_Interference1DParaCrystal();
Simulation *gui_Interference2DParaCrystal();
Simulation *gui_CoreShellParticles();
Simulation *gui_Interference2DSquareLattice();
Simulation *gui_Interference2DCenteredLattice();
Simulation *gui_RotatedPyramids();
Simulation *gui_MultipleLayouts();
Simulation *BeamDivergence();
Simulation *DetectorResolution();
......
......@@ -28,18 +28,18 @@
QMap<QString, QString > init_NameToRegistry()
{
QMap<QString, QString > result;
result["example01"] = "gui_isgisaxs01";
result["example02"] = "gui_isgisaxs04_1DDL";
result["example03"] = "gui_isgisaxs04_2DDL";
result["example04"] = "gui_isgisaxs11";
result["example01"] = "gui_CylinderAndPrisms";
result["example02"] = "gui_Interference1DParaCrystal";
result["example03"] = "gui_Interference2DParaCrystal";
result["example04"] = "gui_CoreShellParticles";
result["example05"] = "LayerWithRoughness";
result["example06"] = "gui_isgisaxs06a";
result["example07"] = "gui_isgisaxs07";
result["example06"] = "gui_Interference2DSquareLattice";
result["example07"] = "gui_RotatedPyramids";
result["example08"] = "part_distribution";
// temporary for testing
// result["example08"] = "beam_divergence";
// result["example08"] = "detector_resolution";
// result["example08"] = "gui_isgisaxs06b";
result["example08"] = "part_distribution";
return result;
}
......
......@@ -260,7 +260,7 @@
<category name="Standard samples">
<categoryentry name="Example #1 (no interference)" icon="images/sample_layers2.png">
<categoryentry name="Cylinder and prisms" icon="images/sample_layers2.png">
<widget class="example01">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -268,7 +268,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #2 (para radial)" icon="images/sample_layers2.png">
<categoryentry name="Interference 1D paracrystal" icon="images/sample_layers2.png">
<widget class="example02">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -276,7 +276,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #3 (para 2D)" icon="images/sample_layers2.png">
<categoryentry name="Interference 2D paracrystal" icon="images/sample_layers2.png">
<widget class="example03">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -284,7 +284,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #4 (core shell particle)" icon="images/sample_layers2.png">
<categoryentry name="Core shell particles" icon="images/sample_layers2.png">
<widget class="example04">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -292,7 +292,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #5 (correlated roughness)" icon="images/sample_layers2.png">
<categoryentry name="Multilayer with correlated roughness" icon="images/sample_layers2.png">
<widget class="example05">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -300,7 +300,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #6 (2D Lattice)" icon="images/sample_layers2.png">
<categoryentry name="Interference 2D square lattice" icon="images/sample_layers2.png">
<widget class="example06">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -308,7 +308,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #7 (Mixture of fixed particles)" icon="images/sample_layers2.png">
<categoryentry name="Rotated pyramids" icon="images/sample_layers2.png">
<widget class="example07">
<property name="objectName">
<string notr="true">somestring</string>
......@@ -316,7 +316,7 @@
</widget>
</categoryentry>
<categoryentry name="Example #8 Test" icon="images/sample_layers2.png">
<categoryentry name="Cylinders with size distribution" icon="images/sample_layers2.png">
<widget class="example08">
<property name="objectName">
<string notr="true">somestring</string>
......
......@@ -498,6 +498,80 @@
</property>
</category>
<category name="example01">
<property name="Title">
<tooltip>Mixture of cylinders and prisms without interference</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example02">
<property name="Title">
<tooltip>Interference 1D radial paracrystal</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example03">
<property name="Title">
<tooltip>Interference 2D paracrystal</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example04">
<property name="Title">
<tooltip>Core shell particles</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example05">
<property name="Title">
<tooltip>Multilayer with correlated roughness</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example06">
<property name="Title">
<tooltip>Interference 2D lattice</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example07">
<property name="Title">
<tooltip>Rotated pyramids on top of substrate</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
<category name="example08">
<property name="Title">
<tooltip>Cylinders with size distribution</tooltip>
</property>
<property name="Description">
<tooltip>Some lengthy description here if necessary</tooltip>
</property>
</category>
</context>
</ToolTipsData>
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs01");
return GUI_FUNCTIONAL_TEST("gui_CylinderAndPrisms");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs04_1DDL");
return GUI_FUNCTIONAL_TEST("gui_Interference1DParaCrystal");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs04_2DDL");
return GUI_FUNCTIONAL_TEST("gui_Interference2DParaCrystal");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs11");
return GUI_FUNCTIONAL_TEST("gui_CoreShellParticles");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs06a");
return GUI_FUNCTIONAL_TEST("gui_Interference2DSquareLattice");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs07");
return GUI_FUNCTIONAL_TEST("gui_RotatedPyramids");
}
......@@ -2,7 +2,7 @@
int main()
{
return GUI_FUNCTIONAL_TEST("gui_isgisaxs06b");
return GUI_FUNCTIONAL_TEST("gui_Interference2DCenteredLattice");
}
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs01");
simulationRegistry.createSimulation("gui_CylinderAndPrisms");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs01"
<< "(Mixture of cylinders and prisms without interference):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs04_1DDL");
simulationRegistry.createSimulation("gui_Interference1DParaCrystal");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs04_1DDL"
<< "(Radial paracrystal):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs04_2DDL");
simulationRegistry.createSimulation("gui_Interference2DParaCrystal");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs04_2DDL"
<< "(2D paracrystal):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs06a");
simulationRegistry.createSimulation("gui_Interference2DSquareLattice");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs06a"
<< "(2D lattice with disorders):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs06b");
simulationRegistry.createSimulation("gui_Interference2DCenteredLattice");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs06b"
<< "(2D lattice centered):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs07");
simulationRegistry.createSimulation("gui_RotatedPyramids");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs07"
<< "(Mixture of different particles a la IsGISAXS morphology file):"
......
......@@ -5,7 +5,7 @@ int main()
{
SimulationRegistry simulationRegistry;
Simulation *simulation =
simulationRegistry.createSimulation("gui_isgisaxs11");
simulationRegistry.createSimulation("gui_CoreShellParticles");
bool test = PyGenTools::testPyScript(simulation);
std::cout << "Python Script Generation Test for isgisaxs11"
<< "(Core shell nanoparticles):"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment