KiCad PCB EDA Suite
Loading...
Searching...
No Matches
ZONE_SETTINGS Class Reference

ZONE_SETTINGS handles zones parameters. More...

#include <zone_settings.h>

Public Types

enum  {
  SMOOTHING_UNDEFINED = -1 , SMOOTHING_NONE = 0 , SMOOTHING_CHAMFER , SMOOTHING_FILLET ,
  SMOOTHING_LAST
}
 

Public Member Functions

 ZONE_SETTINGS ()
 
bool operator== (const ZONE_SETTINGS &aOther) const
 
bool operator!= (const ZONE_SETTINGS &aOther) const
 
ZONE_SETTINGSoperator<< (const ZONE &aSource)
 operator << ( const ZONE& ) was Function ImportSetting copies settings from a given zone into this object. More...
 
void SetupLayersList (wxDataViewListCtrl *aList, PCB_BASE_FRAME *aFrame, LSET aLayers, bool aFpEditorMode)
 A helper routine for the various zone dialogs (copper, non-copper, keepout). More...
 
void ExportSetting (ZONE &aTarget, bool aFullExport=true) const
 Function ExportSetting copy settings to a given zone. More...
 
void SetCornerSmoothingType (int aType)
 
int GetCornerSmoothingType () const
 
void SetCornerRadius (int aRadius)
 
unsigned int GetCornerRadius () const
 
ZONE_CONNECTION GetPadConnection () const
 
void SetPadConnection (ZONE_CONNECTION aPadConnection)
 
bool GetIsRuleArea () const
 Accessors to parameters used in Rule Area zones: More...
 
bool GetDoNotAllowCopperPour () const
 
bool GetDoNotAllowVias () const
 
bool GetDoNotAllowTracks () const
 
bool GetDoNotAllowPads () const
 
bool GetDoNotAllowFootprints () const
 
void SetIsRuleArea (bool aEnable)
 
void SetDoNotAllowCopperPour (bool aEnable)
 
void SetDoNotAllowVias (bool aEnable)
 
void SetDoNotAllowTracks (bool aEnable)
 
void SetDoNotAllowPads (bool aEnable)
 
void SetDoNotAllowFootprints (bool aEnable)
 
ISLAND_REMOVAL_MODE GetIslandRemovalMode () const
 
void SetIslandRemovalMode (ISLAND_REMOVAL_MODE aRemove)
 
long long int GetMinIslandArea () const
 
void SetMinIslandArea (long long int aArea)
 

Static Public Member Functions

static const ZONE_SETTINGSGetDefaultSettings ()
 

Public Attributes

unsigned m_ZonePriority
 
ZONE_FILL_MODE m_FillMode
 
int m_ZoneClearance
 
int m_ZoneMinThickness
 
int m_HatchThickness
 
int m_HatchGap
 
EDA_ANGLE m_HatchOrientation
 
int m_HatchSmoothingLevel
 
double m_HatchSmoothingValue
 
double m_HatchHoleMinArea
 
int m_HatchBorderAlgorithm
 
int m_NetcodeSelection
 
wxString m_Name
 
LSET m_Layers
 
