Clean up including of board_design_settings.h
This commit is contained in:
parent
e4530fcf0d
commit
10e60acf34
|
@ -29,6 +29,7 @@
|
|||
|
||||
#include "../3d_rendering/camera.h"
|
||||
#include "board_adapter.h"
|
||||
#include <board_design_settings.h>
|
||||
#include <3d_rendering/3d_render_raytracing/shapes2D/polygon_2d.h>
|
||||
#include <board.h>
|
||||
#include <3d_math.h>
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
#include "../3d_rendering/3d_render_raytracing/shapes3D/cylinder_3d.h"
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_text.h>
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
#include <3d_viewer/tools/3d_controller.h>
|
||||
#include <3d_viewer/tools/3d_conditions.h>
|
||||
#include <bitmaps.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_stackup_manager/board_stackup.h>
|
||||
#include <board_stackup_manager/stackup_predefined_prms.h>
|
||||
#include <board.h>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <kicad_string.h>
|
||||
#include <kiplatform/ui.h>
|
||||
|
||||
#include <widgets/ui_common.h>
|
||||
#include <widgets/net_selector.h>
|
||||
|
||||
#include <board.h>
|
||||
|
|
|
@ -25,7 +25,8 @@
|
|||
#ifndef BOARD_DESIGN_SETTINGS_H_
|
||||
#define BOARD_DESIGN_SETTINGS_H_
|
||||
|
||||
#include <pad.h>
|
||||
#include <memory>
|
||||
|
||||
#include <netclass.h>
|
||||
#include <config_params.h>
|
||||
#include <board_stackup_manager/board_stackup.h>
|
||||
|
@ -211,6 +212,7 @@ enum class DIM_UNITS_FORMAT : int;
|
|||
enum class DIM_TEXT_POSITION : int;
|
||||
enum class DIM_UNITS_MODE : int;
|
||||
|
||||
class PAD;
|
||||
|
||||
/**
|
||||
* Container for design settings for a #BOARD object.
|
||||
|
@ -750,8 +752,8 @@ public:
|
|||
wxPoint m_AuxOrigin; ///< origin for plot exports
|
||||
wxPoint m_GridOrigin; ///< origin for grid offsets
|
||||
|
||||
PAD m_Pad_Master; // A dummy pad to store all default parameters
|
||||
// when importing values or creating a new pad
|
||||
std::unique_ptr<PAD> m_Pad_Master; // A dummy pad to store all default parameters
|
||||
// when importing values or creating a new pad
|
||||
|
||||
// Set to true if the board has a stackup management.
|
||||
// If not set a default basic stackup will be used to generate the gbrjob file.
|
||||
|
|
|
@ -226,6 +226,7 @@ set( PCBNEW_MICROWAVE_SRCS
|
|||
)
|
||||
|
||||
set( PCBNEW_DRC_SRCS
|
||||
drc/drc_results_provider.cpp
|
||||
drc/drc_test_provider.cpp
|
||||
drc/drc_test_provider_annulus.cpp
|
||||
drc/drc_test_provider_disallow.cpp
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <iterator>
|
||||
#include <drc/drc_rtree.h>
|
||||
#include <pcb_base_frame.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <reporter.h>
|
||||
#include <board_commit.h>
|
||||
#include <board.h>
|
||||
|
@ -487,6 +488,12 @@ void BOARD::SetEnabledLayers( LSET aLayerSet )
|
|||
}
|
||||
|
||||
|
||||
bool BOARD::IsLayerEnabled( PCB_LAYER_ID aLayer ) const
|
||||
{
|
||||
return GetDesignSettings().IsLayerEnabled( aLayer );
|
||||
}
|
||||
|
||||
|
||||
void BOARD::SetVisibleLayers( LSET aLayerSet )
|
||||
{
|
||||
if( m_project )
|
||||
|
@ -577,6 +584,25 @@ bool BOARD::IsFootprintLayerVisible( PCB_LAYER_ID aLayer ) const
|
|||
}
|
||||
|
||||
|
||||
|
||||
BOARD_DESIGN_SETTINGS& BOARD::GetDesignSettings() const
|
||||
{
|
||||
return *m_designSettings;
|
||||
}
|
||||
|
||||
|
||||
const ZONE_SETTINGS& BOARD::GetZoneSettings() const
|
||||
{
|
||||
return GetDesignSettings().GetDefaultZoneSettings();
|
||||
}
|
||||
|
||||
|
||||
void BOARD::SetZoneSettings( const ZONE_SETTINGS& aSettings )
|
||||
{
|
||||
GetDesignSettings().SetDefaultZoneSettings( aSettings );
|
||||
}
|
||||
|
||||
|
||||
void BOARD::Add( BOARD_ITEM* aBoardItem, ADD_MODE aMode )
|
||||
{
|
||||
if( aBoardItem == nullptr )
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
#ifndef CLASS_BOARD_H_
|
||||
#define CLASS_BOARD_H_
|
||||
|
||||
#include <board_design_settings.h>
|
||||
#include <board_item_container.h>
|
||||
#include <common.h> // Needed for stl hash extensions
|
||||
#include <convert_drawsegment_list_to_polygon.h> // for OUTLINE_ERROR_HANDLER
|
||||
|
@ -35,7 +34,10 @@
|
|||
#include <pcb_plot_params.h>
|
||||
#include <title_block.h>
|
||||
#include <tools/pcb_selection.h>
|
||||
#include <mutex>
|
||||
|
||||
class BOARD_DESIGN_SETTINGS;
|
||||
class BOARD_CONNECTED_ITEM;
|
||||
class BOARD_COMMIT;
|
||||
class DRC_RTREE;
|
||||
class PCB_BASE_FRAME;
|
||||
|
@ -438,10 +440,7 @@ public:
|
|||
* @param aLayer = The layer to be tested
|
||||
* @return true if the layer is visible.
|
||||
*/
|
||||
bool IsLayerEnabled( PCB_LAYER_ID aLayer ) const
|
||||
{
|
||||
return GetDesignSettings().IsLayerEnabled( aLayer );
|
||||
}
|
||||
bool IsLayerEnabled( PCB_LAYER_ID aLayer ) const;
|
||||
|
||||
/**
|
||||
* A proxy function that calls the correspondent function in m_BoardSettings
|
||||
|
@ -523,20 +522,11 @@ public:
|
|||
/**
|
||||
* @return the BOARD_DESIGN_SETTINGS for this BOARD
|
||||
*/
|
||||
BOARD_DESIGN_SETTINGS& GetDesignSettings() const
|
||||
{
|
||||
return *m_designSettings;
|
||||
}
|
||||
BOARD_DESIGN_SETTINGS& GetDesignSettings() const;
|
||||
|
||||
const ZONE_SETTINGS& GetZoneSettings() const override
|
||||
{
|
||||
return GetDesignSettings().GetDefaultZoneSettings();
|
||||
}
|
||||
const ZONE_SETTINGS& GetZoneSettings() const override;
|
||||
|
||||
void SetZoneSettings( const ZONE_SETTINGS& aSettings ) override
|
||||
{
|
||||
GetDesignSettings().SetDefaultZoneSettings( aSettings );
|
||||
}
|
||||
void SetZoneSettings( const ZONE_SETTINGS& aSettings ) override;
|
||||
|
||||
const PAGE_INFO& GetPageSettings() const { return m_paper; }
|
||||
void SetPageSettings( const PAGE_INFO& aPageSettings ) { m_paper = aPageSettings; }
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
*/
|
||||
|
||||
#include <board.h>
|
||||
#include <board_item.h>
|
||||
#include <board_connected_item.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <connectivity/connectivity_data.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <kicad_string.h>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <track.h>
|
||||
#include <layers_id_colors_and_visibility.h>
|
||||
#include <kiface_i.h>
|
||||
#include <pad.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_engine.h>
|
||||
|
@ -32,14 +33,14 @@
|
|||
#include <settings/parameters.h>
|
||||
#include <project/project_file.h>
|
||||
#include <advanced_config.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pcbnew.h>
|
||||
|
||||
const int bdsSchemaVersion = 2;
|
||||
|
||||
|
||||
BOARD_DESIGN_SETTINGS::BOARD_DESIGN_SETTINGS( JSON_SETTINGS* aParent, const std::string& aPath ) :
|
||||
NESTED_SETTINGS( "board_design_settings", bdsSchemaVersion, aParent, aPath ),
|
||||
m_Pad_Master( NULL )
|
||||
NESTED_SETTINGS( "board_design_settings", bdsSchemaVersion, aParent, aPath )
|
||||
{
|
||||
// We want to leave alone parameters that aren't found in the project JSON as they may be
|
||||
// initialized by the board file parser before NESTED_SETTINGS::LoadFromFile is called.
|
||||
|
@ -53,6 +54,8 @@ BOARD_DESIGN_SETTINGS::BOARD_DESIGN_SETTINGS( JSON_SETTINGS* aParent, const std:
|
|||
|
||||
m_HasStackup = false; // no stackup defined by default
|
||||
|
||||
m_Pad_Master = std::make_unique<PAD>( nullptr );
|
||||
|
||||
LSET all_set = LSET().set();
|
||||
m_enabledLayers = all_set; // All layers enabled at first.
|
||||
// SetCopperLayerCount() will adjust this.
|
||||
|
@ -560,9 +563,9 @@ BOARD_DESIGN_SETTINGS::BOARD_DESIGN_SETTINGS( JSON_SETTINGS* aParent, const std:
|
|||
{
|
||||
nlohmann::json ret =
|
||||
{
|
||||
{ "width", Iu2Millimeter( m_Pad_Master.GetSize().x ) },
|
||||
{ "height", Iu2Millimeter( m_Pad_Master.GetSize().y ) },
|
||||
{ "drill", Iu2Millimeter( m_Pad_Master.GetDrillSize().x ) }
|
||||
{ "width", Iu2Millimeter( m_Pad_Master->GetSize().x ) },
|
||||
{ "height", Iu2Millimeter( m_Pad_Master->GetSize().y ) },
|
||||
{ "drill", Iu2Millimeter( m_Pad_Master->GetDrillSize().x ) }
|
||||
};
|
||||
|
||||
return ret;
|
||||
|
@ -576,11 +579,11 @@ BOARD_DESIGN_SETTINGS::BOARD_DESIGN_SETTINGS( JSON_SETTINGS* aParent, const std:
|
|||
sz.SetWidth( Millimeter2iu( aJson["width"].get<double>() ) );
|
||||
sz.SetHeight( Millimeter2iu( aJson["height"].get<double>() ) );
|
||||
|
||||
m_Pad_Master.SetSize( sz );
|
||||
m_Pad_Master->SetSize( sz );
|
||||
|
||||
int drill = Millimeter2iu( aJson["drill"].get<double>() );
|
||||
|
||||
m_Pad_Master.SetDrillSize( wxSize( drill, drill ) );
|
||||
m_Pad_Master->SetDrillSize( wxSize( drill, drill ) );
|
||||
}
|
||||
}, {} ) );
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
#include <vector>
|
||||
#include <bezier_curves.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <trigo.h>
|
||||
#include <board.h>
|
||||
#include <pad.h>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
#include <widgets/paged_dialog.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_stackup_manager/stackup_predefined_prms.h>
|
||||
#include "panel_board_finish.h"
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <macros.h> // arrayDim definition
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dialogs/dialog_color_picker.h>
|
||||
#include <widgets/paged_dialog.h>
|
||||
#include <widgets/layer_box_selector.h>
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <math/vector2d.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <base_units.h>
|
||||
#include <convert_basic_shapes_to_polygon.h>
|
||||
#include <geometry/shape_poly_set.h>
|
||||
|
|
|
@ -32,7 +32,9 @@
|
|||
*/
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
#include <collectors.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <../board_stackup_manager/panel_board_stackup.h>
|
||||
#include <../board_stackup_manager/panel_board_finish.h>
|
||||
#include <confirm.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <kiface_i.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <dialog_import_settings.h>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
|
||||
#include "dialog_board_statistics.h"
|
||||
#include "base_units.h"
|
||||
#include <pad.h>
|
||||
#include <macros.h>
|
||||
#include <wildcards_and_files_ext.h>
|
||||
#include <wx/filedlg.h>
|
||||
|
|
|
@ -25,8 +25,10 @@
|
|||
|
||||
#include <confirm.h>
|
||||
#include <dialog_drc.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <kiface_i.h>
|
||||
#include <macros.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <pcbnew_settings.h>
|
||||
#include <pgm_base.h>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <board_commit.h>
|
||||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <dialog_exchange_footprints.h>
|
||||
#include <kicad_string.h>
|
||||
#include <kiway.h>
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <pcbnew_settings.h>
|
||||
#include <wildcards_and_files_ext.h>
|
||||
#include <reporter.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <confirm.h>
|
||||
#include <core/arraydim.h>
|
||||
#include <core/kicad_algo.h>
|
||||
|
|
|
@ -32,8 +32,10 @@
|
|||
#include <bitmaps.h>
|
||||
#include <tools/board_editor_control.h>
|
||||
#include <board.h>
|
||||
#include <track.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <paths.h>
|
||||
#include <dialog_gendrill.h>
|
||||
#include <wildcards_and_files_ext.h>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <pcb_layer_box_selector.h>
|
||||
#include <pcbnew.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <dimension.h>
|
||||
#include <fp_shape.h>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <track.h>
|
||||
#include <connectivity/connectivity_data.h>
|
||||
#include <pcb_layer_box_selector.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <kicad_string.h>
|
||||
#include <tools/board_inspection_tool.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <track.h>
|
||||
#include <dialog_net_inspector.h>
|
||||
#include <eda_pattern_match.h>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <bitmaps.h>
|
||||
#include <board_commit.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <confirm.h>
|
||||
#include <core/arraydim.h>
|
||||
|
@ -37,6 +38,7 @@
|
|||
#include <gal/graphics_abstraction_layer.h>
|
||||
#include <dialogs/html_messagebox.h>
|
||||
#include <macros.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_base_frame.h>
|
||||
#include <footprint_edit_frame.h>
|
||||
#include <pcb_painter.h>
|
||||
|
@ -161,7 +163,7 @@ DIALOG_PAD_PROPERTIES::DIALOG_PAD_PROPERTIES( PCB_BASE_FRAME* aParent, PAD* aPad
|
|||
m_FlippedWarningIcon->SetBitmap( KiBitmap( BITMAPS::dialog_warning ) );
|
||||
m_nonCopperWarningIcon->SetBitmap( KiBitmap( BITMAPS::dialog_warning ) );
|
||||
|
||||
m_padMaster = &m_parent->GetDesignSettings().m_Pad_Master;
|
||||
m_padMaster = m_parent->GetDesignSettings().m_Pad_Master.get();
|
||||
m_dummyPad = new PAD( (FOOTPRINT*) NULL );
|
||||
|
||||
if( aPad )
|
||||
|
@ -1072,6 +1074,13 @@ void DIALOG_PAD_PROPERTIES::OnUpdateUI( wxUpdateUIEvent& event )
|
|||
}
|
||||
|
||||
|
||||
void DIALOG_PAD_PROPERTIES::OnUpdateUINonCopperWarning( wxUpdateUIEvent& event )
|
||||
{
|
||||
bool isOnCopperLayer = ( m_dummyPad->GetLayerSet() & LSET::AllCuMask() ).any();
|
||||
m_nonCopperWarningBook->SetSelection( isOnCopperLayer ? 0 : 1 );
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_PAD_PROPERTIES::updatePadLayersList( LSET layer_mask, bool remove_unconnected,
|
||||
bool keep_top_bottom )
|
||||
{
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
#include <wx/valnum.h>
|
||||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <pad_shapes.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <origin_viewitem.h>
|
||||
#include <dialog_pad_properties_base.h>
|
||||
|
@ -79,11 +80,7 @@ private:
|
|||
void OnCancel( wxCommandEvent& event ) override;
|
||||
void OnUpdateUI( wxUpdateUIEvent& event ) override;
|
||||
|
||||
void OnUpdateUINonCopperWarning( wxUpdateUIEvent& event ) override
|
||||
{
|
||||
bool isOnCopperLayer = ( m_dummyPad->GetLayerSet() & LSET::AllCuMask() ).any();
|
||||
m_nonCopperWarningBook->SetSelection( isOnCopperLayer ? 0 : 1 );
|
||||
}
|
||||
void OnUpdateUINonCopperWarning( wxUpdateUIEvent& event ) override;
|
||||
|
||||
void OnPadShapeSelection( wxCommandEvent& event ) override;
|
||||
void OnDrillShapeSelected( wxCommandEvent& event ) override;
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
#include <locale_io.h>
|
||||
#include <bitmaps.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dialog_plot.h>
|
||||
#include <dialog_gendrill.h>
|
||||
#include <wx_html_report_panel.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <tools/pcb_actions.h>
|
||||
#include <widgets/tab_traversal.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <trigo.h>
|
||||
|
||||
// initialise statics
|
||||
|
|
|
@ -27,7 +27,9 @@
|
|||
#include <dialogs/dialog_track_via_properties.h>
|
||||
#include <pcb_layer_box_selector.h>
|
||||
#include <tools/pcb_selection_tool.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <confirm.h>
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
#include <board.h>
|
||||
#include <dimension.h>
|
||||
#include <pcb_text.h>
|
||||
#include <geometry/shape_compound.h>
|
||||
#include <geometry/shape_circle.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
#include <settings/color_settings.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <reporter.h>
|
||||
#include <widgets/progress_reporter.h>
|
||||
#include <kicad_string.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_rtree.h>
|
||||
#include <drc/drc_rule_parser.h>
|
||||
|
@ -33,6 +34,7 @@
|
|||
#include <drc/drc_rule_condition.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
#include <geometry/shape.h>
|
||||
|
|
|
@ -0,0 +1,113 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2018-2021 KiCad Developers, see change_log.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
* as published by the Free Software Foundation; either version 2
|
||||
* of the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <board_design_settings.h>
|
||||
#include "drc_results_provider.h"
|
||||
|
||||
void BOARD_DRC_ITEMS_PROVIDER::SetSeverities( int aSeverities )
|
||||
{
|
||||
m_severities = aSeverities;
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_board->GetDesignSettings();
|
||||
|
||||
m_filteredMarkers.clear();
|
||||
|
||||
for( PCB_MARKER* marker : m_board->Markers() )
|
||||
{
|
||||
SEVERITY markerSeverity;
|
||||
|
||||
if( marker->IsExcluded() )
|
||||
markerSeverity = RPT_SEVERITY_EXCLUSION;
|
||||
else
|
||||
markerSeverity = bds.GetSeverity( marker->GetRCItem()->GetErrorCode() );
|
||||
|
||||
if( markerSeverity & m_severities )
|
||||
m_filteredMarkers.push_back( marker );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int BOARD_DRC_ITEMS_PROVIDER::GetCount( int aSeverity ) const
|
||||
{
|
||||
if( aSeverity < 0 )
|
||||
return m_filteredMarkers.size();
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_board->GetDesignSettings();
|
||||
|
||||
int count = 0;
|
||||
|
||||
for( PCB_MARKER* marker : m_board->Markers() )
|
||||
{
|
||||
SEVERITY markerSeverity;
|
||||
|
||||
if( marker->IsExcluded() )
|
||||
markerSeverity = RPT_SEVERITY_EXCLUSION;
|
||||
else
|
||||
markerSeverity = bds.GetSeverity( marker->GetRCItem()->GetErrorCode() );
|
||||
|
||||
if( markerSeverity == aSeverity )
|
||||
count++;
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
||||
|
||||
|
||||
void VECTOR_DRC_ITEMS_PROVIDER::SetSeverities( int aSeverities )
|
||||
{
|
||||
m_severities = aSeverities;
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_frame->GetBoard()->GetDesignSettings();
|
||||
|
||||
m_filteredVector.clear();
|
||||
|
||||
if( m_sourceVector )
|
||||
{
|
||||
for( const std::shared_ptr<DRC_ITEM>& item : *m_sourceVector )
|
||||
{
|
||||
if( bds.GetSeverity( item->GetErrorCode() ) & aSeverities )
|
||||
m_filteredVector.push_back( item );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int VECTOR_DRC_ITEMS_PROVIDER::GetCount( int aSeverity ) const
|
||||
{
|
||||
if( aSeverity < 0 )
|
||||
return m_filteredVector.size();
|
||||
|
||||
int count = 0;
|
||||
BOARD_DESIGN_SETTINGS& bds = m_frame->GetBoard()->GetDesignSettings();
|
||||
|
||||
if( m_sourceVector )
|
||||
{
|
||||
for( const std::shared_ptr<DRC_ITEM>& item : *m_sourceVector )
|
||||
{
|
||||
if( bds.GetSeverity( item->GetErrorCode() ) == aSeverity )
|
||||
count++;
|
||||
}
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2018-2020 KiCad Developers, see change_log.txt for contributors.
|
||||
* Copyright (C) 2018-2021 KiCad Developers, see change_log.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -53,52 +53,9 @@ public:
|
|||
{
|
||||
}
|
||||
|
||||
void SetSeverities( int aSeverities ) override
|
||||
{
|
||||
m_severities = aSeverities;
|
||||
void SetSeverities( int aSeverities ) override;
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_board->GetDesignSettings();
|
||||
|
||||
m_filteredMarkers.clear();
|
||||
|
||||
for( PCB_MARKER* marker : m_board->Markers() )
|
||||
{
|
||||
SEVERITY markerSeverity;
|
||||
|
||||
if( marker->IsExcluded() )
|
||||
markerSeverity = RPT_SEVERITY_EXCLUSION;
|
||||
else
|
||||
markerSeverity = bds.GetSeverity( marker->GetRCItem()->GetErrorCode() );
|
||||
|
||||
if( markerSeverity & m_severities )
|
||||
m_filteredMarkers.push_back( marker );
|
||||
}
|
||||
}
|
||||
|
||||
int GetCount( int aSeverity = -1 ) const override
|
||||
{
|
||||
if( aSeverity < 0 )
|
||||
return m_filteredMarkers.size();
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_board->GetDesignSettings();
|
||||
|
||||
int count = 0;
|
||||
|
||||
for( PCB_MARKER* marker : m_board->Markers() )
|
||||
{
|
||||
SEVERITY markerSeverity;
|
||||
|
||||
if( marker->IsExcluded() )
|
||||
markerSeverity = RPT_SEVERITY_EXCLUSION;
|
||||
else
|
||||
markerSeverity = bds.GetSeverity( marker->GetRCItem()->GetErrorCode() );
|
||||
|
||||
if( markerSeverity == aSeverity )
|
||||
count++;
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
||||
int GetCount( int aSeverity = -1 ) const override;
|
||||
|
||||
std::shared_ptr<RC_ITEM> GetItem( int aIndex ) const override
|
||||
{
|
||||
|
@ -149,43 +106,9 @@ public:
|
|||
{
|
||||
}
|
||||
|
||||
void SetSeverities( int aSeverities ) override
|
||||
{
|
||||
m_severities = aSeverities;
|
||||
void SetSeverities( int aSeverities ) override;
|
||||
|
||||
BOARD_DESIGN_SETTINGS& bds = m_frame->GetBoard()->GetDesignSettings();
|
||||
|
||||
m_filteredVector.clear();
|
||||
|
||||
if( m_sourceVector )
|
||||
{
|
||||
for( const std::shared_ptr<DRC_ITEM>& item : *m_sourceVector )
|
||||
{
|
||||
if( bds.GetSeverity( item->GetErrorCode() ) & aSeverities )
|
||||
m_filteredVector.push_back( item );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int GetCount( int aSeverity = -1 ) const override
|
||||
{
|
||||
if( aSeverity < 0 )
|
||||
return m_filteredVector.size();
|
||||
|
||||
int count = 0;
|
||||
BOARD_DESIGN_SETTINGS& bds = m_frame->GetBoard()->GetDesignSettings();
|
||||
|
||||
if( m_sourceVector )
|
||||
{
|
||||
for( const std::shared_ptr<DRC_ITEM>& item : *m_sourceVector )
|
||||
{
|
||||
if( bds.GetSeverity( item->GetErrorCode() ) == aSeverity )
|
||||
count++;
|
||||
}
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
||||
int GetCount( int aSeverity = -1 ) const override;
|
||||
|
||||
std::shared_ptr<RC_ITEM> GetItem( int aIndex ) const override
|
||||
{
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include <common.h>
|
||||
#include <track.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <connectivity/connectivity_data.h>
|
||||
#include <connectivity/connectivity_algo.h>
|
||||
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include <common.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pad.h>
|
||||
|
@ -34,6 +35,7 @@
|
|||
#include <geometry/shape_rect.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_rtree.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
*/
|
||||
|
||||
#include <geometry/shape_poly_set.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider_clearance_base.h>
|
||||
|
@ -46,13 +47,13 @@ public:
|
|||
m_isRuleDriven = false;
|
||||
}
|
||||
|
||||
virtual ~DRC_TEST_PROVIDER_COURTYARD_CLEARANCE ()
|
||||
virtual ~DRC_TEST_PROVIDER_COURTYARD_CLEARANCE ()
|
||||
{
|
||||
}
|
||||
|
||||
virtual bool Run() override;
|
||||
|
||||
virtual const wxString GetName() const override
|
||||
virtual const wxString GetName() const override
|
||||
{
|
||||
return "courtyard_clearance";
|
||||
}
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
#include <pad.h>
|
||||
#include <zone.h>
|
||||
|
||||
/*
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider_clearance_base.h>
|
||||
|
|
|
@ -22,11 +22,13 @@
|
|||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
#include <geometry/shape_circle.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider_clearance_base.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
*/
|
||||
|
||||
#include <board.h>
|
||||
#include <pad.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#include <pad.h>
|
||||
#include <track.h>
|
||||
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <board_design_settings.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <geometry/seg.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider_clearance_base.h>
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <geometry/seg.h>
|
||||
#include <geometry/shape_segment.h>
|
||||
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider_clearance_base.h>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
//#include <common.h>
|
||||
#include <track.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
*/
|
||||
|
||||
#include <track.h>
|
||||
#include <drc/drc_engine.h>
|
||||
#include <drc/drc_item.h>
|
||||
#include <drc/drc_rule.h>
|
||||
#include <drc/drc_test_provider.h>
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
#include <pcbnew_id.h>
|
||||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
#include <pcb_target.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <board_design_settings.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <pcbnew_id.h>
|
||||
#include <track.h>
|
||||
|
|
|
@ -38,7 +38,9 @@
|
|||
#include <locale_io.h>
|
||||
#include <pcbnew.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <vector>
|
||||
#include <cctype>
|
||||
|
|
|
@ -29,9 +29,10 @@
|
|||
#include <kicad_string.h>
|
||||
#include <macros.h>
|
||||
#include <locale_io.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <build_version.h>
|
||||
#include <export_footprints_placefile.h>
|
||||
|
||||
#include <pad.h>
|
||||
|
||||
class LIST_MOD // An helper class used to build a list of useful footprints.
|
||||
{
|
||||
|
|
|
@ -31,8 +31,10 @@
|
|||
|
||||
#include <build_version.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <fp_shape.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <confirm.h>
|
||||
#include <core/arraydim.h>
|
||||
|
|
|
@ -25,8 +25,10 @@
|
|||
#include <macros.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_item.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
#include <cstdio>
|
||||
|
|
|
@ -31,9 +31,11 @@
|
|||
#include <macros.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <fp_shape.h>
|
||||
#include <idf_parser.h>
|
||||
#include <pad.h>
|
||||
#include <build_version.h>
|
||||
#include <wx/msgdlg.h>
|
||||
#include "project.h"
|
||||
|
|
|
@ -34,8 +34,10 @@
|
|||
#include "3d_cache/3d_cache.h"
|
||||
#include "3d_cache/3d_info.h"
|
||||
#include "board.h"
|
||||
#include "board_design_settings.h"
|
||||
#include "fp_shape.h"
|
||||
#include "footprint.h"
|
||||
#include "pad.h"
|
||||
#include "pcb_text.h"
|
||||
#include "track.h"
|
||||
#include "convert_to_biu.h"
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
|
||||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <collectors.h>
|
||||
#include <reporter.h>
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <track.h>
|
||||
#include <pad.h>
|
||||
#include <pcbplot.h>
|
||||
#include <gendrill_gerber_writer.h>
|
||||
#include <reporter.h>
|
||||
|
|
|
@ -37,7 +37,9 @@
|
|||
#include <plotter.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
|
||||
|
|
|
@ -36,11 +36,13 @@
|
|||
#include <pgm_base.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
|
||||
#include <pcbplot.h>
|
||||
#include <wildcards_and_files_ext.h>
|
||||
#include <gbr_metadata.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
|
||||
|
||||
PLACEFILE_GERBER_WRITER::PLACEFILE_GERBER_WRITER( BOARD* aPcb )
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <kicad_string.h>
|
||||
#include <gestfich.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <3d_viewer/eda_3d_viewer.h>
|
||||
#include <pgm_base.h>
|
||||
#include <widgets/msgpanel.h>
|
||||
|
|
|
@ -32,8 +32,10 @@
|
|||
#include <kicad_string.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <fp_shape.h>
|
||||
#include <macros.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_text.h>
|
||||
#include <pcb_marker.h>
|
||||
#include <pcb_group.h>
|
||||
|
|
|
@ -27,12 +27,14 @@
|
|||
#include <base_units.h>
|
||||
#include <bitmaps.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <core/mirror.h>
|
||||
#include <footprint.h>
|
||||
#include <settings/settings_manager.h>
|
||||
#include <trigo.h>
|
||||
#include <kicad_string.h>
|
||||
#include <painter.h>
|
||||
#include <geometry/shape_compound.h>
|
||||
|
||||
FP_TEXT::FP_TEXT( FOOTPRINT* aParentFootprint, TEXT_TYPE text_type ) :
|
||||
BOARD_ITEM( aParentFootprint, PCB_FP_TEXT_T ),
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <project/project_file.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
|
||||
#include <pcbnew.h>
|
||||
#include <footprint_edit_frame.h>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <build_version.h>
|
||||
#include <board.h>
|
||||
#include <track.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_group.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pcb_text.h>
|
||||
|
|
|
@ -22,7 +22,9 @@
|
|||
*/
|
||||
|
||||
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <confirm.h>
|
||||
#include <dialogs/dialog_text_entry.h>
|
||||
#include <microwave/microwave_tool.h>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include <base_units.h>
|
||||
#include <board_commit.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pad.h>
|
||||
#include <fp_shape.h>
|
||||
#include <footprint.h>
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
#include <footprint.h>
|
||||
#include <fp_shape.h>
|
||||
#include <microwave/microwave_tool.h>
|
||||
#include <pad.h>
|
||||
#include <pcbnew.h>
|
||||
#include <math/util.h> // for KiROUND
|
||||
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
#include <widgets/msgpanel.h>
|
||||
#include <base_units.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <track.h>
|
||||
#include <pad.h>
|
||||
|
|
|
@ -37,7 +37,10 @@
|
|||
#include <i18n_utility.h>
|
||||
#include <view/view.h>
|
||||
#include <board.h>
|
||||
#include <board_connected_item.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <connectivity/connectivity_data.h>
|
||||
#include <convert_to_biu.h>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
*/
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_item.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pad.h>
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include <pcbnew_settings.h>
|
||||
#include <pgm_base.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dimension.h>
|
||||
#include <footprint_info_impl.h>
|
||||
#include <project.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
|
||||
#include <common.h>
|
||||
#include <pcbnew.h>
|
||||
#include <pad.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <layers_id_colors_and_visibility.h>
|
||||
#include <pcb_display_options.h>
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
#include <convert_to_biu.h>
|
||||
#include <invoke_pcb_dialog.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <drawing_sheet/ds_proxy_view_item.h>
|
||||
#include <connectivity/connectivity_data.h>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <cstdio>
|
||||
#include <memory>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <drc/drc_rtree.h>
|
||||
#include <track.h>
|
||||
#include <pcb_group.h>
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <base_units.h>
|
||||
#include <eda_draw_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pcb_marker.h>
|
||||
#include <layers_id_colors_and_visibility.h>
|
||||
#include <settings/color_settings.h>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
*/
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <track.h>
|
||||
#include <pcb_group.h>
|
||||
#include <footprint.h>
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <bitmaps.h>
|
||||
#include <pcb_edit_frame.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <base_units.h>
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
|
||||
#include <bitmaps.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pcb_target.h>
|
||||
#include <base_units.h>
|
||||
#include <settings/color_settings.h>
|
||||
|
|
|
@ -28,12 +28,14 @@
|
|||
#include <base_units.h>
|
||||
#include <bitmaps.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <core/mirror.h>
|
||||
#include <footprint.h>
|
||||
#include <pcb_text.h>
|
||||
#include <pcb_painter.h>
|
||||
#include <trigo.h>
|
||||
#include <kicad_string.h>
|
||||
#include <geometry/shape_compound.h>
|
||||
|
||||
using KIGFX::PCB_RENDER_SETTINGS;
|
||||
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <panel_pcbnew_display_origin.h>
|
||||
#include <tool/tool_manager.h>
|
||||
#include <tools/pcb_selection_tool.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <drawing_sheet/ds_data_model.h>
|
||||
#include <pcbplot.h>
|
||||
#include <pcb_painter.h>
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <locale_io.h>
|
||||
#include <reporter.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <plotcontroller.h>
|
||||
#include <pcb_plot_params.h>
|
||||
#include <wx/ffile.h>
|
||||
|
|
|
@ -36,10 +36,12 @@
|
|||
#include <math/util.h> // for KiROUND
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <core/arraydim.h>
|
||||
#include <footprint.h>
|
||||
#include <track.h>
|
||||
#include <fp_shape.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_text.h>
|
||||
#include <zone.h>
|
||||
#include <pcb_shape.h>
|
||||
|
|
|
@ -27,7 +27,9 @@
|
|||
#include <plugins/altium/altium_parser_utils.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dimension.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pcb_text.h>
|
||||
#include <track.h>
|
||||
|
|
|
@ -25,12 +25,15 @@
|
|||
|
||||
#include <cadstar_pcb_archive_loader.h>
|
||||
|
||||
#include <board_stackup_manager/board_stackup.h>
|
||||
#include <board_stackup_manager/stackup_predefined_prms.h> // KEY_COPPER, KEY_CORE, KEY_PREPREG
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dimension.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <fp_shape.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_group.h>
|
||||
#include <pcb_text.h>
|
||||
#include <project.h>
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <set>
|
||||
|
||||
class BOARD;
|
||||
class BOARD_STACKUP_ITEM;
|
||||
class DIMENSION_BASE;
|
||||
|
||||
class CADSTAR_PCB_ARCHIVE_LOADER : public CADSTAR_PCB_ARCHIVE_PARSER
|
||||
|
|
|
@ -69,10 +69,13 @@ Load() TODO's
|
|||
#include <math/util.h> // for KiROUND
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <fp_shape.h>
|
||||
#include <zone.h>
|
||||
#include <pad_shapes.h>
|
||||
#include <pcb_text.h>
|
||||
#include <dimension.h>
|
||||
|
||||
|
|
|
@ -39,10 +39,12 @@
|
|||
#include <wx/log.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_item.h>
|
||||
#include <convert_to_biu.h>
|
||||
#include <footprint.h>
|
||||
#include <fp_shape.h>
|
||||
#include <pad.h>
|
||||
#include <pad_shapes.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pcb_text.h>
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
|
||||
#include <board.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <locale_io.h>
|
||||
#include <macros.h>
|
||||
#include <pcb_text.h>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <advanced_config.h>
|
||||
#include <base_units.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <boost/ptr_container/ptr_map.hpp>
|
||||
#include <confirm.h>
|
||||
#include <convert_basic_shapes_to_polygon.h> // for enum RECT_CHAMFER_POSITIONS definition
|
||||
|
@ -36,6 +37,7 @@
|
|||
#include <kiface_i.h>
|
||||
#include <locale_io.h>
|
||||
#include <macros.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_group.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <pcb_target.h>
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
|
||||
#include <advanced_config.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dimension.h>
|
||||
#include <pcb_shape.h>
|
||||
#include <fp_shape.h>
|
||||
|
@ -1845,7 +1846,7 @@ void PCB_PARSER::parseSetup()
|
|||
wxSize sz;
|
||||
sz.SetWidth( parseBoardUnits( "master pad width" ) );
|
||||
sz.SetHeight( parseBoardUnits( "master pad height" ) );
|
||||
designSettings.m_Pad_Master.SetSize( sz );
|
||||
designSettings.m_Pad_Master->SetSize( sz );
|
||||
m_board->m_LegacyDesignSettingsLoaded = true;
|
||||
NeedRIGHT();
|
||||
}
|
||||
|
@ -1854,7 +1855,7 @@ void PCB_PARSER::parseSetup()
|
|||
case T_pad_drill:
|
||||
{
|
||||
int drillSize = parseBoardUnits( T_pad_drill );
|
||||
designSettings.m_Pad_Master.SetDrillSize( wxSize( drillSize, drillSize ) );
|
||||
designSettings.m_Pad_Master->SetDrillSize( wxSize( drillSize, drillSize ) );
|
||||
m_board->m_LegacyDesignSettingsLoaded = true;
|
||||
NeedRIGHT();
|
||||
}
|
||||
|
|
|
@ -72,7 +72,9 @@
|
|||
#include <zones.h>
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <pcb_text.h>
|
||||
#include <zone.h>
|
||||
|
@ -1067,13 +1069,13 @@ void LEGACY_PLUGIN::loadSETUP()
|
|||
BIU x = biuParse( line + SZ( "PadSize" ), &data );
|
||||
BIU y = biuParse( data );
|
||||
|
||||
bds.m_Pad_Master.SetSize( wxSize( x, y ) );
|
||||
bds.m_Pad_Master->SetSize( wxSize( x, y ) );
|
||||
}
|
||||
|
||||
else if( TESTLINE( "PadDrill" ) )
|
||||
{
|
||||
BIU tmp = biuParse( line + SZ( "PadDrill" ) );
|
||||
bds.m_Pad_Master.SetDrillSize( wxSize( tmp, tmp ) );
|
||||
bds.m_Pad_Master->SetDrillSize( wxSize( tmp, tmp ) );
|
||||
}
|
||||
|
||||
else if( TESTLINE( "Pad2MaskClearance" ) )
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
|
||||
#include <action_plugin.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pcb_marker.h>
|
||||
#include <cstdlib>
|
||||
#include <drc/drc_engine.h>
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
%ignore BOARD_DESIGN_SETTINGS::m_Pad_Master;
|
||||
|
||||
%include <board_design_settings.h>
|
||||
%{
|
||||
#include <board_design_settings.h>
|
||||
|
|
|
@ -21,8 +21,10 @@
|
|||
|
||||
#include <board.h>
|
||||
#include <board_connected_item.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <fp_text.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
#include <pcb_shape.h>
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "pns_topology.h"
|
||||
|
||||
#include <board.h>
|
||||
#include <pad.h>
|
||||
|
||||
namespace PNS {
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <functional>
|
||||
using namespace std::placeholders;
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <board_item.h>
|
||||
#include <footprint.h>
|
||||
#include <fp_shape.h>
|
||||
|
|
|
@ -43,9 +43,11 @@
|
|||
#include <map> // std::map
|
||||
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <fp_shape.h>
|
||||
#include <track.h>
|
||||
#include <pad.h>
|
||||
#include <zone.h>
|
||||
#include <base_units.h>
|
||||
#include <collectors.h>
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
#include <locale_io.h>
|
||||
#include <macros.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <footprint.h>
|
||||
#include <track.h>
|
||||
#include <connectivity/connectivity_data.h>
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
|
||||
#include <bitmaps.h>
|
||||
#include <board.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <dialog_helpers.h>
|
||||
#include <kiface_i.h>
|
||||
#include <macros.h>
|
||||
|
@ -419,7 +420,7 @@ void PCB_EDIT_FRAME::ReCreateVToolbar()
|
|||
|
||||
if( !tuneGroup )
|
||||
{
|
||||
tuneGroup = new ACTION_GROUP( "group.pcbTune",
|
||||
tuneGroup = new ACTION_GROUP( "group.pcbTune",
|
||||
{ &PCB_ACTIONS::routerTuneSingleTrace,
|
||||
&PCB_ACTIONS::routerTuneDiffPair,
|
||||
&PCB_ACTIONS::routerTuneDiffPairSkew } );
|
||||
|
@ -472,7 +473,7 @@ void PCB_EDIT_FRAME::ReCreateVToolbar()
|
|||
m_drawToolBar->AddToolContextMenu( PCB_ACTIONS::routeSingleTrack, makeRouteMenu() );
|
||||
m_drawToolBar->AddToolContextMenu( PCB_ACTIONS::routeDiffPair, makeRouteMenu() );
|
||||
|
||||
auto makeTuneMenu =
|
||||
auto makeTuneMenu =
|
||||
[&]()
|
||||
{
|
||||
std::unique_ptr<ACTION_MENU> tuneMenu = std::make_unique<ACTION_MENU>( false, selTool );
|
||||
|
|
|
@ -31,10 +31,12 @@
|
|||
#include "edit_tool.h"
|
||||
#include "tool/tool_event.h"
|
||||
#include <bitmaps.h>
|
||||
#include <board_commit.h>
|
||||
#include <board.h>
|
||||
#include <board_commit.h>
|
||||
#include <board_design_settings.h>
|
||||
#include <pcb_group.h>
|
||||
#include <footprint.h>
|
||||
#include <pad.h>
|
||||
#include <pcb_target.h>
|
||||
#include <track.h>
|
||||
#include <zone.h>
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue