Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
bec7e76c
Commit
bec7e76c
authored
3 years ago
by
Matthias Puchner
Browse files
Options
Downloads
Patches
Plain Diff
use SelectionDescriptor in InterferenceItems
parent
11ad2691
No related branches found
No related tags found
1 merge request
!393
Selection descriptor
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
GUI/Models/InterferenceItems.cpp
+13
-0
13 additions, 0 deletions
GUI/Models/InterferenceItems.cpp
GUI/Models/InterferenceItems.h
+3
-1
3 additions, 1 deletion
GUI/Models/InterferenceItems.h
with
16 additions
and
1 deletion
GUI/Models/InterferenceItems.cpp
+
13
−
0
View file @
bec7e76c
...
@@ -14,12 +14,14 @@
...
@@ -14,12 +14,14 @@
#include
"GUI/Models/InterferenceItems.h"
#include
"GUI/Models/InterferenceItems.h"
#include
"Base/Const/Units.h"
#include
"Base/Const/Units.h"
#include
"ComboProperty.h"
#include
"GUI/Models/DoubleDescriptor.h"
#include
"GUI/Models/DoubleDescriptor.h"
#include
"GUI/Models/FTDecayFunctionItems.h"
#include
"GUI/Models/FTDecayFunctionItems.h"
#include
"GUI/Models/FTDistributionItems.h"
#include
"GUI/Models/FTDistributionItems.h"
#include
"GUI/Models/GroupItem.h"
#include
"GUI/Models/GroupItem.h"
#include
"GUI/Models/Lattice2DItems.h"
#include
"GUI/Models/Lattice2DItems.h"
#include
"Sample/Aggregate/Interferences.h"
#include
"Sample/Aggregate/Interferences.h"
#include
"SelectionDescriptor.h"
// TODO (when back compatibility will be broken again)
// TODO (when back compatibility will be broken again)
// Make Interference1DLatticeItem::P_DECAY_FUNCTION and
// Make Interference1DLatticeItem::P_DECAY_FUNCTION and
...
@@ -86,6 +88,11 @@ DoubleDescriptor Interference1DLatticeItem::rotationAngle() const
...
@@ -86,6 +88,11 @@ DoubleDescriptor Interference1DLatticeItem::rotationAngle() const
return
d
;
return
d
;
}
}
SelectionDescriptor
<
FTDecayFunction1DItem
*>
Interference1DLatticeItem
::
decayFunction
()
const
{
return
SelectionDescriptor
<
FTDecayFunction1DItem
*>
(
item
<
GroupItem
>
(
P_DECAY_FUNCTION
));
}
// --------------------------------------------------------------------------------------------- //
// --------------------------------------------------------------------------------------------- //
Lattice2DItem
*
Interference2DAbstractLatticeItem
::
latticeType
()
const
Lattice2DItem
*
Interference2DAbstractLatticeItem
::
latticeType
()
const
...
@@ -424,3 +431,9 @@ DoubleDescriptor InterferenceRadialParaCrystalItem::kappa() const
...
@@ -424,3 +431,9 @@ DoubleDescriptor InterferenceRadialParaCrystalItem::kappa() const
{
{
return
DoubleDescriptor
(
getItem
(
P_KAPPA
),
Unit
::
unitless
);
return
DoubleDescriptor
(
getItem
(
P_KAPPA
),
Unit
::
unitless
);
}
}
SelectionDescriptor
<
FTDistribution1DItem
*>
InterferenceRadialParaCrystalItem
::
probabilityDistribution
()
const
{
return
SelectionDescriptor
<
FTDistribution1DItem
*>
(
item
<
GroupItem
>
(
P_PDF
));
}
This diff is collapsed.
Click to expand it.
GUI/Models/InterferenceItems.h
+
3
−
1
View file @
bec7e76c
...
@@ -15,6 +15,7 @@
...
@@ -15,6 +15,7 @@
#ifndef BORNAGAIN_GUI_MODELS_INTERFERENCEITEMS_H
#ifndef BORNAGAIN_GUI_MODELS_INTERFERENCEITEMS_H
#define BORNAGAIN_GUI_MODELS_INTERFERENCEITEMS_H
#define BORNAGAIN_GUI_MODELS_INTERFERENCEITEMS_H
#include
"GUI/Models/SelectionDescriptor.h"
#include
"GUI/Models/SessionGraphicsItem.h"
#include
"GUI/Models/SessionGraphicsItem.h"
class
FTDecayFunction1DItem
;
class
FTDecayFunction1DItem
;
...
@@ -55,6 +56,7 @@ public:
...
@@ -55,6 +56,7 @@ public:
DoubleDescriptor
rotationAngle
()
const
;
DoubleDescriptor
rotationAngle
()
const
;
template
<
typename
T
>
T
*
setDecayFunctionType
();
template
<
typename
T
>
T
*
setDecayFunctionType
();
SelectionDescriptor
<
FTDecayFunction1DItem
*>
decayFunction
()
const
;
};
};
class
Interference2DAbstractLatticeItem
:
public
InterferenceItem
{
class
Interference2DAbstractLatticeItem
:
public
InterferenceItem
{
...
@@ -167,7 +169,7 @@ public:
...
@@ -167,7 +169,7 @@ public:
DoubleDescriptor
dampingLength
()
const
;
DoubleDescriptor
dampingLength
()
const
;
DoubleDescriptor
domainSize
()
const
;
DoubleDescriptor
domainSize
()
const
;
DoubleDescriptor
kappa
()
const
;
DoubleDescriptor
kappa
()
const
;
SelectionDescriptor
<
FTDistribution1DItem
*>
probabilityDistribution
()
const
;
template
<
typename
T
>
T
*
setPDFType
();
template
<
typename
T
>
T
*
setPDFType
();
};
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment