KiCad PCB EDA Suite
PANEL_EESCHEMA_EDITING_OPTIONS Class Reference

#include <panel_eeschema_editing_options.h>

Inheritance diagram for PANEL_EESCHEMA_EDITING_OPTIONS:
PANEL_EESCHEMA_EDITING_OPTIONS_BASE

Public Member Functions

 PANEL_EESCHEMA_EDITING_OPTIONS (SCH_EDIT_FRAME *aFrame, wxWindow *aWindow)
 

Protected Attributes

wxCheckBox * m_checkHVOrientation
 
wxCheckBox * m_mouseDragIsDrag
 
wxCheckBox * m_cbAutoStartWires
 
wxStaticText * m_borderColorLabel
 
COLOR_SWATCHm_borderColorSwatch
 
wxStaticText * m_backgroundColorLabel
 
COLOR_SWATCHm_backgroundColorSwatch
 
wxCheckBox * m_cbPinSelectionOpt
 
wxSimplebook * m_leftClickCmdsBook
 
wxPanel * m_pageWinLin
 
wxStaticText * m_staticText8
 
wxStaticLine * m_staticline1
 
wxStaticText * m_staticText91
 
wxStaticText * m_staticText101
 
wxStaticText * m_staticText131
 
wxStaticText * m_staticText141
 
wxStaticText * m_staticText151
 
wxStaticText * m_staticText161
 
wxPanel * m_pageMac
 
wxStaticText * m_staticText81
 
wxStaticLine * m_staticline2
 
wxStaticText * m_staticText11
 
wxStaticText * m_staticText12
 
wxStaticText * m_staticText9
 
wxStaticText * m_staticText10
 
wxStaticText * m_staticText15
 
wxStaticText * m_staticText16
 
wxStaticText * m_staticText13
 
wxStaticText * m_staticText14
 
wxCheckBox * m_checkAutoplaceFields
 
wxCheckBox * m_checkAutoplaceJustify
 
wxCheckBox * m_checkAutoplaceAlign
 
wxStaticText * m_hPitchLabel
 
wxTextCtrl * m_hPitchCtrl
 
wxStaticText * m_hPitchUnits
 
wxStaticText * m_vPitchLabel
 
wxTextCtrl * m_vPitchCtrl
 
wxStaticText * m_vPitchUnits
 
wxStaticText * m_labelIncrementLabel
 
wxSpinCtrl * m_spinLabelRepeatStep
 
wxCheckBox * m_footprintPreview
 
wxCheckBox * m_navigatorStaysOpen
 

Private Member Functions

bool TransferDataToWindow () override
 
bool TransferDataFromWindow () override
 

Private Attributes

SCH_EDIT_FRAMEm_frame
 
UNIT_BINDER m_hPitch
 
UNIT_BINDER m_vPitch
 

Detailed Description

Definition at line 29 of file panel_eeschema_editing_options.h.

Constructor & Destructor Documentation

◆ PANEL_EESCHEMA_EDITING_OPTIONS()

PANEL_EESCHEMA_EDITING_OPTIONS::PANEL_EESCHEMA_EDITING_OPTIONS ( SCH_EDIT_FRAME aFrame,
wxWindow *  aWindow 
)

Definition at line 33 of file panel_eeschema_editing_options.cpp.

34  :
36  m_frame( aFrame ),
39 {
40  // Make the color swatch show "Clear Color" instead
41  m_borderColorSwatch->SetDefaultColor( COLOR4D::UNSPECIFIED );
42  m_backgroundColorSwatch->SetDefaultColor( COLOR4D::UNSPECIFIED );
43 
44 #ifdef __WXOSX_MAC__
45  m_leftClickCmdsBook->SetSelection( 1 );
46 #else
47  m_leftClickCmdsBook->SetSelection( 0 );
48 #endif
49 }
PANEL_EESCHEMA_EDITING_OPTIONS_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
void SetDefaultColor(const KIGFX::COLOR4D &aColor)
Sets the color that will be chosen with the "Reset to Default" button in the chooser.

References PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_backgroundColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_borderColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_leftClickCmdsBook, and COLOR_SWATCH::SetDefaultColor().

Member Function Documentation

◆ TransferDataFromWindow()

bool PANEL_EESCHEMA_EDITING_OPTIONS::TransferDataFromWindow ( )
overrideprivate

Definition at line 86 of file panel_eeschema_editing_options.cpp.

