ICF 3.0.5.47
Technical documentation of ICF Libraries
icmpstr::CAttributeEditorComp Class Reference

#include <CAttributeEditorComp.h>

Inheritance diagram for icmpstr::CAttributeEditorComp:
Collaboration diagram for icmpstr::CAttributeEditorComp:

Classes

struct  AttrInfo
 

Public Types

enum  TabIndex {
  TI_GENERAL , TI_ATTRIBUTES , TI_INTERFACES , TI_EXPORTS ,
  TI_FLAGS
}
 
enum  AttrMeaning {
  AM_NONE = 0 , AM_REFERENCE , AM_FACTORY , AM_MULTI_REFERENCE ,
  AM_MULTI_FACTORY , AM_ATTRIBUTE , AM_BOOL_ATTRIBUTE , AM_MULTI_ATTRIBUTE ,
  AM_EXPORTED_ATTR , AM_EXPORTED_COMP , AM_MULTI
}
 
enum  AttributeGroupType { AGT_ATTRIBUTE , AGT_REFERENCE , AGT_FACTORY , AGT_LAST = AGT_FACTORY }
 
enum  AttributeColumns { AC_NAME = 0 , AC_VALUE = 1 }
 
enum  AttributeRole {
  AttributeMining = Qt::UserRole + 1 , AttributeId , AttributeValue , AttributeTypeId ,
  ElementId , InterfaceName
}
 
typedef istdgui::TGuiObserverWrap< istdgui::TDesignerGuiCompBase< Ui::CAttributeEditorComp >, CElementSelectionInfoManagerBaseBaseClass
 
- Public Types inherited from istdgui::TGuiComponentBase< QWidget >
typedef CGuiComponentBase BaseClass
 
- Public Types inherited from istdgui::CGuiComponentBase
typedef ibase::TVisualChangesHandlerWrap< icomp::CComponentBaseBaseClass
 
- Public Types inherited from ibase::TVisualChangesHandlerWrap< icomp::CComponentBase >
typedef icomp::CComponentBase BaseClass
 
- Public Types inherited from imod::IModelEditor
enum  ChangeFlags { CF_INIT_EDITOR = 0x3720694 }
 Data model change notification flags. More...
 

Signals

void AfterAttributesChange ()
 
void AfterInterfacesChange ()
 
void AfterSubcomponentsChange ()
 

Public Member Functions

 CAttributeEditorComp ()
 
const icomp::IMetaInfoManagerGetMetaInfoManagerPtr () const override
 
const icmpstr::IRegistryConsistInfoGetConsistencyInfoPtr () const override
 
- Public Member Functions inherited from istdgui::TGuiComponentBase< QWidget >
 TGuiComponentBase ()
 
virtual QWidget * GetQtWidget () const
 
- Public Member Functions inherited from istdgui::CGuiComponentBase
 I_REGISTER_SUBELEMENT_INTERFACE_T (VisualStatus, IVisualStatus, ExtractVisualStatus)
 
 I_REGISTER_SUBELEMENT_INTERFACE_T (VisualStatus, istd::IChangeable, ExtractVisualStatus)
 
 I_REGISTER_SUBELEMENT_INTERFACE_T (VisualStatus, imod::IModel, ExtractVisualStatus)
 
 CGuiComponentBase ()
 
bool IsGuiShown () const
 
bool IsGuiCreated () const override
 Inform if GUI was initilized.
 
bool CreateGui (QWidget *parentPtr) override
 Initialize GUI and connect it to the parent.
 
bool DestroyGui () override
 Release GUI and disconnect it from parent.
 
QWidget * GetWidget () const override
 Get access to internal QWidget object.
 
void OnTryClose (bool *ignoredPtr=nullptr) override
 Called on trying to close application.
 
- Public Member Functions inherited from ibase::TVisualChangesHandlerWrap< icomp::CComponentBase >
 TVisualChangesHandlerWrap (Args &&... args)
 
virtual void EnableVisualChangesHandler (bool enableLocalization=true)
 If enabled, listen to the language change event from the application context.
 
- Public Member Functions inherited from icomp::CComponentBase
 CComponentBase ()
 Create component and assign it to specific context.
 
 CComponentBase (const CComponentBase &)=delete
 
CComponentBaseoperator= (const CComponentBase &)=delete
 
virtual const ICompositeComponentGetParentComponent (bool ownerOnly=false) const
 Get parent of this component.
 
virtual void * GetInterface (const istd::CClassInfo &interfaceType, const QByteArray &subId="")
 Get access to specified component interface.
 
virtual const IComponentContextGetComponentContext () const
 Get access to component context describing all application-specified component information loaded from components registry.
 
virtual void SetComponentContext (const IComponentContext *contextPtr, const ICompositeComponent *parentPtr, bool isParentOwner)
 Set component context of this component.
 
- Public Member Functions inherited from icomp::IComponent
- Public Member Functions inherited from istdgui::IGuiObject
- Public Member Functions inherited from imod::IModelEditor
virtual void UpdateEditor (const istd::IChangeable::ChangeSet &changeSet)=0
 Updates editor with model data.
 
virtual void UpdateModelFromEditor () const =0
 Updates model from editor.
 
virtual bool IsReadOnly () const =0
 Returns true if the model data can be changed.
 
virtual void SetReadOnly (bool state)=0
 Set flag that the model data can be changed.
 

Protected Types

typedef QMap< QByteArray, AttrInfoElementIdToAttrInfoMap
 
typedef QMap< QByteArray, ElementIdToAttrInfoMapAttrInfosMap
 

Protected Slots

void on_AttributeTree_itemSelectionChanged ()
 
void on_AttributeTree_itemChanged (QTreeWidgetItem *item, int column)
 
void on_InterfacesTree_itemSelectionChanged ()
 
void on_InterfacesTree_itemChanged (QTreeWidgetItem *item, int column)
 
void on_AutoInstanceCB_toggled (bool checked)
 
void on_IsDetachedCB_toggled (bool checked)
 
void UpdateGeneralView ()
 
void UpdateAttributesView ()
 
void UpdateInterfacesView ()
 
void UpdateFlagsView ()
 
void UpdateSubcomponentsView ()
 

Protected Member Functions

bool SetAttributeToItem (AttributeGroupType groupType, int &itemIndex, const icomp::IRegistry &registry, const QByteArray &attributeId, const ElementIdToAttrInfoMap &infos, const QFont &normalFont, const QFont &importantFont, bool &hasError, bool &hasWarning, bool &hasExport) const
 
bool SetInterfaceToItem (QTreeWidgetItem &item, icomp::IRegistry::ExportedInterfacesMap *interfacesMapPtr, const QByteArray &elementId, const QByteArray &interfaceName, bool &hasWarning, bool &hasExport, bool readOnly) const
 
bool ResetItem (QTreeWidgetItem &item)
 
bool DecodeAttribute (const iser::ISerializable &attribute, QString &text, int &meaning) const
 
bool EncodeAttribute (const QString &text, int meaning, iser::ISerializable &result) const
 
void CreateInterfacesTree (const QByteArray &elementId, const icomp::IElementStaticInfo *infoPtr, icomp::IRegistry::ExportedInterfacesMap &registryInterfaces, QTreeWidgetItem *parentItemPtr, bool &hasWarning, bool &hasExport, bool includeSubelement, bool readOnly)
 
void CreateExportedComponentsTree (const QByteArray &elementId, const QByteArray &globalElementId, const icomp::IElementStaticInfo *elementMetaInfoPtr, QTreeWidgetItem &item, bool &hasWarning, bool &hasExport, bool readOnly) const
 
void OnGuiModelDetached () override
 
void UpdateGui (const istd::IChangeable::ChangeSet &changeSet) override
 
void OnGuiCreated () override
 Called just after GUI is initialized.
 
void OnGuiDestroyed () override
 Called just before GUI is released.
 
- Protected Member Functions inherited from istdgui::TGuiComponentBase< QWidget >
virtual QWidget * CreateQtWidget (QWidget *parentPtr)
 Create slave widget object.
 
- Protected Member Functions inherited from istdgui::CGuiComponentBase
virtual void OnGuiShown ()
 Called from widget event filter when slave widget is shown.
 
virtual void OnGuiHidden ()
 Called from widget event filter when slave widget is hidden.
 
virtual bool OnKeyPressed (QKeyEvent *event)
 Called from widget event filter when key is pressed.
 
virtual void OnRetranslate ()
 Called when non-GUI elements (like commands) should be retranslated.
 
virtual void OnGuiRetranslate ()
 Called from widget event filter when GUI should be retranslated.
 
void SetStatusIcon (const QIcon &icon)
 Set status icon;.
 
void SetStatusText (const QString &text)
 Set status text;.
 
void OnLanguageChanged () override
 
