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)
 
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
 

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 366 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 407 of file collectors.h.

408  {
409  m_PreferredLayer = aPreferredLayer;
410  m_IgnorePreferredLayer = false;
411  m_LayerVisible = aVisibleLayerMask;
412  m_IgnoreLockedLayers = true;
414  m_IgnoreLockedItems = false;
415 
416 #if defined(USE_MATCH_LAYER)
417  m_IncludeSecondary = false;
418 #else
419  m_IncludeSecondary = true;
420 #endif
421 
422  m_IgnoreMTextsMarkedNoShow = true; // g_ModuleTextNOVColor;
423  m_IgnoreMTextsOnBack = true;
424  m_IgnoreMTextsOnFront = false;
425  m_IgnoreModulesOnBack = true; // !Show_Modules_Cmp;
426  m_IgnoreModulesOnFront = false;
427 
428  m_IgnorePadsOnFront = false;
429  m_IgnorePadsOnBack = false;
430 
431  m_IgnoreModulesVals = false;
432  m_IgnoreModulesRefs = false;
433 
434  m_IgnoreThroughVias = false;
435  m_IgnoreBlindBuriedVias = false;
436  m_IgnoreMicroVias = false;
437  }
PCB_LAYER_ID m_PreferredLayer
Definition: collectors.h:372
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:378

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 480 of file collectors.h.

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

Implements COLLECTORS_GUIDE.

Definition at line 562 of file collectors.h.

562 { 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 494 of file collectors.h.

494 { 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 468 of file collectors.h.

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

Implements COLLECTORS_GUIDE.

Definition at line 565 of file collectors.h.

565 { 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 526 of file collectors.h.

526 { 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 532 of file collectors.h.

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

Implements COLLECTORS_GUIDE.

Definition at line 556 of file collectors.h.

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

Implements COLLECTORS_GUIDE.

Definition at line 550 of file collectors.h.

550 { 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 508 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 514 of file collectors.h.

514 { 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 520 of file collectors.h.

520 { 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 474 of file collectors.h.

474 { 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 538 of file collectors.h.

538 { 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 544 of file collectors.h.

544 { 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 488 of file collectors.h.

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

Implements COLLECTORS_GUIDE.

Definition at line 559 of file collectors.h.

559 { return m_IgnoreThroughVias; }
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 502 of file collectors.h.

502 { 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 442 of file collectors.h.

443  {
444  return m_LayerLocked[aLayerId];
445  }
LSET m_LayerLocked
bit-mapped layer locked bits
Definition: collectors.h:375
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 455 of file collectors.h.

456  {
457  return m_LayerVisible[aLayerId];
458  }
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:378
void GENERAL_COLLECTORS_GUIDE::SetIgnoreBlindBuriedVias ( bool  ignore)
inline

Definition at line 563 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

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

Definition at line 495 of file collectors.h.

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

Definition at line 469 of file collectors.h.

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

Definition at line 566 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

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

Definition at line 527 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

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

Definition at line 533 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

533 { 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 475 of file collectors.h.

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

Definition at line 539 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

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

Definition at line 545 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

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

Definition at line 489 of file collectors.h.

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

Definition at line 560 of file collectors.h.

Referenced by SELECTION_TOOL::getCollectorsGuide().

560 { m_IgnoreThroughVias = ignore; }
void GENERAL_COLLECTORS_GUIDE::SetIncludeSecondary ( bool  include)
inline

Definition at line 503 of file collectors.h.

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

Definition at line 447 of file collectors.h.

448  {
449  m_LayerLocked.set( aLayerId, isLocked );
450  }
LSET m_LayerLocked
bit-mapped layer locked bits
Definition: collectors.h:375
void GENERAL_COLLECTORS_GUIDE::SetLayerVisible ( PCB_LAYER_ID  aLayerId,
bool  isVisible 
)
inline

Definition at line 459 of file collectors.h.

460  {
461  m_LayerVisible.set( aLayerId, isVisible );
462  }
LSET m_LayerVisible
bit-mapped layer visible bits
Definition: collectors.h:378
void GENERAL_COLLECTORS_GUIDE::SetLayerVisibleBits ( LSET  aLayerBits)
inline

Definition at line 463 of file collectors.h.

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

Definition at line 481 of file collectors.h.

481 { m_PreferredLayer = aLayer; }
PCB_LAYER_ID m_PreferredLayer
Definition: collectors.h:372

Member Data Documentation

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreBlindBuriedVias
private

Definition at line 394 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreLockedItems
private

Definition at line 381 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreLockedLayers
private

Definition at line 376 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMicroVias
private

Definition at line 395 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesOnBack
private

Definition at line 387 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesOnFront
private

Definition at line 388 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesRefs
private

Definition at line 392 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreModulesVals
private

Definition at line 391 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsMarkedNoShow
private

Definition at line 384 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsOnBack
private

Definition at line 385 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreMTextsOnFront
private

Definition at line 386 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreNonVisibleLayers
private

Definition at line 379 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePadsOnBack
private

Definition at line 390 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePadsOnFront
private

Definition at line 389 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnorePreferredLayer
private

Definition at line 373 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IgnoreThroughVias
private

Definition at line 393 of file collectors.h.

bool GENERAL_COLLECTORS_GUIDE::m_IncludeSecondary
private

Definition at line 382 of file collectors.h.

LSET GENERAL_COLLECTORS_GUIDE::m_LayerLocked
private

bit-mapped layer locked bits

Definition at line 375 of file collectors.h.

LSET GENERAL_COLLECTORS_GUIDE::m_LayerVisible
private

bit-mapped layer visible bits

Definition at line 378 of file collectors.h.

PCB_LAYER_ID GENERAL_COLLECTORS_GUIDE::m_PreferredLayer
private

Definition at line 372 of file collectors.h.


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