KiCad PCB EDA Suite
SCH_EAGLE_PLUGIN::SEG_DESC Struct Reference

Wires and labels of a single connection (segment in Eagle nomenclature)

More...

Public Member Functions

const SEGLabelAttached (const SCH_TEXT *aLabel) const
 

Tests if a particular label is attached to any of the stored segments

More...
 

Public Attributes

std::vector< SCH_TEXT * > labels
 
std::vector< SEGsegs
 

Detailed Description

Wires and labels of a single connection (segment in Eagle nomenclature)

Definition at line 207 of file sch_eagle_plugin.h.

Member Function Documentation

◆ LabelAttached()

const SEG * SCH_EAGLE_PLUGIN::SEG_DESC::LabelAttached ( const SCH_TEXT aLabel) const

Tests if a particular label is attached to any of the stored segments

Definition at line 2502 of file sch_eagle_plugin.cpp.

2503 {
2504  VECTOR2I labelPos( aLabel->GetPosition() );
2505 
2506  for( const auto& seg : segs )
2507  {
2508  if( seg.Contains( labelPos ) )
2509  return &seg;
2510  }
2511 
2512  return nullptr;
2513 }
wxPoint GetPosition() const override
Definition: sch_text.h:313

References SCH_TEXT::GetPosition().

Member Data Documentation

◆ labels

std::vector<SCH_TEXT*> SCH_EAGLE_PLUGIN::SEG_DESC::labels

Definition at line 211 of file sch_eagle_plugin.h.

Referenced by SCH_EAGLE_PLUGIN::loadSegments().

◆ segs

std::vector<SEG> SCH_EAGLE_PLUGIN::SEG_DESC::segs

Definition at line 212 of file sch_eagle_plugin.h.

Referenced by SCH_EAGLE_PLUGIN::loadSegments().


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