void OnDesignSchemaChanged () override
 
bool eventFilter (QObject *sourcePtr, QEvent *eventPtr) override
 
void OnComponentCreated () override
 
void OnComponentDestroyed () override
 
- Protected Member Functions inherited from ibase::TVisualChangesHandlerWrap< icomp::CComponentBase >
- Protected Member Functions inherited from icomp::CComponentBase
bool IsComponentActive () const
 Check if component is active.
 
virtual const IRealComponentStaticInfoGetComponentStaticInfo () const =0
 Get access to static info of this component.
 

Static Protected Member Functions

static QString DecodeFromEdit (const QString &text)
 
static QString EncodeToEdit (const QString &text)
 
- Static Protected Member Functions inherited from icomp::CComponentBase
static const IRealComponentStaticInfoInitStaticInfo (IComponent *componentPtr)
 
static QByteArray GetComponentId (const IComponentContext *componentContextPtr, const QByteArray &contextId=QByteArray())
 

Additional Inherited Members

- Static Public Member Functions inherited from istdgui::CGuiComponentBase
static void MakeAutoSlotConnection (const QWidget &widget, QObject &object)
 
- Protected Attributes inherited from istdgui::CGuiComponentBase
istd::CMainThreadCaller m_updateGuiCaller
 
imod::TModelWrap< VisualStatusm_visualStatus
 

Detailed Description

Definition at line 28 of file CAttributeEditorComp.h.

Member Typedef Documentation

◆ AttrInfosMap

Definition at line 133 of file CAttributeEditorComp.h.

◆ BaseClass

◆ ElementIdToAttrInfoMap

Definition at line 132 of file CAttributeEditorComp.h.

Member Enumeration Documentation

◆ AttributeColumns

Enumerator
AC_NAME 
AC_VALUE 

Definition at line 82 of file CAttributeEditorComp.h.

◆ AttributeGroupType

Enumerator
AGT_ATTRIBUTE 
AGT_REFERENCE 
AGT_FACTORY 
AGT_LAST 

Definition at line 74 of file CAttributeEditorComp.h.

◆ AttributeRole

Enumerator
AttributeMining 
AttributeId 
AttributeValue 
AttributeTypeId 
ElementId 
InterfaceName 

Definition at line 88 of file CAttributeEditorComp.h.

◆ AttrMeaning

Enumerator
AM_NONE 
AM_REFERENCE 
AM_FACTORY 
AM_MULTI_REFERENCE 
AM_MULTI_FACTORY 
AM_ATTRIBUTE 
AM_BOOL_ATTRIBUTE 
AM_MULTI_ATTRIBUTE 
AM_EXPORTED_ATTR 
AM_EXPORTED_COMP 
AM_MULTI 

Definition at line 59 of file CAttributeEditorComp.h.

◆ TabIndex

Enumerator
TI_GENERAL 
TI_ATTRIBUTES 
TI_INTERFACES 
TI_EXPORTS 
TI_FLAGS 

Definition at line 50 of file CAttributeEditorComp.h.

Constructor & Destructor Documentation

◆ CAttributeEditorComp()

icmpstr::CAttributeEditorComp::CAttributeEditorComp ( )

Member Function Documentation

◆ AfterAttributesChange

void icmpstr::CAttributeEditorComp::AfterAttributesChange ( )
signal

◆ AfterInterfacesChange

void icmpstr::CAttributeEditorComp::AfterInterfacesChange ( )
signal

◆ AfterSubcomponentsChange

void icmpstr::CAttributeEditorComp::AfterSubcomponentsChange ( )
signal

◆ CreateExportedComponentsTree()

void icmpstr::CAttributeEditorComp::CreateExportedComponentsTree ( const QByteArray & elementId,
const QByteArray & globalElementId,
const icomp::IElementStaticInfo * elementMetaInfoPtr,
QTreeWidgetItem & item,
bool & hasWarning,
bool & hasExport,
bool readOnly ) const
protected

◆ CreateInterfacesTree()

void icmpstr::CAttributeEditorComp::CreateInterfacesTree ( const QByteArray & elementId,
const icomp::IElementStaticInfo * infoPtr,
icomp::IRegistry::ExportedInterfacesMap & registryInterfaces,
QTreeWidgetItem * parentItemPtr,
bool & hasWarning,
bool & hasExport,
bool includeSubelement,
bool readOnly )
protected

◆ DecodeAttribute()

bool icmpstr::CAttributeEditorComp::DecodeAttribute ( const iser::ISerializable & attribute,
QString & text,
int & meaning ) const
protected

◆ DecodeFromEdit()

static QString icmpstr::CAttributeEditorComp::DecodeFromEdit ( const QString & text)
staticprotected

◆ EncodeAttribute()

bool icmpstr::CAttributeEditorComp::EncodeAttribute ( const QString & text,
int meaning,
iser::ISerializable & result ) const
protected

◆ EncodeToEdit()

static QString icmpstr::CAttributeEditorComp::EncodeToEdit ( const QString & text)
staticprotected

◆ GetConsistencyInfoPtr()

const icmpstr::IRegistryConsistInfo * icmpstr::CAttributeEditorComp::GetConsistencyInfoPtr ( ) const
override

◆ GetMetaInfoManagerPtr()

const icomp::IMetaInfoManager * icmpstr::CAttributeEditorComp::GetMetaInfoManagerPtr ( ) const
override

◆ on_AttributeTree_itemChanged

void icmpstr::CAttributeEditorComp::on_AttributeTree_itemChanged ( QTreeWidgetItem * item,
int column )
protectedslot

◆ on_AttributeTree_itemSelectionChanged

void icmpstr::CAttributeEditorComp::on_AttributeTree_itemSelectionChanged ( )
protectedslot

◆ on_AutoInstanceCB_toggled

void icmpstr::CAttributeEditorComp::on_AutoInstanceCB_toggled ( bool checked)
protectedslot

◆ on_InterfacesTree_itemChanged

void icmpstr::CAttributeEditorComp::on_InterfacesTree_itemChanged ( QTreeWidgetItem * item,
int column )
protectedslot

◆ on_InterfacesTree_itemSelectionChanged

void icmpstr::CAttributeEditorComp::on_InterfacesTree_itemSelectionChanged ( )
protectedslot

◆ on_IsDetachedCB_toggled

void icmpstr::CAttributeEditorComp::on_IsDetachedCB_toggled ( bool checked)
protectedslot

◆ OnGuiCreated()

void icmpstr::CAttributeEditorComp::OnGuiCreated ( )
overrideprotectedvirtual

Called just after GUI is initialized.

Reimplemented from istdgui::CGuiComponentBase.

◆ OnGuiDestroyed()

void icmpstr::CAttributeEditorComp::OnGuiDestroyed ( )
overrideprotectedvirtual

Called just before GUI is released.

Reimplemented from istdgui::CGuiComponentBase.

◆ OnGuiModelDetached()

void icmpstr::CAttributeEditorComp::OnGuiModelDetached ( )
overrideprotected

◆ ResetItem()

bool icmpstr::CAttributeEditorComp::ResetItem ( QTreeWidgetItem & item)
protected

◆ SetAttributeToItem()

bool icmpstr::CAttributeEditorComp::SetAttributeToItem ( AttributeGroupType groupType,
int & itemIndex,
const icomp::IRegistry & registry,
const QByteArray & attributeId,
const ElementIdToAttrInfoMap & infos,
const QFont & normalFont,
const QFont & importantFont,
bool & hasError,
bool & hasWarning,
bool & hasExport ) const
protected

◆ SetInterfaceToItem()

bool icmpstr::CAttributeEditorComp::SetInterfaceToItem ( QTreeWidgetItem & item,
icomp::IRegistry::ExportedInterfacesMap * interfacesMapPtr,
const QByteArray & elementId,
const QByteArray & interfaceName,
bool & hasWarning,
bool & hasExport,
bool readOnly ) const
protected

◆ UpdateAttributesView

void icmpstr::CAttributeEditorComp::UpdateAttributesView ( )
protectedslot

◆ UpdateFlagsView

void icmpstr::CAttributeEditorComp::UpdateFlagsView ( )
protectedslot

◆ UpdateGeneralView

void icmpstr::CAttributeEditorComp::UpdateGeneralView ( )
protectedslot

◆ UpdateGui()

void icmpstr::CAttributeEditorComp::UpdateGui ( const istd::IChangeable::ChangeSet & changeSet)
overrideprotected

◆ UpdateInterfacesView

void icmpstr::CAttributeEditorComp::UpdateInterfacesView ( )
protectedslot

◆ UpdateSubcomponentsView

void icmpstr::CAttributeEditorComp::UpdateSubcomponentsView ( )
protectedslot

The documentation for this class was generated from the following file:

© Witold Gantzke and Kirill Lepskiy