ZONE_BORDER_DISPLAY_STYLE m_ZoneBorderDisplayStyle
 Option to show the zone area (outlines only, short hatches or full hatches. More...
 
int m_BorderHatchPitch
 
long m_ThermalReliefGap
 
long m_ThermalReliefSpokeWidth
 
bool m_Locked
 
TEARDROP_TYPE m_TeardropType
 

Private Attributes

int m_cornerSmoothingType
 
unsigned int m_cornerRadius
 
ZONE_CONNECTION m_padConnection
 
bool m_isRuleArea
 
bool m_keepoutDoNotAllowCopperPour
 
bool m_keepoutDoNotAllowVias
 
bool m_keepoutDoNotAllowTracks
 
bool m_keepoutDoNotAllowPads
 
bool m_keepoutDoNotAllowFootprints
 
ISLAND_REMOVAL_MODE m_removeIslands
 
long long int m_minIslandArea
 

Detailed Description

ZONE_SETTINGS handles zones parameters.

Because a zone can be on copper or non copper layers, and can be also a keepout area, some parameters are irrelevant depending on the type of zone

Definition at line 70 of file zone_settings.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
SMOOTHING_UNDEFINED 
SMOOTHING_NONE 
SMOOTHING_CHAMFER 
SMOOTHING_FILLET 
SMOOTHING_LAST 

Definition at line 74 of file zone_settings.h.

Constructor & Destructor Documentation

◆ ZONE_SETTINGS()

Member Function Documentation

◆ ExportSetting()

void ZONE_SETTINGS::ExportSetting ( ZONE aTarget,
bool  aFullExport = true 
) const

Function ExportSetting copy settings to a given zone.

Parameters
aTargetthe given zone
aFullExportif false: some parameters are NOT exported because they must not be exported when export settings from a zone to others zones Currently: m_NetcodeSelection

Definition at line 174 of file zone_settings.cpp.

References GetDoNotAllowCopperPour(), GetDoNotAllowFootprints(), GetDoNotAllowPads(), GetDoNotAllowTracks(), GetDoNotAllowVias(), GetIslandRemovalMode(), GetIsRuleArea(), GetMinIslandArea(), m_BorderHatchPitch, m_cornerRadius, m_cornerSmoothingType, m_FillMode, m_HatchBorderAlgorithm, m_HatchGap, m_HatchHoleMinArea, m_HatchOrientation, m_HatchSmoothingLevel, m_HatchSmoothingValue, m_HatchThickness, m_isRuleArea, m_Layers, m_Locked, m_Name, m_NetcodeSelection, m_padConnection, m_TeardropType, m_ThermalReliefGap, m_ThermalReliefSpokeWidth, m_ZoneBorderDisplayStyle, m_ZoneClearance, m_ZoneMinThickness, m_ZonePriority, ZONE::SetAssignedPriority(), ZONE::SetBorderDisplayStyle(), ZONE::SetCornerRadius(), ZONE::SetCornerSmoothingType(), ZONE::SetDoNotAllowCopperPour(), ZONE::SetDoNotAllowFootprints(), ZONE::SetDoNotAllowPads(), ZONE::SetDoNotAllowTracks(), ZONE::SetDoNotAllowVias(), ZONE::SetFillMode(), ZONE::SetHatchBorderAlgorithm(), ZONE::SetHatchGap(), ZONE::SetHatchHoleMinArea(), ZONE::SetHatchOrientation(), ZONE::SetHatchSmoothingLevel(), ZONE::SetHatchSmoothingValue(), ZONE::SetHatchThickness(), ZONE::SetIslandRemovalMode(), ZONE::SetIsRuleArea(), ZONE::SetLayerSet(), ZONE::SetLocalClearance(), BOARD_ITEM::SetLocked(), ZONE::SetMinIslandArea(), ZONE::SetMinThickness(), BOARD_CONNECTED_ITEM::SetNetCode(), ZONE::SetPadConnection(), ZONE::SetTeardropAreaType(), ZONE::SetThermalReliefGap(), ZONE::SetThermalReliefSpokeWidth(), and ZONE::SetZoneName().

Referenced by ZONE_CREATE_HELPER::createNewZone(), CONVERT_TOOL::CreatePolys(), TEARDROP_MANAGER::createTeardrop(), ZONE_CREATE_HELPER::createZoneFromExisting(), PCB_EDIT_FRAME::Edit_Zone_Params(), FOOTPRINT_EDIT_FRAME::OnEditItemRequest(), ZONE::ZONE(), and BOARD_EDITOR_CONTROL::ZoneDuplicate().

◆ GetCornerRadius()

unsigned int ZONE_SETTINGS::GetCornerRadius ( ) const
inline

◆ GetCornerSmoothingType()

◆ GetDefaultSettings()

const ZONE_SETTINGS & ZONE_SETTINGS::GetDefaultSettings ( )
static
Returns
Default ZONE_SETTINGS

Definition at line 242 of file zone_settings.cpp.

Referenced by TEARDROP_MANAGER::createTeardrop().

◆ GetDoNotAllowCopperPour()

bool ZONE_SETTINGS::GetDoNotAllowCopperPour ( ) const
inline

◆ GetDoNotAllowFootprints()

bool ZONE_SETTINGS::GetDoNotAllowFootprints ( ) const
inline

◆ GetDoNotAllowPads()

bool ZONE_SETTINGS::GetDoNotAllowPads ( ) const
inline

◆ GetDoNotAllowTracks()

bool ZONE_SETTINGS::GetDoNotAllowTracks ( ) const
inline

◆ GetDoNotAllowVias()

bool ZONE_SETTINGS::GetDoNotAllowVias ( ) const
inline

◆ GetIslandRemovalMode()

ISLAND_REMOVAL_MODE ZONE_SETTINGS::GetIslandRemovalMode ( ) const
inline

◆ GetIsRuleArea()

bool ZONE_SETTINGS::GetIsRuleArea ( ) const
inline

Accessors to parameters used in Rule Area zones:

Definition at line 188 of file zone_settings.h.

References m_isRuleArea.

Referenced by ExportSetting().

◆ GetMinIslandArea()

long long int ZONE_SETTINGS::GetMinIslandArea ( ) const
inline

Definition at line 205 of file zone_settings.h.

References m_minIslandArea.

Referenced by ExportSetting(), and DIALOG_COPPER_ZONE::TransferDataToWindow().

◆ GetPadConnection()

ZONE_CONNECTION ZONE_SETTINGS::GetPadConnection ( ) const
inline

Definition at line 182 of file zone_settings.h.

References m_padConnection.

Referenced by DIALOG_COPPER_ZONE::TransferDataToWindow().

◆ operator!=()

bool ZONE_SETTINGS::operator!= ( const ZONE_SETTINGS aOther) const
inline

Definition at line 141 of file zone_settings.h.

References operator==().

◆ operator<<()

ZONE_SETTINGS & ZONE_SETTINGS::operator<< ( const ZONE aSource)

operator << ( const ZONE& ) was Function ImportSetting copies settings from a given zone into this object.

Parameters
aSourcethe given zone

Definition at line 131 of file zone_settings.cpp.

References ZONE::GetAssignedPriority(), ZONE::GetBorderHatchPitch(), ZONE::GetCornerRadius(), ZONE::GetCornerSmoothingType(), ZONE::GetDoNotAllowCopperPour(), ZONE::GetDoNotAllowFootprints(), ZONE::GetDoNotAllowPads(), ZONE::GetDoNotAllowTracks(), ZONE::GetDoNotAllowVias(), ZONE::GetFillMode(), ZONE::GetHatchBorderAlgorithm(), ZONE::GetHatchGap(), ZONE::GetHatchHoleMinArea(), ZONE::GetHatchOrientation(), ZONE::GetHatchSmoothingLevel(), ZONE::GetHatchSmoothingValue(), ZONE::GetHatchStyle(), ZONE::GetHatchThickness(), ZONE::GetIslandRemovalMode(), ZONE::GetIsRuleArea(), ZONE::GetLayerSet(), ZONE::GetLocalClearance(), ZONE::GetMinIslandArea(), ZONE::GetMinThickness(), BOARD_CONNECTED_ITEM::GetNetCode(), ZONE::GetPadConnection(), ZONE::GetTeardropAreaType(), ZONE::GetThermalReliefGap(), ZONE::GetThermalReliefSpokeWidth(), ZONE::GetZoneName(), BOARD_ITEM::IsLocked(), m_BorderHatchPitch, m_cornerRadius, m_cornerSmoothingType, m_FillMode, m_HatchBorderAlgorithm, m_HatchGap, m_HatchHoleMinArea, m_HatchOrientation, m_HatchSmoothingLevel, m_HatchSmoothingValue, m_HatchThickness, m_isRuleArea, m_keepoutDoNotAllowCopperPour, m_keepoutDoNotAllowFootprints, m_keepoutDoNotAllowPads, m_keepoutDoNotAllowTracks, m_keepoutDoNotAllowVias, m_Layers, m_Locked, m_minIslandArea, m_Name, m_NetcodeSelection, m_padConnection, m_removeIslands, m_TeardropType, m_ThermalReliefGap, m_ThermalReliefSpokeWidth, m_ZoneBorderDisplayStyle, m_ZoneClearance, m_ZoneMinThickness, and m_ZonePriority.

◆ operator==()

◆ SetCornerRadius()

void ZONE_SETTINGS::SetCornerRadius ( int  aRadius)

◆ SetCornerSmoothingType()

void ZONE_SETTINGS::SetCornerSmoothingType ( int  aType)
inline

◆ SetDoNotAllowCopperPour()

void ZONE_SETTINGS::SetDoNotAllowCopperPour ( bool  aEnable)
inline

◆ SetDoNotAllowFootprints()

void ZONE_SETTINGS::SetDoNotAllowFootprints ( bool  aEnable)
inline

◆ SetDoNotAllowPads()

void ZONE_SETTINGS::SetDoNotAllowPads ( bool  aEnable)
inline

◆ SetDoNotAllowTracks()

void ZONE_SETTINGS::SetDoNotAllowTracks ( bool  aEnable)
inline

◆ SetDoNotAllowVias()

void ZONE_SETTINGS::SetDoNotAllowVias ( bool  aEnable)
inline

◆ SetIslandRemovalMode()

void ZONE_SETTINGS::SetIslandRemovalMode ( ISLAND_REMOVAL_MODE  aRemove)
inline

◆ SetIsRuleArea()

void ZONE_SETTINGS::SetIsRuleArea ( bool  aEnable)
inline

◆ SetMinIslandArea()

void ZONE_SETTINGS::SetMinIslandArea ( long long int  aArea)
inline

Definition at line 206 of file zone_settings.h.

References m_minIslandArea.

Referenced by DIALOG_COPPER_ZONE::AcceptOptions().

◆ SetPadConnection()

void ZONE_SETTINGS::SetPadConnection ( ZONE_CONNECTION  aPadConnection)
inline

Definition at line 183 of file zone_settings.h.

References m_padConnection.

Referenced by DIALOG_COPPER_ZONE::AcceptOptions().

◆ SetupLayersList()

void ZONE_SETTINGS::SetupLayersList ( wxDataViewListCtrl *  aList,
PCB_BASE_FRAME aFrame,
LSET  aLayers,
bool  aFpEditorMode 
)

A helper routine for the various zone dialogs (copper, non-copper, keepout).

Parameters
aListthe wxDataViewListCtrl to populate
aFramethe parent editor frame
aFpEditorModetrue to show a single "Inner Layers" item for all inner copper layers

Definition at line 252 of file zone_settings.cpp.

References _, CHECKERBOARD_SIZE(), PCB_BASE_FRAME::GetBoard(), COLOR_SETTINGS::GetColor(), PCB_BASE_FRAME::GetColorSettings(), BOARD::GetLayerName(), KIUI::GetTextSize(), In1_Cu, LAYER_BITMAP_SIZE(), LAYER_PCB_BACKGROUND, m_Layers, COLOR_SWATCH::MakeBitmap(), and LSET::UIOrder().

Referenced by DIALOG_COPPER_ZONE::DIALOG_COPPER_ZONE(), DIALOG_NON_COPPER_ZONES_EDITOR::DIALOG_NON_COPPER_ZONES_EDITOR(), and DIALOG_RULE_AREA_PROPERTIES::DIALOG_RULE_AREA_PROPERTIES().

Member Data Documentation

◆ m_BorderHatchPitch

◆ m_cornerRadius

unsigned int ZONE_SETTINGS::m_cornerRadius
private

◆ m_cornerSmoothingType

int ZONE_SETTINGS::m_cornerSmoothingType
private

◆ m_FillMode

◆ m_HatchBorderAlgorithm

int ZONE_SETTINGS::m_HatchBorderAlgorithm

Definition at line 94 of file zone_settings.h.

Referenced by ExportSetting(), operator<<(), operator==(), and ZONE_SETTINGS().

◆ m_HatchGap

◆ m_HatchHoleMinArea

double ZONE_SETTINGS::m_HatchHoleMinArea

Definition at line 93 of file zone_settings.h.

Referenced by ExportSetting(), operator<<(), operator==(), and ZONE_SETTINGS().

◆ m_HatchOrientation

◆ m_HatchSmoothingLevel

◆ m_HatchSmoothingValue

◆ m_HatchThickness

◆ m_isRuleArea

bool ZONE_SETTINGS::m_isRuleArea
private

Definition at line 125 of file zone_settings.h.

Referenced by ExportSetting(), GetIsRuleArea(), operator<<(), operator==(), and SetIsRuleArea().

◆ m_keepoutDoNotAllowCopperPour

bool ZONE_SETTINGS::m_keepoutDoNotAllowCopperPour
private

◆ m_keepoutDoNotAllowFootprints

bool ZONE_SETTINGS::m_keepoutDoNotAllowFootprints
private

◆ m_keepoutDoNotAllowPads

bool ZONE_SETTINGS::m_keepoutDoNotAllowPads
private

Definition at line 130 of file zone_settings.h.

Referenced by GetDoNotAllowPads(), operator<<(), operator==(), and SetDoNotAllowPads().

◆ m_keepoutDoNotAllowTracks

bool ZONE_SETTINGS::m_keepoutDoNotAllowTracks
private

Definition at line 129 of file zone_settings.h.

Referenced by GetDoNotAllowTracks(), operator<<(), operator==(), and SetDoNotAllowTracks().

◆ m_keepoutDoNotAllowVias

bool ZONE_SETTINGS::m_keepoutDoNotAllowVias
private

Definition at line 128 of file zone_settings.h.

Referenced by GetDoNotAllowVias(), operator<<(), operator==(), and SetDoNotAllowVias().

◆ m_Layers

◆ m_Locked

◆ m_minIslandArea

long long int ZONE_SETTINGS::m_minIslandArea
private

◆ m_Name

◆ m_NetcodeSelection

◆ m_padConnection

ZONE_CONNECTION ZONE_SETTINGS::m_padConnection
private

◆ m_removeIslands

ISLAND_REMOVAL_MODE ZONE_SETTINGS::m_removeIslands
private

◆ m_TeardropType

TEARDROP_TYPE ZONE_SETTINGS::m_TeardropType

◆ m_ThermalReliefGap

long ZONE_SETTINGS::m_ThermalReliefGap

◆ m_ThermalReliefSpokeWidth

long ZONE_SETTINGS::m_ThermalReliefSpokeWidth

◆ m_ZoneBorderDisplayStyle

◆ m_ZoneClearance

◆ m_ZoneMinThickness

◆ m_ZonePriority


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