KiCad PCB EDA Suite
GENERAL_COLLECTORS_GUIDE Class Reference

A general implementation of a COLLECTORS_GUIDE. More...

#include <collectors.h>

Inheritance diagram for GENERAL_COLLECTORS_GUIDE:
COLLECTORS_GUIDE

Public Member Functions

 GENERAL_COLLECTORS_GUIDE (LSET aVisibleLayerMask, PCB_LAYER_ID aPreferredLayer)
 Grab stuff from global preferences and uses reasonable defaults. More...
 
bool IsLayerLocked (PCB_LAYER_ID aLayerId) const override
 
void SetLayerLocked (PCB_LAYER_ID aLayerId, bool isLocked)
 
bool IsLayerVisible (PCB_LAYER_ID aLayerId) const override
 
void SetLayerVisible (PCB_LAYER_ID aLayerId, bool isVisible)
 
void SetLayerVisibleBits (LSET aLayerBits)
 
bool IgnoreLockedLayers () const override
 
void SetIgnoreLockedLayers (bool ignore)
 
bool IgnoreNonVisibleLayers () const override
 
void SetIgnoreNonVisibleLayers (bool ignore)
 
PCB_LAYER_ID GetPreferredLayer () const override
 
void SetPreferredLayer (PCB_LAYER_ID aLayer)
 
bool IgnorePreferredLayer () const override
 Provide wildcard behavior regarding the preferred layer. More...
 
void SetIgnorePreferredLayer (bool ignore)
 
bool IgnoreLockedItems () const override
 
void SetIgnoreLockedItems (bool ignore)
 
bool IncludeSecondary () const override
 Determine if the secondary criteria, or 2nd choice items should be included. More...
 
void SetIncludeSecondary (bool include)
 
bool IgnoreMTextsMarkedNoShow () const override
 
void SetIgnoreMTextsMarkedNoShow (bool ignore)
 
bool IgnoreMTextsOnBack () const override
 
void SetIgnoreMTextsOnBack (bool ignore)
 
bool IgnoreMTextsOnFront () const override
 
void SetIgnoreMTextsOnFront (bool ignore)
 
bool IgnoreModulesOnBack () const override
 
void SetIgnoreModulesOnBack (bool ignore)
 
bool IgnoreModulesOnFront () const override
 
void SetIgnoreModulesOnFront (bool ignore)
 
bool IgnorePadsOnBack () const override
 
void SetIgnorePadsOnBack (bool ignore)
 
bool IgnorePadsOnFront () const override
 
void SetIgnorePadsOnFront (bool ignore)
 
bool IgnoreModulesVals () const override
 
void SetIgnoreModulesVals (bool ignore)
 
bool IgnoreModulesRefs () const override
 
void SetIgnoreModulesRefs (bool ignore)
 
bool IgnoreThroughVias () const override
 
void SetIgnoreThroughVias (bool ignore)
 
bool IgnoreBlindBuriedVias () const override
 
void SetIgnoreBlindBuriedVias (bool ignore)
 
bool IgnoreMicroVias () const override
 
void SetIgnoreMicroVias (bool ignore)
 
bool IgnoreTracks () const override
 
void SetIgnoreTracks (bool ignore)
 
virtual bool IgnorePads () const
 

Private Attributes

PCB_LAYER_ID m_PreferredLayer
 
bool m_IgnorePreferredLayer
 
LSET m_LayerLocked
 bit-mapped layer locked bits More...
 
bool m_IgnoreLockedLayers
 
LSET m_LayerVisible
 bit-mapped layer visible bits More...
 
bool m_IgnoreNonVisibleLayers
 
bool m_IgnoreLockedItems
 
bool m_IncludeSecondary
 
bool m_IgnoreMTextsMarkedNoShow
 
bool m_IgnoreMTextsOnBack
 
bool m_IgnoreMTextsOnFront
 
bool m_IgnoreModulesOnBack
 
bool m_IgnoreModulesOnFront
 
bool m_IgnorePadsOnFront
 
bool m_IgnorePadsOnBack
 
bool m_IgnoreModulesVals
 
bool m_IgnoreModulesRefs
 
bool m_IgnoreThroughVias
 
bool m_IgnoreBlindBuriedVias
 
