KiCad PCB EDA Suite
PANEL_MODEDIT_SETTINGS Class Reference

#include <panel_modedit_settings.h>

Inheritance diagram for PANEL_MODEDIT_SETTINGS:
PANEL_MODEDIT_SETTINGS_BASE

Public Member Functions

 PANEL_MODEDIT_SETTINGS (FOOTPRINT_EDIT_FRAME *aFrame, PAGED_DIALOG *aWindow)
 

Protected Attributes

wxRadioBox * m_PolarDisplay
 
wxRadioBox * m_UnitsSelection
 
wxCheckBox * m_MagneticPads
 
wxCheckBox * m_Segments_45_Only_Ctrl
 

Private Member Functions

bool TransferDataToWindow () override
 
bool TransferDataFromWindow () override
 

Private Attributes

FOOTPRINT_EDIT_FRAMEm_frame
 

Detailed Description

Definition at line 29 of file panel_modedit_settings.h.

Constructor & Destructor Documentation

◆ PANEL_MODEDIT_SETTINGS()

PANEL_MODEDIT_SETTINGS::PANEL_MODEDIT_SETTINGS ( FOOTPRINT_EDIT_FRAME aFrame,
PAGED_DIALOG aWindow 
)

Definition at line 35 of file panel_modedit_settings.cpp.

36  :
37  PANEL_MODEDIT_SETTINGS_BASE( aParent->GetTreebook() ),
38  m_frame( aFrame )
39 {}
PANEL_MODEDIT_SETTINGS_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL)
FOOTPRINT_EDIT_FRAME * m_frame

Member Function Documentation

◆ TransferDataFromWindow()

bool PANEL_MODEDIT_SETTINGS::TransferDataFromWindow ( )
overrideprivate

Definition at line 57 of file panel_modedit_settings.cpp.

58 {
59  // Display options
60  m_frame->SetShowPolarCoords( m_PolarDisplay->GetSelection() != 0 );
63 
64  // Editing options
68 
69  return true;
70 }
void SetShowPolarCoords(bool aShow)
bool m_Use45DegreeGraphicSegments
FOOTPRINT_EDIT_FRAME * m_frame
MAGNETIC_OPTIONS pads
PCBNEW_SETTINGS & Settings()
MAGNETIC_SETTINGS * GetMagneticItemsSettings() override
void SetUserUnits(EDA_UNITS aUnits)

References CAPTURE_ALWAYS, FOOTPRINT_EDIT_FRAME::GetMagneticItemsSettings(), INCHES, m_frame, PANEL_MODEDIT_SETTINGS_BASE::m_MagneticPads, PANEL_MODEDIT_SETTINGS_BASE::m_PolarDisplay, PANEL_MODEDIT_SETTINGS_BASE::m_Segments_45_Only_Ctrl, PANEL_MODEDIT_SETTINGS_BASE::m_UnitsSelection, PCBNEW_SETTINGS::m_Use45DegreeGraphicSegments, MILLIMETRES, NO_EFFECT, MAGNETIC_SETTINGS::pads, EDA_DRAW_FRAME::SetShowPolarCoords(), PCB_BASE_FRAME::Settings(), and EDA_BASE_FRAME::SetUserUnits().

◆ TransferDataToWindow()

bool PANEL_MODEDIT_SETTINGS::TransferDataToWindow ( )
overrideprivate

Definition at line 42 of file panel_modedit_settings.cpp.

43 {
44  // Display options
45  m_PolarDisplay->SetSelection( m_frame->GetShowPolarCoords() ? 1 : 0 );
46  m_UnitsSelection->SetSelection( m_frame->GetUserUnits() == EDA_UNITS::INCHES ? 0 : 1 );
47 
48  // Editing options
50  m_MagneticPads->SetValue(
52 
53  return true;
54 }
bool m_Use45DegreeGraphicSegments
FOOTPRINT_EDIT_FRAME * m_frame
bool GetShowPolarCoords() const
For those frames that support polar coordinates.
MAGNETIC_OPTIONS pads
PCBNEW_SETTINGS & Settings()
MAGNETIC_SETTINGS * GetMagneticItemsSettings() override
EDA_UNITS GetUserUnits() const
Return the user units currently in use.

References CAPTURE_ALWAYS, FOOTPRINT_EDIT_FRAME::GetMagneticItemsSettings(), EDA_DRAW_FRAME::GetShowPolarCoords(), EDA_BASE_FRAME::GetUserUnits(), INCHES, m_frame, PANEL_MODEDIT_SETTINGS_BASE::m_MagneticPads, PANEL_MODEDIT_SETTINGS_BASE::m_PolarDisplay, PANEL_MODEDIT_SETTINGS_BASE::m_Segments_45_Only_Ctrl, PANEL_MODEDIT_SETTINGS_BASE::m_UnitsSelection, PCBNEW_SETTINGS::m_Use45DegreeGraphicSegments, MAGNETIC_SETTINGS::pads, and PCB_BASE_FRAME::Settings().

Member Data Documentation

◆ m_frame

FOOTPRINT_EDIT_FRAME* PANEL_MODEDIT_SETTINGS::m_frame
private

Definition at line 31 of file panel_modedit_settings.h.

Referenced by TransferDataFromWindow(), and TransferDataToWindow().

◆ m_MagneticPads

wxCheckBox* PANEL_MODEDIT_SETTINGS_BASE::m_MagneticPads
protectedinherited

◆ m_PolarDisplay

wxRadioBox* PANEL_MODEDIT_SETTINGS_BASE::m_PolarDisplay
protectedinherited

◆ m_Segments_45_Only_Ctrl

wxCheckBox* PANEL_MODEDIT_SETTINGS_BASE::m_Segments_45_Only_Ctrl
protectedinherited

◆ m_UnitsSelection

wxRadioBox* PANEL_MODEDIT_SETTINGS_BASE::m_UnitsSelection
protectedinherited

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