KiCad PCB EDA Suite
PANEL_EESCHEMA_DISPLAY_OPTIONS Class Reference

#include <panel_eeschema_display_options.h>

Inheritance diagram for PANEL_EESCHEMA_DISPLAY_OPTIONS:
PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE

Public Member Functions

 PANEL_EESCHEMA_DISPLAY_OPTIONS (SCH_EDIT_FRAME *aFrame, wxWindow *aWindow)
 

Protected Attributes

wxBoxSizer * m_galOptionsSizer
 
wxCheckBox * m_checkShowHiddenPins
 
wxCheckBox * m_checkShowHiddenFields
 
wxCheckBox * m_checkPageLimits
 
wxCheckBox * m_checkSelTextBox
 
wxCheckBox * m_checkSelDrawChildItems
 
wxCheckBox * m_checkSelFillShapes
 
wxStaticText * m_selWidthLabel
 
wxSpinCtrlDouble * m_selWidthCtrl
 
wxStaticText * m_highlightColorNote
 
wxCheckBox * m_checkCrossProbeCenter
 
wxCheckBox * m_checkCrossProbeZoom
 
wxCheckBox * m_checkCrossProbeAutoHighlight
 

Private Member Functions

bool TransferDataToWindow () override
 
bool TransferDataFromWindow () override
 

Private Attributes

SCH_EDIT_FRAMEm_frame
 
GAL_OPTIONS_PANELm_galOptsPanel
 

Detailed Description

Definition at line 30 of file panel_eeschema_display_options.h.

Constructor & Destructor Documentation

◆ PANEL_EESCHEMA_DISPLAY_OPTIONS()

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

Definition at line 34 of file panel_eeschema_display_options.cpp.

35  :
37  m_frame( aFrame )
38 {
40  m_galOptsPanel = new GAL_OPTIONS_PANEL( this, galOptions );
41 
42  m_galOptionsSizer->Add( m_galOptsPanel, 1, wxEXPAND, 0 );
43 
44  wxFont infoFont = wxSystemSettings::GetFont( wxSYS_DEFAULT_GUI_FONT );
45  infoFont.SetSymbolicSize( wxFONTSIZE_SMALL );
46  m_highlightColorNote->SetFont( infoFont );
47 }
KIGFX::GAL_DISPLAY_OPTIONS & GetGalDisplayOptions()
Return a reference to the gal rendering options used by GAL for rendering.
PANEL_EESCHEMA_DISPLAY_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)

References EDA_DRAW_FRAME::GetGalDisplayOptions(), m_frame, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_galOptionsSizer, m_galOptsPanel, and PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_highlightColorNote.

Member Function Documentation

◆ TransferDataFromWindow()

bool PANEL_EESCHEMA_DISPLAY_OPTIONS::TransferDataFromWindow ( )
overrideprivate

Definition at line 73 of file panel_eeschema_display_options.cpp.

