QElectroTech  0.70
Public Member Functions | Private Member Functions | Private Attributes | List of all members
ElementItemEditor Class Referenceabstract

#include <elementitemeditor.h>

Public Member Functions

 ElementItemEditor (QETElementEditor *, QWidget *=nullptr)
 
 ~ElementItemEditor () override
 
virtual QETElementEditorelementEditor () const
 
virtual ElementSceneelementScene () const
 
virtual QUndoStack & undoStack () const
 
virtual QString elementTypeName () const
 
virtual void setElementTypeName (const QString &)
 
virtual void detach ()
 
virtual bool setPart (CustomElementPart *)=0
 
virtual bool setParts (QList< CustomElementPart *>)
 
virtual CustomElementPartcurrentPart () const =0
 
virtual void updateForm ()=0
 

Private Member Functions

 ElementItemEditor (const ElementItemEditor &)
 

Private Attributes

QETElementEditorelement_editor
 
QString element_type_name
 

Detailed Description

This is the base class for primitives editors within the element editor. It provides methods to access the editor itself, the undo stack, the edition scene and even a method to easily take a ChangePartCommand into account.

Definition at line 33 of file elementitemeditor.h.

Constructor & Destructor Documentation

◆ ElementItemEditor() [1/2]

ElementItemEditor::ElementItemEditor ( QETElementEditor editor,
QWidget *  parent = nullptr 
)

Constructeur

Parameters
editorQETElementEditor auquel cet editeur appartient
parentQWidget parent de cet editeur

Definition at line 27 of file elementitemeditor.cpp.

◆ ~ElementItemEditor()

ElementItemEditor::~ElementItemEditor ( )
inlineoverride

Definition at line 39 of file elementitemeditor.h.

◆ ElementItemEditor() [2/2]

ElementItemEditor::ElementItemEditor ( const ElementItemEditor )
private

Member Function Documentation

◆ currentPart()

virtual CustomElementPart* ElementItemEditor::currentPart ( ) const
pure virtual

◆ detach()

void ElementItemEditor::detach ( )
virtual

Detache l'editeur de la primitive qu'il edite. Equivaut a setPart(0)

See also
setPart

Definition at line 63 of file elementitemeditor.cpp.

References setPart().

◆ elementEditor()

QETElementEditor * ElementItemEditor::elementEditor ( ) const
virtual
Returns
le QETElementEditor auquel cet editeur appartient

Definition at line 34 of file elementitemeditor.cpp.

References element_editor.

Referenced by DynamicTextFieldEditor::fillInfoComboBox(), and DynamicTextFieldEditor::on_m_elmt_info_cb_activated().

◆ elementScene()

ElementScene * ElementItemEditor::elementScene ( ) const
virtual

◆ elementTypeName()

QString ElementItemEditor::elementTypeName ( ) const
virtual
Returns
Le nom du type d'element edite

Definition at line 49 of file elementitemeditor.cpp.

References element_type_name.

◆ setElementTypeName()

void ElementItemEditor::setElementTypeName ( const QString &  name)
virtual
Parameters
nameNom du type d'element edite

Definition at line 54 of file elementitemeditor.cpp.

References element_type_name.

◆ setPart()

virtual bool ElementItemEditor::setPart ( CustomElementPart )
pure virtual

◆ setParts()

virtual bool ElementItemEditor::setParts ( QList< CustomElementPart *>  )
inlinevirtual

Reimplemented in StyleEditor.

Definition at line 54 of file elementitemeditor.h.

◆ undoStack()

QUndoStack & ElementItemEditor::undoStack ( ) const
virtual

◆ updateForm()

virtual void ElementItemEditor::updateForm ( )
pure virtual

Implemented in DynamicTextFieldEditor, and TextEditor.

Member Data Documentation

◆ element_editor

QETElementEditor* ElementItemEditor::element_editor
private

Definition at line 61 of file elementitemeditor.h.

Referenced by elementEditor(), and elementScene().

◆ element_type_name

QString ElementItemEditor::element_type_name
private

Definition at line 62 of file elementitemeditor.h.

Referenced by elementTypeName(), and setElementTypeName().


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