87 {
89 
92 
93  cfg->m_Drawing.default_repeat_offset_x = Iu2Mils( (int) m_hPitch.GetValue() );
94  cfg->m_Drawing.default_repeat_offset_y = Iu2Mils( (int) m_vPitch.GetValue() );
96 
97  cfg->m_Drawing.hv_lines_only = m_checkHVOrientation->GetValue();
100 
104 
105  cfg->m_Input.drag_is_move = !m_mouseDragIsDrag->GetValue();
107 
108  cfg->m_Drawing.auto_start_wires = m_cbAutoStartWires->GetValue();
109 
111 
112  return true;
113 }
KIGFX::COLOR4D GetSwatchColor() const
void SaveProjectSettings() override
Save changes to the project settings to the project (.pro) file.
EESCHEMA_SETTINGS * eeconfig() const
AUTOPLACE_FIELDS m_AutoplaceFields
virtual long long int GetValue()
Return the current value in Internal Units.

References EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::align_to_grid, EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::allow_rejustify, EESCHEMA_SETTINGS::DRAWING::auto_start_wires, EESCHEMA_SETTINGS::DRAWING::default_repeat_offset_x, EESCHEMA_SETTINGS::DRAWING::default_repeat_offset_y, EESCHEMA_SETTINGS::DRAWING::default_sheet_background_color, EESCHEMA_SETTINGS::DRAWING::default_sheet_border_color, EESCHEMA_SETTINGS::INPUT::drag_is_move, SCH_BASE_FRAME::eeconfig(), EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::enable, EESCHEMA_SETTINGS::APPEARANCE::footprint_preview, COLOR_SWATCH::GetSwatchColor(), UNIT_BINDER::GetValue(), EESCHEMA_SETTINGS::DRAWING::hv_lines_only, EESCHEMA_SETTINGS::m_Appearance, EESCHEMA_SETTINGS::m_AutoplaceFields, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_backgroundColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_borderColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbAutoStartWires, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbPinSelectionOpt, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceAlign, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceFields, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceJustify, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkHVOrientation, EESCHEMA_SETTINGS::m_Drawing, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_footprintPreview, m_frame, m_hPitch, EESCHEMA_SETTINGS::m_Input, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_mouseDragIsDrag, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_navigatorStaysOpen, EESCHEMA_SETTINGS::m_Selection, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_spinLabelRepeatStep, m_vPitch, EESCHEMA_SETTINGS::APPEARANCE::navigator_stays_open, EESCHEMA_SETTINGS::DRAWING::repeat_label_increment, SCH_EDIT_FRAME::SaveProjectSettings(), and EESCHEMA_SETTINGS::SELECTION::select_pin_selects_symbol.

◆ TransferDataToWindow()

bool PANEL_EESCHEMA_EDITING_OPTIONS::TransferDataToWindow ( )
overrideprivate

Definition at line 52 of file panel_eeschema_editing_options.cpp.

53 {
55 
59 
61  COLOR4D schematicBackground = settings->GetColor( LAYER_SCHEMATIC_BACKGROUND );
62 
63  m_borderColorSwatch->SetSwatchBackground( schematicBackground );
65 
66  m_backgroundColorSwatch->SetSwatchBackground( schematicBackground );
68 
72 
76 
77  m_mouseDragIsDrag->SetValue( !cfg->m_Input.drag_is_move );
79 
81 
82  return true;
83 }
void SetSwatchColor(const KIGFX::COLOR4D &aColor, bool aSendEvent)
Set the current swatch color directly.
EESCHEMA_SETTINGS * eeconfig() const
AUTOPLACE_FIELDS m_AutoplaceFields
COLOR_SETTINGS * GetColorSettings() const override
Returns a pointer to the active color theme settings.
COLOR4D GetColor(int aLayer) const
virtual void SetValue(int aValue)
Set new value (in Internal Units) for the text field, taking care of units conversion.
Color settings are a bit different than most of the settings objects in that there can be more than o...
void SetSwatchBackground(const KIGFX::COLOR4D &aBackground)
Set the swatch background color.
A color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:103

References EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::align_to_grid, EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::allow_rejustify, EESCHEMA_SETTINGS::DRAWING::auto_start_wires, EESCHEMA_SETTINGS::DRAWING::default_repeat_offset_x, EESCHEMA_SETTINGS::DRAWING::default_repeat_offset_y, EESCHEMA_SETTINGS::DRAWING::default_sheet_background_color, EESCHEMA_SETTINGS::DRAWING::default_sheet_border_color, EESCHEMA_SETTINGS::INPUT::drag_is_move, SCH_BASE_FRAME::eeconfig(), EESCHEMA_SETTINGS::AUTOPLACE_FIELDS::enable, EESCHEMA_SETTINGS::APPEARANCE::footprint_preview, COLOR_SETTINGS::GetColor(), SCH_BASE_FRAME::GetColorSettings(), EESCHEMA_SETTINGS::DRAWING::hv_lines_only, LAYER_SCHEMATIC_BACKGROUND, EESCHEMA_SETTINGS::m_Appearance, EESCHEMA_SETTINGS::m_AutoplaceFields, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_backgroundColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_borderColorSwatch, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbAutoStartWires, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbPinSelectionOpt, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceAlign, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceFields, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceJustify, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkHVOrientation, EESCHEMA_SETTINGS::m_Drawing, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_footprintPreview, m_frame, m_hPitch, EESCHEMA_SETTINGS::m_Input, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_mouseDragIsDrag, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_navigatorStaysOpen, EESCHEMA_SETTINGS::m_Selection, PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_spinLabelRepeatStep, m_vPitch, EESCHEMA_SETTINGS::APPEARANCE::navigator_stays_open, EESCHEMA_SETTINGS::DRAWING::repeat_label_increment, EESCHEMA_SETTINGS::SELECTION::select_pin_selects_symbol, COLOR_SWATCH::SetSwatchBackground(), COLOR_SWATCH::SetSwatchColor(), and UNIT_BINDER::SetValue().

Member Data Documentation

◆ m_backgroundColorLabel

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_backgroundColorLabel
protectedinherited

◆ m_backgroundColorSwatch

COLOR_SWATCH* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_backgroundColorSwatch
protectedinherited

◆ m_borderColorLabel

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_borderColorLabel
protectedinherited

◆ m_borderColorSwatch

◆ m_cbAutoStartWires

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbAutoStartWires
protectedinherited

◆ m_cbPinSelectionOpt

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_cbPinSelectionOpt
protectedinherited

◆ m_checkAutoplaceAlign

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceAlign
protectedinherited

◆ m_checkAutoplaceFields

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceFields
protectedinherited

◆ m_checkAutoplaceJustify

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkAutoplaceJustify
protectedinherited

◆ m_checkHVOrientation

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_checkHVOrientation
protectedinherited

◆ m_footprintPreview

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_footprintPreview
protectedinherited

◆ m_frame

SCH_EDIT_FRAME* PANEL_EESCHEMA_EDITING_OPTIONS::m_frame
private

◆ m_hPitch

UNIT_BINDER PANEL_EESCHEMA_EDITING_OPTIONS::m_hPitch
private

◆ m_hPitchCtrl

wxTextCtrl* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_hPitchCtrl
protectedinherited

◆ m_hPitchLabel

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_hPitchLabel
protectedinherited

◆ m_hPitchUnits

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_hPitchUnits
protectedinherited

◆ m_labelIncrementLabel

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_labelIncrementLabel
protectedinherited

◆ m_leftClickCmdsBook

wxSimplebook* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_leftClickCmdsBook
protectedinherited

◆ m_mouseDragIsDrag

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_mouseDragIsDrag
protectedinherited

◆ m_navigatorStaysOpen

wxCheckBox* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_navigatorStaysOpen
protectedinherited

◆ m_pageMac

wxPanel* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_pageMac
protectedinherited

◆ m_pageWinLin

wxPanel* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_pageWinLin
protectedinherited

◆ m_spinLabelRepeatStep

wxSpinCtrl* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_spinLabelRepeatStep
protectedinherited

◆ m_staticline1

wxStaticLine* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticline1
protectedinherited

◆ m_staticline2

wxStaticLine* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticline2
protectedinherited

◆ m_staticText10

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText10
protectedinherited

◆ m_staticText101

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText101
protectedinherited

◆ m_staticText11

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText11
protectedinherited

◆ m_staticText12

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText12
protectedinherited

◆ m_staticText13

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText13
protectedinherited

◆ m_staticText131

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText131
protectedinherited

◆ m_staticText14

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText14
protectedinherited

◆ m_staticText141

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText141
protectedinherited

◆ m_staticText15

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText15
protectedinherited

◆ m_staticText151

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText151
protectedinherited

◆ m_staticText16

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText16
protectedinherited

◆ m_staticText161

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText161
protectedinherited

◆ m_staticText8

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText8
protectedinherited

◆ m_staticText81

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText81
protectedinherited

◆ m_staticText9

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText9
protectedinherited

◆ m_staticText91

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_staticText91
protectedinherited

◆ m_vPitch

UNIT_BINDER PANEL_EESCHEMA_EDITING_OPTIONS::m_vPitch
private

◆ m_vPitchCtrl

wxTextCtrl* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_vPitchCtrl
protectedinherited

◆ m_vPitchLabel

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_vPitchLabel
protectedinherited

◆ m_vPitchUnits

wxStaticText* PANEL_EESCHEMA_EDITING_OPTIONS_BASE::m_vPitchUnits
protectedinherited

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