KiCad PCB EDA Suite
|
A set of EDA_ITEMs (i.e., without duplicates). More...
#include <eda_group.h>
Public Member Functions | |
virtual EDA_ITEM * | AsEdaItem ()=0 |
virtual | ~EDA_GROUP ()=default |
wxString | GetName () const |
void | SetName (const wxString &aName) |
std::unordered_set< EDA_ITEM * > & | GetItems () |
const std::unordered_set< EDA_ITEM * > & | GetItems () const |
void | AddItem (EDA_ITEM *aItem) |
Add item to group. | |
void | RemoveItem (EDA_ITEM *aItem) |
Remove item from group. | |
void | RemoveAll () |
KIID_VECT_LIST | GetGroupMemberIds () const |
bool | HasDesignBlockLink () const |
void | SetDesignBlockLibId (const LIB_ID &aLibId) |
const LIB_ID & | GetDesignBlockLibId () const |
Protected Attributes | |
std::unordered_set< EDA_ITEM * > | m_items |
wxString | m_name |
LIB_ID | m_designBlockLibId |
A set of EDA_ITEMs (i.e., without duplicates).
The group parent is always board/sheet, not logical parent group. The group is transparent container - e.g., its position is derived from the position of its members. A selection containing a group implicitly contains its members. However other operations on sets of items, like committing, updating the view, etc the set is explicit.
Definition at line 45 of file eda_group.h.
|
virtualdefault |
void EDA_GROUP::AddItem | ( | EDA_ITEM * | aItem | ) |
Add item to group.
Does not take ownership of item.
Definition at line 27 of file eda_group.cpp.
References EDA_ITEM::GetParentGroup(), m_items, and EDA_ITEM::SetParentGroup().
Referenced by CADSTAR_PCB_ARCHIVE_LOADER::addToGroup(), SCH_GROUP::DeepClone(), PCB_GENERATOR::DeepClone(), PCB_GROUP::DeepClone(), PCB_GROUP::DeepDuplicate(), SCH_GROUP::DeepDuplicate(), PCB_GROUP::Deserialize(), PCB_TUNING_PATTERN::EditPush(), PCB_EDIT_FRAME::ExchangeFootprint(), FOOTPRINT::FOOTPRINT(), CADSTAR_PCB_ARCHIVE_LOADER::loadGroups(), FOOTPRINT::operator=(), SCH_COMMIT::pushSchEdit(), DIALOG_GROUP_PROPERTIES::TransferDataFromWindow(), and BOARD_NETLIST_UPDATER::updateFootprintGroup().
|
pure virtual |
Implemented in SCH_GROUP, and PCB_GROUP.
Referenced by GROUP_TOOL::AddToGroup(), DIALOG_GROUP_PROPERTIES::DIALOG_GROUP_PROPERTIES(), DIALOG_GROUP_PROPERTIES::DoAddMember(), PCB_EDIT_FRAME::ExchangeFootprint(), BOARD_EDITOR_CONTROL::modifyLockSelected(), BOARD_COMMIT::Push(), SCH_COMMIT::pushSchEdit(), PCB_SELECTION_TOOL::Selectable(), DIALOG_GROUP_PROPERTIES::TransferDataFromWindow(), DIALOG_GLOBAL_EDIT_TEXT_AND_GRAPHICS::visitItem(), PCB_GROUP::WithinScope(), and SCH_GROUP::WithinScope().
|
inline |
Definition at line 73 of file eda_group.h.
References m_designBlockLibId.
Referenced by DIALOG_GROUP_PROPERTIES::DIALOG_GROUP_PROPERTIES(), PCB_IO_KICAD_SEXPR::format(), and SCH_IO_KICAD_SEXPR::saveGroup().
KIID_VECT_LIST EDA_GROUP::GetGroupMemberIds | ( | ) | const |
Definition at line 58 of file eda_group.cpp.
References m_items.
|
inline |
Definition at line 54 of file eda_group.h.
References m_items.
Referenced by EDIT_TOOL::DeleteItems(), DIALOG_GROUP_PROPERTIES::DIALOG_GROUP_PROPERTIES(), PCB_SELECTION_TOOL::EnterGroup(), FOOTPRINT::FOOTPRINT(), PCB_IO_KICAD_SEXPR::format(), PCB_TUNING_PATTERN::GetMsgPanelInfo(), BOARD_INSPECTION_TOOL::InspectClearance(), FOOTPRINT::operator=(), DRAWING_TOOL::PlaceTuningPattern(), SCH_IO_KICAD_SEXPR::saveGroup(), PCB_GROUP::Serialize(), and testGroupEqual().
|
inline |
Definition at line 55 of file eda_group.h.
References m_items.
|
inline |
Definition at line 51 of file eda_group.h.
References m_name.
Referenced by createBoard(), DIALOG_GROUP_PROPERTIES::DIALOG_GROUP_PROPERTIES(), KIGFX::PCB_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), PCB_IO_KICAD_SEXPR::format(), SCH_GROUP::Matches(), PCB_GROUP::Matches(), PCB_GROUP_DESC::PCB_GROUP_DESC(), SCH_IO_KICAD_SEXPR::saveGroup(), SCH_GROUP_DESC::SCH_GROUP_DESC(), PCB_GROUP::Serialize(), testGroupEqual(), and BOARD_NETLIST_UPDATER::updateFootprintGroup().
|
inline |
Definition at line 70 of file eda_group.h.
References LIB_ID::IsValid(), and m_designBlockLibId.
Referenced by PCB_IO_KICAD_SEXPR::format(), and SCH_IO_KICAD_SEXPR::saveGroup().
void EDA_GROUP::RemoveAll | ( | ) |
Definition at line 49 of file eda_group.cpp.
References m_items.
Referenced by DIALOG_GROUP_PROPERTIES::TransferDataFromWindow().
void EDA_GROUP::RemoveItem | ( | EDA_ITEM * | aItem | ) |
Remove item from group.
Definition at line 40 of file eda_group.cpp.
References m_items, and EDA_ITEM::SetParentGroup().
Referenced by PCB_EDIT_FRAME::ExchangeFootprint(), BOARD_COMMIT::Push(), and BOARD_NETLIST_UPDATER::updateFootprintGroup().
|
inline |
Definition at line 72 of file eda_group.h.
References m_designBlockLibId.
Referenced by DIALOG_GROUP_PROPERTIES::TransferDataFromWindow().
|
inline |
Definition at line 52 of file eda_group.h.
References m_name.
Referenced by createBoard(), CADSTAR_PCB_ARCHIVE_LOADER::createUniqueGroupID(), PCB_GROUP::Deserialize(), CADSTAR_PCB_ARCHIVE_LOADER::loadGroups(), PCB_GROUP_DESC::PCB_GROUP_DESC(), SCH_GROUP_DESC::SCH_GROUP_DESC(), DIALOG_GROUP_PROPERTIES::TransferDataFromWindow(), and BOARD_NETLIST_UPDATER::updateFootprintGroup().
|
protected |
Definition at line 78 of file eda_group.h.
Referenced by GetDesignBlockLibId(), HasDesignBlockLink(), SetDesignBlockLibId(), and SCH_GROUP::swapData().
|
protected |
Definition at line 76 of file eda_group.h.
Referenced by AddItem(), SCH_GROUP::DeepClone(), PCB_GENERATOR::DeepClone(), PCB_GROUP::DeepClone(), PCB_GROUP::DeepDuplicate(), SCH_GROUP::DeepDuplicate(), PCB_GROUP::Flip(), PCB_GROUP::GetBoardItems(), SCH_GROUP::GetBoundingBox(), PCB_GROUP::GetBoundingBox(), GetGroupMemberIds(), SCH_GROUP::GetItemDescription(), PCB_GROUP::GetItemDescription(), GetItems(), PCB_GROUP::GetLayerSet(), SCH_GROUP::GetMsgPanelInfo(), PCB_GROUP::GetMsgPanelInfo(), SCH_GROUP::GetSchItems(), PCB_GROUP::IsOnLayer(), PCB_GROUP::Mirror(), SCH_GROUP::MirrorHorizontally(), SCH_GROUP::MirrorVertically(), SCH_GROUP::Move(), PCB_GROUP::Move(), PCB_GROUP::operator==(), SCH_GROUP::operator==(), RemoveAll(), RemoveItem(), SCH_GROUP::Rotate(), PCB_GROUP::Rotate(), SCH_GROUP::RunOnChildren(), PCB_TUNING_PATTERN::ShowPropertiesDialog(), PCB_GROUP::Similarity(), SCH_GROUP::Similarity(), and SCH_GROUP::swapData().
|
protected |
Definition at line 77 of file eda_group.h.
Referenced by SCH_GROUP::GetItemDescription(), PCB_GROUP::GetItemDescription(), SCH_GROUP::GetMsgPanelInfo(), PCB_GROUP::GetMsgPanelInfo(), GetName(), PCB_TUNING_PATTERN::PCB_TUNING_PATTERN(), SetName(), and SCH_GROUP::swapData().