◆ SCH_PIN_TABLE_DATA_MODEL()
SCH_PIN_TABLE_DATA_MODEL::SCH_PIN_TABLE_DATA_MODEL |
( |
| ) |
|
|
inline |
◆ ~SCH_PIN_TABLE_DATA_MODEL()
SCH_PIN_TABLE_DATA_MODEL::~SCH_PIN_TABLE_DATA_MODEL |
( |
| ) |
|
|
inline |
◆ BuildAttrs()
void SCH_PIN_TABLE_DATA_MODEL::BuildAttrs |
( |
| ) |
|
|
inline |
Definition at line 90 of file dialog_symbol_properties.cpp.
98 wxGridCellAttr* attr =
nullptr;
102 attr =
new wxGridCellAttr;
103 attr->SetReadOnly(
true );
107 wxArrayString choices;
108 choices.push_back( lib_pin->
GetName() );
110 for(
const std::pair<const wxString, LIB_PIN::ALT>& alt : lib_pin->
GetAlternates() )
111 choices.push_back( alt.first );
113 attr =
new wxGridCellAttr();
wxGridCellAttr * m_shapeAttr
const std::vector< BITMAPS > & PinShapeIcons()
wxGridCellAttr * m_typeAttr
const wxArrayString & PinShapeNames()
const wxString & GetName() const
const wxArrayString & PinTypeNames()
wxGridCellAttr * m_readOnlyAttr
std::map< wxString, ALT > & GetAlternates()
std::vector< wxGridCellAttr * > m_nameAttrs
const std::vector< BITMAPS > & PinTypeIcons()
References LIB_PIN::GetAlternates(), LIB_PIN::GetName(), m_nameAttrs, m_readOnlyAttr, m_shapeAttr, m_typeAttr, pin, PinShapeIcons(), PinShapeNames(), PinTypeIcons(), and PinTypeNames().
Referenced by DIALOG_SYMBOL_PROPERTIES::DIALOG_SYMBOL_PROPERTIES().
◆ compare()
static bool SCH_PIN_TABLE_DATA_MODEL::compare |
( |
const SCH_PIN & |
lhs, |
|
|
const SCH_PIN & |
rhs, |
|
|
int |
sortCol, |
|
|
bool |
ascending |
|
) |
| |
|
inlinestatic |
Definition at line 219 of file dialog_symbol_properties.cpp.
221 wxString lhStr =
GetValue( lhs, sortCol );
222 wxString rhStr =
GetValue( rhs, sortCol );
236 auto cmp = [ ascending ](
const auto a,
const auto b )
253 res = cmp( lhStr.CmpNoCase( rhStr ), 0 );
256 res = cmp(
StrNumCmp( lhStr, rhStr ), 0 );
static int Compare(PinNumber const &lhs, PinNumber const &rhs)
wxString GetValue(int aRow, int aCol) override
int StrNumCmp(const wxString &aString1, const wxString &aString2, bool aIgnoreCase)
Compare two strings with alphanumerical content.
References COL_ALT_NAME, COL_BASE_NAME, COL_NUMBER, COL_SHAPE, COL_TYPE, PinNumbers::Compare(), GetValue(), and StrNumCmp().
Referenced by SortRows().
◆ GetAttr()
wxGridCellAttr* SCH_PIN_TABLE_DATA_MODEL::GetAttr |
( |
int |
aRow, |
|
|
int |
aCol, |
|
|
wxGridCellAttr::wxAttrKind |
|
|
) |
| |
|
inlineoverride |
◆ GetColLabelValue()
wxString SCH_PIN_TABLE_DATA_MODEL::GetColLabelValue |
( |
int |
aCol | ) |
|
|
inlineoverride |
◆ GetNumberCols()
int SCH_PIN_TABLE_DATA_MODEL::GetNumberCols |
( |
| ) |
|
|
inlineoverride |
◆ GetNumberRows()
int SCH_PIN_TABLE_DATA_MODEL::GetNumberRows |
( |
| ) |
|
|
inlineoverride |
◆ GetValue() [1/2]
wxString SCH_PIN_TABLE_DATA_MODEL::GetValue |
( |
int |
aRow, |
|
|
int |
aCol |
|
) |
| |
|
inlineoverride |
◆ GetValue() [2/2]
static wxString SCH_PIN_TABLE_DATA_MODEL::GetValue |
( |
const SCH_PIN & |
aPin, |
|
|
int |
aCol |
|
) |
| |
|
inlinestatic |
Definition at line 155 of file dialog_symbol_properties.cpp.
164 default: wxFAIL;
return wxEmptyString;
LIB_PIN * GetLibPin() const
wxString GetNumber() const
const wxArrayString & PinShapeNames()
const wxString & GetName() const
const wxArrayString & PinTypeNames()
GRAPHIC_PINSHAPE GetShape() const
ELECTRICAL_PINTYPE GetType() const
References COL_ALT_NAME, COL_BASE_NAME, COL_NUMBER, COL_SHAPE, COL_TYPE, SCH_PIN::GetAlt(), SCH_PIN::GetLibPin(), LIB_PIN::GetName(), SCH_PIN::GetNumber(), SCH_PIN::GetShape(), SCH_PIN::GetType(), PinShapeNames(), and PinTypeNames().
◆ IsEmptyCell()
bool SCH_PIN_TABLE_DATA_MODEL::IsEmptyCell |
( |
int |
row, |
|
|
int |
col |
|
) |
| |
|
inlineoverride |
◆ SetValue()
void SCH_PIN_TABLE_DATA_MODEL::SetValue |
( |
int |
aRow, |
|
|
int |
aCol, |
|
|
const wxString & |
aValue |
|
) |
| |
|
inlineoverride |
◆ SortRows()
void SCH_PIN_TABLE_DATA_MODEL::SortRows |
( |
int |
aSortCol, |
|
|
bool |
ascending |
|
) |
| |
|
inline |
Definition at line 263 of file dialog_symbol_properties.cpp.
265 std::sort( begin(), end(),
266 [ aSortCol, ascending ](
const SCH_PIN& lhs,
const SCH_PIN& rhs ) ->
bool 268 return compare( lhs, rhs, aSortCol, ascending );
static bool compare(const SCH_PIN &lhs, const SCH_PIN &rhs, int sortCol, bool ascending)
References compare().
Referenced by DIALOG_SYMBOL_PROPERTIES::DIALOG_SYMBOL_PROPERTIES(), and DIALOG_SYMBOL_PROPERTIES::OnPinTableColSort().
◆ m_nameAttrs
std::vector<wxGridCellAttr*> SCH_PIN_TABLE_DATA_MODEL::m_nameAttrs |
|
protected |
◆ m_readOnlyAttr
wxGridCellAttr* SCH_PIN_TABLE_DATA_MODEL::m_readOnlyAttr |
|
protected |
◆ m_shapeAttr
wxGridCellAttr* SCH_PIN_TABLE_DATA_MODEL::m_shapeAttr |
|
protected |
◆ m_typeAttr
wxGridCellAttr* SCH_PIN_TABLE_DATA_MODEL::m_typeAttr |
|
protected |
The documentation for this class was generated from the following file: