LibrePCB Developers Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FootprintListEditorWidget Class Referencefinal

The FootprintListEditorWidget class. More...

#include <footprintlisteditorwidget.h>

Inherits QWidget, and IF_Observer.

+ Collaboration diagram for FootprintListEditorWidget:

Signals

void currentFootprintChanged (int index)
 

Public Member Functions

 FootprintListEditorWidget (QWidget *parent=nullptr) noexcept
 
 FootprintListEditorWidget (const FootprintListEditorWidget &other)=delete
 
 ~FootprintListEditorWidget () noexcept
 
void setReferences (FootprintList &list, UndoStack &stack) noexcept
 
void addDefaultFootprint ()
 
FootprintListEditorWidgetoperator= (const FootprintListEditorWidget &rhs)=delete
 

Private Types

enum  Column
 

Private Member Functions

void currentCellChanged (int currentRow, int currentColumn, int previousRow, int previousColumn) noexcept
 
void tableCellChanged (int row, int column) noexcept
 
void btnUpClicked () noexcept
 
void btnDownClicked () noexcept
 
void btnCopyClicked () noexcept
 
void btnAddRemoveClicked () noexcept
 
void updateTable (tl::optional< Uuid > selected=tl::nullopt) noexcept
 
void setTableRowContent (int row, const tl::optional< Uuid > &uuid, const QString &name) noexcept
 
void addFootprint (const QString &name) noexcept
 
void removeFootprint (const Uuid &uuid) noexcept
 
void moveFootprintUp (int index) noexcept
 
void moveFootprintDown (int index) noexcept
 
void copyFootprint (const Uuid &uuid) noexcept
 
ElementName setName (const Uuid &uuid, const QString &name) noexcept
 
int getRowOfTableCellWidget (QObject *obj) const noexcept
 
tl::optional< UuidgetUuidOfRow (int row) const noexcept
 
ElementName validateNameOrThrow (const QString &name) const
 
int newFootprintRow () const noexcept
 
int indexToRow (int index) const noexcept
 
int rowToIndex (int row) const noexcept
 
bool isExistingFootprintRow (int row) const noexcept
 
bool isNewFootprintRow (int row) const noexcept
 
void listObjectAdded (const FootprintList &list, int newIndex, const std::shared_ptr< Footprint > &ptr) noexceptoverride
 
void listObjectRemoved (const FootprintList &list, int oldIndex, const std::shared_ptr< Footprint > &ptr) noexceptoverride
 

Private Attributes

QTableWidget * mTable
 
FootprintListmFootprintList
 
UndoStackmUndoStack
 
tl::optional< UuidmSelectedFootprint
 

Detailed Description

The FootprintListEditorWidget class.

Author
ubruhin
Date
2017-05-27

Member Enumeration Documentation

enum Column
private
Enumerator
COLUMN_NAME 
COLUMN_BUTTONS 
_COLUMN_COUNT 

Constructor & Destructor Documentation

FootprintListEditorWidget ( QWidget *  parent = nullptr)
explicitnoexcept

+ Here is the call graph for this function:

+ Here is the call graph for this function:

Member Function Documentation

void setReferences ( FootprintList list,
UndoStack stack 
)
noexcept
void addDefaultFootprint ( )

+ Here is the call graph for this function:

FootprintListEditorWidget& operator= ( const FootprintListEditorWidget rhs)
delete
void currentFootprintChanged ( int  index)
signal

+ Here is the caller graph for this function:

void currentCellChanged ( int  currentRow,
int  currentColumn,
int  previousRow,
int  previousColumn 
)
privatenoexcept

+ Here is the caller graph for this function:

void tableCellChanged ( int  row,
int  column 
)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void btnUpClicked ( )
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void btnDownClicked ( )
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void btnCopyClicked ( )
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void btnAddRemoveClicked ( )
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void updateTable ( tl::optional< Uuid selected = tl::nullopt)
privatenoexcept

+ Here is the call graph for this function:

void setTableRowContent ( int  row,
const tl::optional< Uuid > &  uuid,
const QString &  name 
)
privatenoexcept

+ Here is the call graph for this function:

void addFootprint ( const QString &  name)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void removeFootprint ( const Uuid uuid)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void moveFootprintUp ( int  index)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void moveFootprintDown ( int  index)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void copyFootprint ( const Uuid uuid)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

ElementName setName ( const Uuid uuid,
const QString &  name 
)
privatenoexcept

+ Here is the call graph for this function:

int getRowOfTableCellWidget ( QObject *  obj) const
privatenoexcept

+ Here is the caller graph for this function:

tl::optional< Uuid > getUuidOfRow ( int  row) const
privatenoexcept

+ Here is the caller graph for this function:

ElementName validateNameOrThrow ( const QString &  name) const
private
int newFootprintRow ( ) const
inlineprivatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int indexToRow ( int  index) const
inlineprivatenoexcept
int rowToIndex ( int  row) const
inlineprivatenoexcept

+ Here is the caller graph for this function:

bool isExistingFootprintRow ( int  row) const
inlineprivatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool isNewFootprintRow ( int  row) const
inlineprivatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void listObjectAdded ( const FootprintList list,
int  newIndex,
const std::shared_ptr< Footprint > &  ptr 
)
overrideprivatenoexcept
void listObjectRemoved ( const FootprintList list,
int  oldIndex,
const std::shared_ptr< Footprint > &  ptr 
)
overrideprivatenoexcept

Member Data Documentation

QTableWidget* mTable
private
FootprintList* mFootprintList
private
UndoStack* mUndoStack
private
tl::optional<Uuid> mSelectedFootprint
private

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