Algorithm for FUNCTIONS block implemented in GUI. Not yet full in MSR module.
This commit is contained in:
parent
e68de4133c
commit
0543c97b81
5
src/external/MuSRFitGUI/devel/MuSRFit.ui
vendored
5
src/external/MuSRFitGUI/devel/MuSRFit.ui
vendored
@ -3962,7 +3962,7 @@
|
||||
<cstring>TheoryBlock</cstring>
|
||||
</property>
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" row="0" column="1">
|
||||
@ -4228,7 +4228,7 @@
|
||||
<cstring>ParametersList</cstring>
|
||||
</property>
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</grid>
|
||||
@ -5458,6 +5458,7 @@
|
||||
<slot>RunSelectionToggle()</slot>
|
||||
<slot>fileBrowse()</slot>
|
||||
<slot>AppendToFunctions()</slot>
|
||||
<slot>ResetFunctions()</slot>
|
||||
</slots>
|
||||
<layoutdefaults spacing="6" margin="11"/>
|
||||
</UI>
|
||||
|
46
src/external/MuSRFitGUI/devel/MuSRFit.ui.h
vendored
46
src/external/MuSRFitGUI/devel/MuSRFit.ui.h
vendored
@ -570,7 +570,6 @@ void MuSRFitform::ActivateShComp()
|
||||
my $Full_T_Block= $All{"Full_T_Block"};
|
||||
|
||||
my $Component=1;
|
||||
CParamsCombo->clear();
|
||||
|
||||
foreach my $FitType (@FitTypes) {
|
||||
my $Parameters=$Paramcomp[$Component-1];
|
||||
@ -613,11 +612,6 @@ void MuSRFitform::ActivateShComp()
|
||||
}
|
||||
$Component++;
|
||||
}
|
||||
# Set theory block in Constraints
|
||||
TheoryBlock->setText($Full_T_Block);
|
||||
# Then clear the text
|
||||
ConstraintLine->setText("");
|
||||
FunctionsBlock->setText("");
|
||||
}
|
||||
|
||||
void MuSRFitform::InitializeTab()
|
||||
@ -634,10 +628,6 @@ void MuSRFitform::InitializeTab()
|
||||
}
|
||||
}
|
||||
|
||||
# Initialize Parameters List in function block (constraints).
|
||||
my $ParametersList="";
|
||||
ParametersList->setText("");
|
||||
|
||||
my %PTable=MSR::PrepParamTable(\%All);
|
||||
|
||||
# Setup the table with the right size
|
||||
@ -646,9 +636,6 @@ void MuSRFitform::InitializeTab()
|
||||
InitParamTable->setNumRows($NParam);
|
||||
}
|
||||
|
||||
# Counter for function block (with out Alpha etc.)
|
||||
my $ParCount=0;
|
||||
|
||||
# Fill the table with labels and values of parametr
|
||||
for (my $PCount=0;$PCount<$NParam;$PCount++) {
|
||||
my ($Param,$value,$error,$minvalue,$maxvalue,$RUN) = split(/,/,$PTable{$PCount});
|
||||
@ -661,15 +648,6 @@ void MuSRFitform::InitializeTab()
|
||||
InitParamTable->setText($PCount,1,$error);
|
||||
InitParamTable->setText($PCount,2,$minvalue);
|
||||
InitParamTable->setText($PCount,3,$maxvalue);
|
||||
|
||||
# Also update Parameters List for the Functions block
|
||||
(my $Ptmp,my $tmp)=split(/_/,$Param);
|
||||
if ($Ptmp ne "" && $Ptmp ne "Alpha" && $Ptmp ne "N0" && $Ptmp ne "NBg") {
|
||||
$ParCount++;
|
||||
$ParametersList=$ParametersList."$Param is par$ParCount\n";
|
||||
ParametersList->setText($ParametersList);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -846,3 +824,27 @@ void MuSRFitform::AppendToFunctions()
|
||||
TheoryBlock->setText($Full_T_Block);
|
||||
}
|
||||
|
||||
void MuSRFitform::ResetFunctions()
|
||||
{
|
||||
# Initialize Parameters List in function block (constraints).
|
||||
my $ParametersList="";
|
||||
ParametersList->setText("");
|
||||
|
||||
# Counter for function block (with out Alpha etc.)
|
||||
my $ParCount=0;
|
||||
CParamsCombo->clear();
|
||||
|
||||
# Also update Parameters List for the Functions block
|
||||
(my $Ptmp,my $tmp)=split(/_/,$Param);
|
||||
if ($Ptmp ne "" && $Ptmp ne "Alpha" && $Ptmp ne "N0" && $Ptmp ne "NBg") {
|
||||
$ParCount++;
|
||||
$ParametersList=$ParametersList."$Param is par$ParCount\n";
|
||||
ParametersList->setText($ParametersList);
|
||||
}
|
||||
# Set theory block in Constraints
|
||||
TheoryBlock->setText($Full_T_Block);
|
||||
# Then clear the text
|
||||
ConstraintLine->setText("");
|
||||
FunctionsBlock->setText("");
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user