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

The ComponentSymbolVariantItemListEditorWidget class. More...

#include <componentsymbolvariantitemlisteditorwidget.h>

Inherits QWidget.

+ Collaboration diagram for ComponentSymbolVariantItemListEditorWidget:

Signals

void edited ()
 

Public Member Functions

 ComponentSymbolVariantItemListEditorWidget (QWidget *parent=nullptr) noexcept
 
 ComponentSymbolVariantItemListEditorWidget (const ComponentSymbolVariantItemListEditorWidget &other)=delete
 
 ~ComponentSymbolVariantItemListEditorWidget () noexcept
 
void setVariant (const workspace::Workspace &ws, const IF_GraphicsLayerProvider &layerProvider, ComponentSymbolVariantItemList &items) noexcept
 
ComponentSymbolVariantItemListEditorWidgetoperator= (const ComponentSymbolVariantItemListEditorWidget &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 isRequiredChanged (bool checked) noexcept
 
void btnChooseSymbolClicked () noexcept
 
void btnAddRemoveClicked () noexcept
 
void btnUpClicked () noexcept
 
void btnDownClicked () noexcept
 
void updateTable (tl::optional< Uuid > selected=tl::nullopt) noexcept
 
void setTableRowContent (int row, int number, const tl::optional< Uuid > &uuid, const tl::optional< Uuid > &symbol, const QString &suffix, bool required, const Point &pos, const Angle &rot) noexcept
 
void addItem (const Uuid &symbol, const QString &suffix, bool required, const Point &pos, const Angle &rot) noexcept
 
void removeItem (const Uuid &uuid) noexcept
 
void moveItemUp (int index) noexcept
 
void moveItemDown (int index) noexcept
 
void setSymbolUuid (const Uuid &uuid, const Uuid &symbol) noexcept
 
void setIsRequired (const Uuid &uuid, bool required) noexcept
 
void setSuffix (const Uuid &uuid, const QString &suffix) noexcept
 
void setPosX (const Uuid &uuid, const Length &x) noexcept
 
void setPosY (const Uuid &uuid, const Length &y) noexcept
 
void setRotation (const Uuid &uuid, const Angle &rot) noexcept
 
int getRowOfTableCellWidget (QObject *obj) const noexcept
 
tl::optional< UuidgetUuidOfRow (int row) const noexcept
 
int newItemRow () const noexcept
 
int indexToRow (int index) const noexcept
 
int rowToIndex (int row) const noexcept
 
bool isExistingItemRow (int row) const noexcept
 
bool isNewItemRow (int row) const noexcept
 

Private Attributes

QTableWidget * mTable
 
const workspace::WorkspacemWorkspace
 
const IF_GraphicsLayerProvidermLayerProvider
 
ComponentSymbolVariantItemListmItems
 
tl::optional< UuidmSelectedItem
 
QLabel * mNewSymbolLabel
 
CenteredCheckBoxmNewRequiredCheckbox
 

Detailed Description

The ComponentSymbolVariantItemListEditorWidget class.

Author
ubruhin
Date
2017-03-19

Member Enumeration Documentation

enum Column
private
Enumerator
COLUMN_NUMBER 
COLUMN_SYMBOL 
COLUMN_SUFFIX 
COLUMN_ISREQUIRED 
COLUMN_POS_X 
COLUMN_POS_Y 
COLUMN_ROTATION 
COLUMN_BUTTONS 
_COLUMN_COUNT 

Constructor & Destructor Documentation

ComponentSymbolVariantItemListEditorWidget ( QWidget *  parent = nullptr)
explicitnoexcept

+ Here is the call graph for this function:

Member Function Documentation

void setVariant ( const workspace::Workspace ws,
const IF_GraphicsLayerProvider layerProvider,
ComponentSymbolVariantItemList items 
)
noexcept
void edited ( )
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 isRequiredChanged ( bool  checked)
privatenoexcept

+ Here is the caller graph for this function:

void btnChooseSymbolClicked ( )
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 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 updateTable ( tl::optional< Uuid selected = tl::nullopt)
privatenoexcept

+ Here is the call graph for this function:

void setTableRowContent ( int  row,
int  number,
const tl::optional< Uuid > &  uuid,
const tl::optional< Uuid > &  symbol,
const QString &  suffix,
bool  required,
const Point pos,
const Angle rot 
)
privatenoexcept

+ Here is the call graph for this function:

void addItem ( const Uuid symbol,
const QString &  suffix,
bool  required,
const Point pos,
const Angle rot 
)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void removeItem ( const Uuid uuid)
privatenoexcept

+ Here is the caller graph for this function:

void moveItemUp ( int  index)
privatenoexcept

+ Here is the caller graph for this function:

void moveItemDown ( int  index)
privatenoexcept

+ Here is the caller graph for this function:

void setSymbolUuid ( const Uuid uuid,
const Uuid symbol 
)
privatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void setIsRequired ( const Uuid uuid,
bool  required 
)
privatenoexcept
void setSuffix ( const Uuid uuid,
const QString &  suffix 
)
privatenoexcept

+ Here is the call graph for this function:

void setPosX ( const Uuid uuid,
const Length x 
)
privatenoexcept

+ Here is the call graph for this function:

void setPosY ( const Uuid uuid,
const Length y 
)
privatenoexcept

+ Here is the call graph for this function:

void setRotation ( const Uuid uuid,
const Angle rot 
)
privatenoexcept
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:

int newItemRow ( ) 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 isExistingItemRow ( int  row) const
inlineprivatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool isNewItemRow ( int  row) const
inlineprivatenoexcept

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

QTableWidget* mTable
private
const workspace::Workspace* mWorkspace
private
const IF_GraphicsLayerProvider* mLayerProvider
private
tl::optional<Uuid> mSelectedItem
private
QLabel* mNewSymbolLabel
private
CenteredCheckBox* mNewRequiredCheckbox
private

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