KiCad PCB EDA Suite
Loading...
Searching...
No Matches
ee_tool_utils.h File Reference
#include <optional>
#include <set>
#include <sch_item.h>
#include <tool/selection.h>

Go to the source code of this file.

Functions

wxString GetSchItemAsText (const SCH_ITEM &aItem)
 
wxString GetSelectedItemsAsText (const SELECTION &aSel)
 
std::set< int > GetUnplacedUnitsForSymbol (const SCH_SYMBOL &aSym)
 Get a list of unplaced (i.e.
 
std::optional< SCH_REFERENCEFindSymbolByRefAndUnit (const SCHEMATIC &aSheet, const wxString &aRef, int aUnit)
 Find a symbol by reference and unit.
 

Function Documentation

◆ FindSymbolByRefAndUnit()

std::optional< SCH_REFERENCE > FindSymbolByRefAndUnit ( const SCHEMATIC aSheet,
const wxString &  aRef,
int  aUnit 
)

Find a symbol by reference and unit.

Returns
A SCH_REFERENCE to the found symbol, or std::nullopt if not found.

Definition at line 163 of file ee_tool_utils.cpp.

References SCH_SHEET_LIST::GetSymbols(), and SCHEMATIC::Hierarchy().

Referenced by SCH_EDIT_FRAME::SelectUnit().

◆ GetSchItemAsText()

◆ GetSelectedItemsAsText()

wxString GetSelectedItemsAsText ( const SELECTION aSel)

◆ GetUnplacedUnitsForSymbol()

std::set< int > GetUnplacedUnitsForSymbol ( const SCH_SYMBOL aSym)

Get a list of unplaced (i.e.

not in schamtic) unit numbers for a symbol.

Definition at line 131 of file ee_tool_utils.cpp.

References SCHEMATIC::CurrentSheet(), SCH_SYMBOL::GetRef(), SCH_SHEET_LIST::GetSymbols(), SCH_SYMBOL::GetUnitCount(), SCHEMATIC::Hierarchy(), and SCH_ITEM::Schematic().

Referenced by SCH_DRAWING_TOOLS::PlaceNextSymbolUnit(), and SYMBOL_UNIT_MENU::update().