LibrePCB Developers Documentation
Loading...
Searching...
No Matches
ComponentPinSignalMapModel Class Referencefinal

The ComponentPinSignalMapModel class. More...

#include <componentpinsignalmapmodel.h>

Inherits QAbstractTableModel.

+ Collaboration diagram for ComponentPinSignalMapModel:

Public Types

enum  Column
 

Public Member Functions

 ComponentPinSignalMapModel ()=delete
 
 ComponentPinSignalMapModel (const ComponentPinSignalMapModel &other)=delete
 
 ComponentPinSignalMapModel (QObject *parent=nullptr) noexcept
 
 ~ComponentPinSignalMapModel () noexcept
 
void setSymbolVariant (ComponentSymbolVariant *variant) noexcept
 
void setSignalList (const ComponentSignalList *list) noexcept
 
void setSymbolsCache (const std::shared_ptr< const LibraryElementCache > &cache) noexcept
 
void setUndoStack (UndoStack *stack) noexcept
 
void autoAssignSignals () noexcept
 
int rowCount (const QModelIndex &parent=QModelIndex()) const override
 
int columnCount (const QModelIndex &parent=QModelIndex()) const override
 
QVariant data (const QModelIndex &index, int role=Qt::DisplayRole) const override
 
QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
 
Qt::ItemFlags flags (const QModelIndex &index) const override
 
bool setData (const QModelIndex &index, const QVariant &value, int role=Qt::EditRole) override
 
ComponentPinSignalMapModeloperator= (const ComponentPinSignalMapModel &rhs) noexcept
 

Private Member Functions

void symbolItemsEdited (const ComponentSymbolVariantItemList &list, int index, const std::shared_ptr< const ComponentSymbolVariantItem > &item, ComponentSymbolVariantItemList::Event event) noexcept
 
void signalListEdited (const ComponentSignalList &list, int index, const std::shared_ptr< const ComponentSignal > &signal, ComponentSignalList::Event event) noexcept
 
void execCmd (UndoCommand *cmd)
 
void updateSignalComboBoxItems () noexcept
 
void getRowItem (int row, int &symbolItemIndex, std::shared_ptr< ComponentSymbolVariantItem > &symbolItem, std::shared_ptr< ComponentPinSignalMapItem > &mapItem) const noexcept
 

Private Attributes

ComponentSymbolVariantmSymbolVariant
 
const ComponentSignalListmSignals
 
std::shared_ptr< const LibraryElementCachemSymbolsCache
 
UndoStackmUndoStack
 
ComboBoxDelegate::Items mSignalComboBoxItems
 
ComboBoxDelegate::Items mDisplayTypeComboBoxItems
 
ComponentSymbolVariantItemList::OnEditedSlot mOnItemsEditedSlot
 
ComponentSignalList::OnEditedSlot mOnSignalsEditedSlot
 

Detailed Description

Member Enumeration Documentation

◆ Column

enum Column
Enumerator
COLUMN_SYMBOL 
COLUMN_PIN 
COLUMN_SIGNAL 
COLUMN_DISPLAY 
_COLUMN_COUNT 

Constructor & Destructor Documentation

◆ ComponentPinSignalMapModel() [1/3]

◆ ComponentPinSignalMapModel() [2/3]

◆ ComponentPinSignalMapModel() [3/3]

ComponentPinSignalMapModel ( QObject *  parent = nullptr)
explicitnoexcept
+ Here is the call graph for this function:

◆ ~ComponentPinSignalMapModel()

Member Function Documentation

◆ setSymbolVariant()

void setSymbolVariant ( ComponentSymbolVariant variant)
noexcept

◆ setSignalList()

void setSignalList ( const ComponentSignalList list)
noexcept

◆ setSymbolsCache()

void setSymbolsCache ( const std::shared_ptr< const LibraryElementCache > &  cache)
noexcept

◆ setUndoStack()

void setUndoStack ( UndoStack stack)
noexcept

◆ autoAssignSignals()

void autoAssignSignals ( )
noexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ rowCount()

int rowCount ( const QModelIndex &  parent = QModelIndex()) const
override
+ Here is the call graph for this function:

◆ columnCount()

int columnCount ( const QModelIndex &  parent = QModelIndex()) const
override

◆ data()

QVariant data ( const QModelIndex &  index,
int  role = Qt::DisplayRole 
) const
override
+ Here is the call graph for this function:

◆ headerData()

QVariant headerData ( int  section,
Qt::Orientation  orientation,
int  role = Qt::DisplayRole 
) const
override

◆ flags()

Qt::ItemFlags flags ( const QModelIndex &  index) const
override

◆ setData()

bool setData ( const QModelIndex &  index,
const QVariant &  value,
int  role = Qt::EditRole 
)
override
+ Here is the call graph for this function:

◆ operator=()

ComponentPinSignalMapModel & operator= ( const ComponentPinSignalMapModel rhs)
noexcept

◆ symbolItemsEdited()

void symbolItemsEdited ( const ComponentSymbolVariantItemList list,
int  index,
const std::shared_ptr< const ComponentSymbolVariantItem > &  item,
ComponentSymbolVariantItemList::Event  event 
)
privatenoexcept

◆ signalListEdited()

void signalListEdited ( const ComponentSignalList list,
int  index,
const std::shared_ptr< const ComponentSignal > &  signal,
ComponentSignalList::Event  event 
)
privatenoexcept

◆ execCmd()

void execCmd ( UndoCommand cmd)
private
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateSignalComboBoxItems()

void updateSignalComboBoxItems ( )
privatenoexcept
+ Here is the call graph for this function:

◆ getRowItem()

void getRowItem ( int  row,
int &  symbolItemIndex,
std::shared_ptr< ComponentSymbolVariantItem > &  symbolItem,
std::shared_ptr< ComponentPinSignalMapItem > &  mapItem 
) const
privatenoexcept
+ Here is the caller graph for this function:

Member Data Documentation

◆ mSymbolVariant

ComponentSymbolVariant* mSymbolVariant
private

◆ mSignals

const ComponentSignalList* mSignals
private

◆ mSymbolsCache

std::shared_ptr<const LibraryElementCache> mSymbolsCache
private

◆ mUndoStack

UndoStack* mUndoStack
private

◆ mSignalComboBoxItems

ComboBoxDelegate::Items mSignalComboBoxItems
private

◆ mDisplayTypeComboBoxItems

ComboBoxDelegate::Items mDisplayTypeComboBoxItems
private

◆ mOnItemsEditedSlot

◆ mOnSignalsEditedSlot

ComponentSignalList::OnEditedSlot mOnSignalsEditedSlot
private

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