bool m_IgnoreMicroVias
 
bool m_IgnoreTracks
 

Detailed Description

A general implementation of a COLLECTORS_GUIDE.

One of its constructors is entitled to grab information from the program's global preferences.

Definition at line 376 of file collectors.h.

Constructor & Destructor Documentation

GENERAL_COLLECTORS_GUIDE::GENERAL_COLLECTORS_GUIDE ( LSET  aVisibleLayerMask,
PCB_LAYER_ID  aPreferredLayer 
)
inline

Grab stuff from global preferences and uses reasonable defaults.

Add more constructors as needed.

Parameters
aVisibleLayerMask= current visible layers (bit mask)
aPreferredLayer= the layer to search first

Definition at line 418 of file collectors.h.

419  {
420  m_PreferredLayer = aPreferredLayer;
421  m_IgnorePreferredLayer = false;
422  m_LayerVisible = aVisibleLayerMask;
423  m_IgnoreLockedLayers = true;
425  m_IgnoreLockedItems = false;
426 
427 #if defined(USE_MATCH_LAYER)
428  m_IncludeSecondary = false;
429 #else
430  m_IncludeSecondary = true;
431 #endif
432 
433  m_IgnoreMTextsMarkedNoShow = true; // g_ModuleTextNOVColor;
434  m_IgnoreMTextsOnBack = true;
435  m_IgnoreMTextsOnFront = false;
436  m_IgnoreModulesOnBack = true; // !Show_Modules_Cmp;
437  m_IgnoreModulesOnFront = false;
438 
439  m_IgnorePadsOnFront = false;
440  m_IgnorePadsOnBack = false;
441 
442  m_IgnoreModulesVals = false;
443  m_IgnoreModulesRefs = false;
444 
445  m_IgnoreThroughVias = false;
446  m_IgnoreBlindBuriedVias = false;
447  m_IgnoreMicroVias = false;
448  m_IgnoreTracks = false;
449  }
PCB_LAYER_ID m_PreferredLayer
Definition: collectors.h:382
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:388

Member Function Documentation

PCB_LAYER_ID GENERAL_COLLECTORS_GUIDE::GetPreferredLayer ( ) const
inlineoverridevirtual
Returns
int - the preferred layer for HitTest()ing.

Implements COLLECTORS_GUIDE.

Definition at line 492 of file collectors.h.

492 { return m_PreferredLayer; }
PCB_LAYER_ID m_PreferredLayer
Definition: collectors.h:382
bool GENERAL_COLLECTORS_GUIDE::IgnoreBlindBuriedVias ( ) const
inlineoverridevirtual
Returns
true if should ignore blind/buried vias

Implements COLLECTORS_GUIDE.

Definition at line 574 of file collectors.h.