74 {
76 
80 
81  cfg->m_Selection.text_as_box = m_checkSelTextBox->GetValue();
83  cfg->m_Selection.fill_shapes = m_checkSelFillShapes->GetValue();
84  cfg->m_Selection.thickness = KiROUND( m_selWidthCtrl->GetValue() );
85 
89 
90  // Update canvas
97 
99 
100  return true;
101 }
KIGFX::SCH_VIEW * GetView() const override
Function GetView() Returns a pointer to the VIEW instance used in the panel.
void UpdateAllItems(int aUpdateFlags)
Updates all items in the view according to the given flags.
Definition: view.cpp:1435
KIGFX::SCH_RENDER_SETTINGS * GetRenderSettings()
EESCHEMA_SETTINGS * eeconfig() const
Item is being added to the view.
Definition: view_item.h:62
SCH_DRAW_PANEL * GetCanvas() const override
Return a pointer to GAL-based canvas of given EDA draw frame.
virtual void Refresh(bool aEraseBackground=true, const wxRect *aRect=NULL) override
Update the board display after modifying it by a python script (note: it is automatically called by a...
bool zoom_to_fit
Zoom to fit items (ignored if center_on_items is off)
Definition: app_settings.h:33
bool auto_highlight
Automatically turn on highlight mode in the target frame.
Definition: app_settings.h:34
constexpr ret_type KiROUND(fp_type v)
Round a floating point number to an integer using "round halfway cases away from zero".
Definition: util.h:68
CROSS_PROBING_SETTINGS m_CrossProbing
Definition: app_settings.h:157
bool center_on_items
Automatically pan to cross-probed items.
Definition: app_settings.h:32
void MarkDirty()
Function MarkDirty() Forces redraw of view on the next rendering.
Definition: view.h:599
void SetShowPageLimits(bool aDraw)
bool TransferDataFromWindow() override
Read the options set in the UI into the given options object.

References CROSS_PROBING_SETTINGS::auto_highlight, CROSS_PROBING_SETTINGS::center_on_items, EESCHEMA_SETTINGS::SELECTION::draw_selected_children, SCH_BASE_FRAME::eeconfig(), EESCHEMA_SETTINGS::SELECTION::fill_shapes, SCH_BASE_FRAME::GetCanvas(), SCH_BASE_FRAME::GetRenderSettings(), SCH_DRAW_PANEL::GetView(), KiROUND(), EESCHEMA_SETTINGS::m_Appearance, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeAutoHighlight, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeCenter, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeZoom, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkPageLimits, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelDrawChildItems, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelFillShapes, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelTextBox, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenFields, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenPins, APP_SETTINGS_BASE::m_CrossProbing, m_frame, m_galOptsPanel, EESCHEMA_SETTINGS::m_Selection, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_selWidthCtrl, KIGFX::SCH_RENDER_SETTINGS::m_ShowHiddenPins, KIGFX::SCH_RENDER_SETTINGS::m_ShowHiddenText, KIGFX::VIEW::MarkDirty(), EDA_DRAW_PANEL_GAL::Refresh(), KIGFX::REPAINT, KIGFX::RENDER_SETTINGS::SetShowPageLimits(), EESCHEMA_SETTINGS::APPEARANCE::show_hidden_fields, EESCHEMA_SETTINGS::APPEARANCE::show_hidden_pins, EESCHEMA_SETTINGS::APPEARANCE::show_page_limits, EESCHEMA_SETTINGS::SELECTION::text_as_box, EESCHEMA_SETTINGS::SELECTION::thickness, GAL_OPTIONS_PANEL::TransferDataFromWindow(), KIGFX::VIEW::UpdateAllItems(), and CROSS_PROBING_SETTINGS::zoom_to_fit.

◆ TransferDataToWindow()

bool PANEL_EESCHEMA_DISPLAY_OPTIONS::TransferDataToWindow ( )
overrideprivate

Definition at line 50 of file panel_eeschema_display_options.cpp.

51 {
53 
57 
58  m_checkSelTextBox->SetValue( cfg->m_Selection.text_as_box );
61  m_selWidthCtrl->SetValue( cfg->m_Selection.thickness );
62 
66 
68 
69  return true;
70 }
EESCHEMA_SETTINGS * eeconfig() const
bool TransferDataToWindow() override
Load the panel controls from the given opt.
bool zoom_to_fit
Zoom to fit items (ignored if center_on_items is off)
Definition: app_settings.h:33
bool auto_highlight
Automatically turn on highlight mode in the target frame.
Definition: app_settings.h:34
CROSS_PROBING_SETTINGS m_CrossProbing
Definition: app_settings.h:157
bool center_on_items
Automatically pan to cross-probed items.
Definition: app_settings.h:32

References CROSS_PROBING_SETTINGS::auto_highlight, CROSS_PROBING_SETTINGS::center_on_items, EESCHEMA_SETTINGS::SELECTION::draw_selected_children, SCH_BASE_FRAME::eeconfig(), EESCHEMA_SETTINGS::SELECTION::fill_shapes, EESCHEMA_SETTINGS::m_Appearance, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeAutoHighlight, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeCenter, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeZoom, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkPageLimits, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelDrawChildItems, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelFillShapes, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelTextBox, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenFields, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenPins, APP_SETTINGS_BASE::m_CrossProbing, m_frame, m_galOptsPanel, EESCHEMA_SETTINGS::m_Selection, PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_selWidthCtrl, EESCHEMA_SETTINGS::APPEARANCE::show_hidden_fields, EESCHEMA_SETTINGS::APPEARANCE::show_hidden_pins, EESCHEMA_SETTINGS::APPEARANCE::show_page_limits, EESCHEMA_SETTINGS::SELECTION::text_as_box, EESCHEMA_SETTINGS::SELECTION::thickness, GAL_OPTIONS_PANEL::TransferDataToWindow(), and CROSS_PROBING_SETTINGS::zoom_to_fit.

Member Data Documentation

◆ m_checkCrossProbeAutoHighlight

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeAutoHighlight
protectedinherited

◆ m_checkCrossProbeCenter

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeCenter
protectedinherited

◆ m_checkCrossProbeZoom

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkCrossProbeZoom
protectedinherited

◆ m_checkPageLimits

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkPageLimits
protectedinherited

◆ m_checkSelDrawChildItems

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelDrawChildItems
protectedinherited

◆ m_checkSelFillShapes

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelFillShapes
protectedinherited

◆ m_checkSelTextBox

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkSelTextBox
protectedinherited

◆ m_checkShowHiddenFields

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenFields
protectedinherited

◆ m_checkShowHiddenPins

wxCheckBox* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_checkShowHiddenPins
protectedinherited

◆ m_frame

SCH_EDIT_FRAME* PANEL_EESCHEMA_DISPLAY_OPTIONS::m_frame
private

◆ m_galOptionsSizer

wxBoxSizer* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_galOptionsSizer
protectedinherited

◆ m_galOptsPanel

GAL_OPTIONS_PANEL* PANEL_EESCHEMA_DISPLAY_OPTIONS::m_galOptsPanel
private

◆ m_highlightColorNote

wxStaticText* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_highlightColorNote
protectedinherited

◆ m_selWidthCtrl

wxSpinCtrlDouble* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_selWidthCtrl
protectedinherited

◆ m_selWidthLabel

wxStaticText* PANEL_EESCHEMA_DISPLAY_OPTIONS_BASE::m_selWidthLabel
protectedinherited

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