COPASI API
4.16.103
|
A widget class for Functions branch. More...
#include <FunctionWidget1.h>
Public Member Functions | |
FunctionWidget1 (QWidget *parent, const char *name=0, Qt::WFlags f=0) | |
virtual bool | leave () |
virtual bool | update (ListViews::ObjectType objectType, ListViews::Action action, const std::string &key) |
Function to update the COPASI widgets. More... | |
virtual | ~FunctionWidget1 () |
Destructor. More... | |
![]() | |
CopasiWidget (QWidget *parent=0, const char *name=0, Qt::WFlags f=0) | |
bool | enter (const std::string &key) |
CCopasiDataModel * | getDataModel () |
bool | getIgnoreUpdates () |
virtual void | setFramework (int framework) |
void | setIgnoreUpdates (bool v) |
Protected Slots | |
void | slotBtnCopy () |
void | slotBtnDelete () |
Slot for being activated whenever Delete button is clicked. More... | |
void | slotBtnNew () |
Slot for being activated wehenver New button is clicked. More... | |
virtual void | slotFcnDescriptionChanged (bool) |
Slot for changing the function description. More... | |
virtual void | slotReversibilityChanged () |
Slot for changing the reversibility of the function. More... | |
void | slotTableValueChanged (const QString &) |
Slot for changing the table value. More... | |
![]() | |
virtual bool | protectedNotify (ListViews::ObjectType objectType, ListViews::Action action, const std::string &key="") |
Protected Member Functions | |
bool | copyFunctionContentsToFunction (const CFunction *src, CFunction *target) |
virtual bool | enterProtected () |
bool | functionParametersChanged () |
bool | loadFromFunction (const CFunction *=NULL) |
bool | loadParameterTable () |
bool | loadReversibility (TriLogic rev) |
bool | loadUsageTable () |
Function to generate the text representation of the usage restrictions. More... | |
bool | saveToFunction () |
void | updateApplication () |
Protected Attributes | |
bool | flagChanged |
bool | isValid |
bool | mIgnoreFcnDescriptionChange |
CFunction * | mpFunction |
![]() | |
int | mFramework |
bool | mIgnoreUpdates |
std::string | mKey |
CCopasiDataModel * | mpDataModel |
ListViews * | mpListView |
CCopasiObject * | mpObject |
Private Member Functions | |
void | init () |
Private Attributes | |
std::string | mKeyToCopy |
bool | mReadOnly |
A widget class for Functions branch.
This widget shows detailed description of an individual function
Definition at line 29 of file FunctionWidget1.h.
FunctionWidget1::FunctionWidget1 | ( | QWidget * | parent, |
const char * | name = 0 , |
||
Qt::WFlags | f = 0 |
||
) |
Definition at line 49 of file FunctionWidget1.cpp.
References init().
|
virtual |
|
protected |
Definition at line 447 of file FunctionWidget1.cpp.
References CFunctionParameters::add(), C_INVALID_INDEX, CFunctionParameters::findParameterByName(), CEvaluationTree::getInfix(), CCopasiObject::getObjectName(), CFunction::getVariables(), CFunctionParameters::remove(), CFunction::setInfix(), and CFunctionParameters::size().
Referenced by saveToFunction().
|
protectedvirtual |
Reimplemented from CopasiWidget.
Definition at line 922 of file FunctionWidget1.cpp.
References CKeyFactory::get(), CCopasiRootContainer::getKeyFactory(), loadFromFunction(), mKeyToCopy, CopasiWidget::mpListView, CopasiWidget::mpObject, and ListViews::switchToOtherWidget().
|
protected |
Definition at line 508 of file FunctionWidget1.cpp.
References CKeyFactory::get(), CCopasiRootContainer::getKeyFactory(), CFunction::getVariables(), CopasiWidget::mKey, and mpFunction.
Referenced by leave().
|
private |
Definition at line 70 of file FunctionWidget1.cpp.
References mpFunction, and slotFcnDescriptionChanged().
Referenced by FunctionWidget1().
|
virtual |
Reimplemented from CopasiWidget.
Definition at line 753 of file FunctionWidget1.cpp.
References CFunctionDB::appendDependentFunctions(), CModel::appendDependentModelObjects(), FROM_UTF8, functionParametersChanged(), CKeyFactory::get(), CCopasiRootContainer::getDatamodelList(), CEvaluationTree::getDeletedObjects(), CCopasiRootContainer::getFunctionList(), CCopasiRootContainer::getKeyFactory(), CCopasiObject::getObjectName(), CQMessageBox::information(), isValid, CopasiWidget::mKey, and saveToFunction().
|
protected |
Definition at line 375 of file FunctionWidget1.cpp.
References CEvaluationTree::copy(), flagChanged, CEvaluationTree::getInfix(), CEvaluationTree::getType(), CFunction::isReversible(), CEvaluationTree::isUsable(), isValid, loadParameterTable(), loadReversibility(), loadUsageTable(), CEvaluationTree::MassAction, mIgnoreFcnDescriptionChange, mpFunction, mReadOnly, pdelete, and CEvaluationTree::PreDefined.
Referenced by enterProtected(), and update().
|
protected |
Definition at line 91 of file FunctionWidget1.cpp.
References COL_NAME, COL_UNIT, COL_USAGE, CFunctionParameter::DataTypeName, CModel::dimensionlessArea, CModel::dimensionlessLength, CModel::dimensionlessQuantity, CModel::dimensionlessTime, CModel::dimensionlessVolume, FROM_UTF8, CModel::getAreaUnitEnum(), CCopasiRootContainer::getDatamodelList(), CModel::getLengthUnitEnum(), CCopasiDataModel::getModel(), CModel::getQuantityUnitEnum(), CModel::getTimeUnitEnum(), CFunction::getVariables(), CModel::getVolumeUnitEnum(), CFunctionParameter::MODIFIER, mpFunction, mReadOnly, CFunctionParameter::PARAMETER, CFunctionParameter::PRODUCT, CFunctionParameter::RoleNameDisplay, CFindDimensions::setUseHeuristics(), CFunctionParameters::size(), slotTableValueChanged(), CFunctionParameter::SUBSTRATE, CFunctionParameter::TIME, CFunctionParameter::VARIABLE, and CFunctionParameter::VOLUME.
Referenced by loadFromFunction(), slotFcnDescriptionChanged(), and slotTableValueChanged().
|
protected |
Definition at line 352 of file FunctionWidget1.cpp.
References TriFalse, TriTrue, and TriUnspecified.
Referenced by loadFromFunction().
|
protected |
Function to generate the text representation of the usage restrictions.
Definition at line 255 of file FunctionWidget1.cpp.
References FROM_UTF8, CFunctionParameters::getNumberOfParametersByUsage(), CCopasiObject::getObjectName(), CFunction::getVariables(), CFunctionParameters::isVector(), mpFunction, CFunctionParameter::PRODUCT, and CFunctionParameter::SUBSTRATE.
Referenced by loadFromFunction(), slotFcnDescriptionChanged(), slotReversibilityChanged(), and slotTableValueChanged().
|
protected |
Definition at line 517 of file FunctionWidget1.cpp.
References ListViews::CHANGE, CCopasiDataModel::changed(), CEvaluationTree::compile(), copyFunctionContentsToFunction(), flagChanged, ListViews::FUNCTION, CKeyFactory::get(), CCopasiRootContainer::getKeyFactory(), CFunction::isReversible(), CopasiWidget::mKey, CopasiWidget::mpDataModel, mpFunction, CopasiWidget::protectedNotify(), CFunction::setReversible(), TriFalse, TriTrue, and TriUnspecified.
Referenced by leave().
|
protectedslot |
|
protectedslot |
Slot for being activated whenever Delete button is clicked.
Definition at line 676 of file FunctionWidget1.cpp.
References CQMessageBox::confirmDelete(), ListViews::DELETE, FROM_UTF8, ListViews::FUNCTION, CKeyFactory::get(), CEvaluationTree::getDeletedObjects(), CCopasiRootContainer::getFunctionList(), CCopasiRootContainer::getKeyFactory(), CCopasiObject::getObjectName(), CopasiWidget::mKey, CopasiWidget::protectedNotify(), and CFunctionDB::removeFunction().
|
protectedslot |
Slot for being activated wehenver New button is clicked.
Definition at line 647 of file FunctionWidget1.cpp.
References CFunctionDB::add(), ListViews::ADD, C_INVALID_INDEX, ListViews::FUNCTION, CCopasiRootContainer::getFunctionList(), CCopasiVectorN< CType >::getIndex(), CFunction::getKey(), CFunctionDB::loadedFunctions(), CopasiWidget::mpListView, CopasiWidget::protectedNotify(), ListViews::switchToOtherWidget(), and TO_UTF8.
|
protectedvirtualslot |
Slot for changing the function description.
This slot function is called whenever the function description is changed.
Definition at line 571 of file FunctionWidget1.cpp.
References CCopasiMessage::clearDeque(), CEvaluationTree::compile(), CQMessageBox::critical(), flagChanged, CCopasiMessage::getLastMessage(), isValid, loadParameterTable(), loadUsageTable(), MCFunction, mIgnoreFcnDescriptionChange, mpFunction, CCopasiMessage::peekLastMessage(), CFunction::setInfix(), and TO_UTF8.
Referenced by init().
|
protectedvirtualslot |
Slot for changing the reversibility of the function.
Definition at line 639 of file FunctionWidget1.cpp.
References loadUsageTable().
|
protectedslot |
Slot for changing the table value.
Definition at line 619 of file FunctionWidget1.cpp.
References flagChanged, CFunction::getVariables(), loadParameterTable(), loadUsageTable(), and mpFunction.
Referenced by loadParameterTable().
|
virtual |
Function to update the COPASI widgets.
Reimplemented from CopasiWidget.
Definition at line 715 of file FunctionWidget1.cpp.
References ListViews::CHANGE, ListViews::DELETE, ListViews::FUNCTION, CCopasiRootContainer::getKeyFactory(), loadFromFunction(), CopasiWidget::mIgnoreUpdates, CopasiWidget::mKey, and ListViews::MODEL.
|
protected |
|
protected |
Definition at line 62 of file FunctionWidget1.h.
Referenced by loadFromFunction(), saveToFunction(), slotFcnDescriptionChanged(), and slotTableValueChanged().
|
protected |
Definition at line 63 of file FunctionWidget1.h.
Referenced by leave(), loadFromFunction(), and slotFcnDescriptionChanged().
|
protected |
Definition at line 64 of file FunctionWidget1.h.
Referenced by loadFromFunction(), and slotFcnDescriptionChanged().
|
private |
Definition at line 73 of file FunctionWidget1.h.
Referenced by enterProtected(), and slotBtnCopy().
|
protected |
Definition at line 66 of file FunctionWidget1.h.
Referenced by functionParametersChanged(), init(), loadFromFunction(), loadParameterTable(), loadUsageTable(), saveToFunction(), slotFcnDescriptionChanged(), slotTableValueChanged(), and ~FunctionWidget1().
|
private |
Definition at line 71 of file FunctionWidget1.h.
Referenced by loadFromFunction(), and loadParameterTable().