574 { return m_IgnoreBlindBuriedVias; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreLockedItems ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore locked items, else false.

Implements COLLECTORS_GUIDE.

Definition at line 506 of file collectors.h.

506 { return m_IgnoreLockedItems; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreLockedLayers ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore locked layers, else false.

Implements COLLECTORS_GUIDE.

Definition at line 480 of file collectors.h.

480 { return m_IgnoreLockedLayers; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreMicroVias ( ) const
inlineoverridevirtual
Returns
true if should ignore micro vias

Implements COLLECTORS_GUIDE.

Definition at line 577 of file collectors.h.

577 { return m_IgnoreMicroVias; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreModulesOnBack ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore MODULEs on the back side

Implements COLLECTORS_GUIDE.

Definition at line 538 of file collectors.h.

538 { return m_IgnoreModulesOnBack; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreModulesOnFront ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore MODULEs on component layer.

Implements COLLECTORS_GUIDE.

Definition at line 544 of file collectors.h.

544 { return m_IgnoreModulesOnFront; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreModulesRefs ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore modules references.

Implements COLLECTORS_GUIDE.

Definition at line 568 of file collectors.h.

568 { return m_IgnoreModulesRefs; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreModulesVals ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore modules values.

Implements COLLECTORS_GUIDE.

Definition at line 562 of file collectors.h.

562 { return m_IgnoreModulesVals; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreMTextsMarkedNoShow ( ) const
inlineoverridevirtual
Returns
bool - true if MTexts marked as "no show" should be ignored.

Implements COLLECTORS_GUIDE.

Definition at line 520 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::IgnoreMTextsOnBack ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore MTexts on back layers

Implements COLLECTORS_GUIDE.

Definition at line 526 of file collectors.h.

526 { return m_IgnoreMTextsOnBack; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreMTextsOnFront ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore MTexts on front layers

Implements COLLECTORS_GUIDE.

Definition at line 532 of file collectors.h.

532 { return m_IgnoreMTextsOnFront; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreNonVisibleLayers ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore non-visible layers, else false.

Implements COLLECTORS_GUIDE.

Definition at line 486 of file collectors.h.

486 { return m_IgnoreNonVisibleLayers; }
virtual bool COLLECTORS_GUIDE::IgnorePads ( ) const
inlinevirtualinherited
bool GENERAL_COLLECTORS_GUIDE::IgnorePadsOnBack ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore Pads on Back Side.

Implements COLLECTORS_GUIDE.

Definition at line 550 of file collectors.h.

550 { return m_IgnorePadsOnBack; }
bool GENERAL_COLLECTORS_GUIDE::IgnorePadsOnFront ( ) const
inlineoverridevirtual
Returns
bool - true if should ignore PADSs on Front Side.

Implements COLLECTORS_GUIDE.

Definition at line 556 of file collectors.h.

556 { return m_IgnorePadsOnFront; }
bool GENERAL_COLLECTORS_GUIDE::IgnorePreferredLayer ( ) const
inlineoverridevirtual

Provide wildcard behavior regarding the preferred layer.

Returns
bool - true if should ignore preferred layer, else false.

Implements COLLECTORS_GUIDE.

Definition at line 500 of file collectors.h.

500 { return m_IgnorePreferredLayer; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreThroughVias ( ) const
inlineoverridevirtual
Returns
true if should ignore through-hole vias

Implements COLLECTORS_GUIDE.

Definition at line 571 of file collectors.h.

571 { return m_IgnoreThroughVias; }
bool GENERAL_COLLECTORS_GUIDE::IgnoreTracks ( ) const
inlineoverridevirtual
Returns
true if should ignore tracks

Implements COLLECTORS_GUIDE.

Definition at line 580 of file collectors.h.

580 { return m_IgnoreTracks; }
bool GENERAL_COLLECTORS_GUIDE::IncludeSecondary ( ) const
inlineoverridevirtual

Determine if the secondary criteria, or 2nd choice items should be included.

Returns
bool - true if should include, else false.

Implements COLLECTORS_GUIDE.

Definition at line 514 of file collectors.h.

514 { return m_IncludeSecondary; }
bool GENERAL_COLLECTORS_GUIDE::IsLayerLocked ( PCB_LAYER_ID  aLayerId) const
inlineoverridevirtual
Returns
bool - true if the given layer is locked, else false.

Implements COLLECTORS_GUIDE.

Definition at line 454 of file collectors.h.

455  {
456  return m_LayerLocked[aLayerId];
457  }
LSET m_LayerLocked
bit-mapped layer locked bits
Definition: collectors.h:385
bool GENERAL_COLLECTORS_GUIDE::IsLayerVisible ( PCB_LAYER_ID  aLayerId) const
inlineoverridevirtual
Returns
bool - true if the given layer is visible, else false.

Implements COLLECTORS_GUIDE.

Definition at line 467 of file collectors.h.

468  {
469  return m_LayerVisible[aLayerId];
470  }
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:388
void GENERAL_COLLECTORS_GUIDE::SetIgnoreBlindBuriedVias ( bool  ignore)
inline

Definition at line 575 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

575 { m_IgnoreBlindBuriedVias = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreLockedItems ( bool  ignore)
inline

Definition at line 507 of file collectors.h.

507 { m_IgnoreLockedItems = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreLockedLayers ( bool  ignore)
inline

Definition at line 481 of file collectors.h.

481 { m_IgnoreLockedLayers = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreMicroVias ( bool  ignore)
inline

Definition at line 578 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

578 { m_IgnoreMicroVias = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreModulesOnBack ( bool  ignore)
inline

Definition at line 539 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

539 { m_IgnoreModulesOnBack = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreModulesOnFront ( bool  ignore)
inline

Definition at line 545 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

545 { m_IgnoreModulesOnFront = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreModulesRefs ( bool  ignore)
inline
void GENERAL_COLLECTORS_GUIDE::SetIgnoreModulesVals ( bool  ignore)
inline
void GENERAL_COLLECTORS_GUIDE::SetIgnoreMTextsMarkedNoShow ( bool  ignore)
inline
void GENERAL_COLLECTORS_GUIDE::SetIgnoreMTextsOnBack ( bool  ignore)
inline
void GENERAL_COLLECTORS_GUIDE::SetIgnoreMTextsOnFront ( bool  ignore)
inline
void GENERAL_COLLECTORS_GUIDE::SetIgnoreNonVisibleLayers ( bool  ignore)
inline

Definition at line 487 of file collectors.h.

487 { m_IgnoreLockedLayers = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnorePadsOnBack ( bool  ignore)
inline

Definition at line 551 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

551 { m_IgnorePadsOnBack = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnorePadsOnFront ( bool  ignore)
inline

Definition at line 557 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

557 { m_IgnorePadsOnFront = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnorePreferredLayer ( bool  ignore)
inline

Definition at line 501 of file collectors.h.

501 { m_IgnorePreferredLayer = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreThroughVias ( bool  ignore)
inline

Definition at line 572 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

572 { m_IgnoreThroughVias = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIgnoreTracks ( bool  ignore)
inline

Definition at line 581 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

581 { m_IgnoreTracks = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIncludeSecondary ( bool  include)
inline

Definition at line 515 of file collectors.h.

515 { m_IncludeSecondary = include; }
void GENERAL_COLLECTORS_GUIDE::SetLayerLocked ( PCB_LAYER_ID  aLayerId,
bool  isLocked 
)
inline

Definition at line 459 of file collectors.h.

460  {
461  m_LayerLocked.set( aLayerId, isLocked );
462  }
LSET m_LayerLocked
bit-mapped layer locked bits
Definition: collectors.h:385
void GENERAL_COLLECTORS_GUIDE::SetLayerVisible ( PCB_LAYER_ID  aLayerId,
bool  isVisible 
)
inline

Definition at line 471 of file collectors.h.

472  {
473  m_LayerVisible.set( aLayerId, isVisible );
474  }
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:388
void GENERAL_COLLECTORS_GUIDE::SetLayerVisibleBits ( LSET  aLayerBits)
inline

Definition at line 475 of file collectors.h.

475 { m_LayerVisible = aLayerBits; }
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:388
void GENERAL_COLLECTORS_GUIDE::SetPreferredLayer ( PCB_LAYER_ID  aLayer)
inline

Definition at line 493 of file collectors.h.

493 { m_PreferredLayer = aLayer; }
PCB_LAYER_ID m_PreferredLayer
Definition: collectors.h:382

Member Data Documentation

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreBlindBuriedVias
private

Definition at line 404 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreLockedItems
private

Definition at line 391 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreLockedLayers
private

Definition at line 386 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMicroVias
private

Definition at line 405 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesOnBack
private

Definition at line 397 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesOnFront
private

Definition at line 398 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesRefs
private

Definition at line 402 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesVals
private

Definition at line 401 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsMarkedNoShow
private

Definition at line 394 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsOnBack
private

Definition at line 395 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsOnFront
private

Definition at line 396 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreNonVisibleLayers
private

Definition at line 389 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePadsOnBack
private

Definition at line 400 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePadsOnFront
private

Definition at line 399 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePreferredLayer
private

Definition at line 383 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreThroughVias
private

Definition at line 403 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreTracks
private

Definition at line 406 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IncludeSecondary
private

Definition at line 392 of file collectors.h.

LSET GENERAL_COLLECTORS_GUIDE::m_LayerLocked
private

bit-mapped layer locked bits

Definition at line 385 of file collectors.h.

LSET GENERAL_COLLECTORS_GUIDE::m_LayerVisible
private

bit-mapped layer visible bits

Definition at line 388 of file collectors.h.

PCB_LAYER_ID GENERAL_COLLECTORS_GUIDE::m_PreferredLayer
private

Definition at line 382 of file collectors.h.


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