37#define SELECT_COLNUM 0
39#define LAYERNAME_COLNUM 2
84 LSET aNotAllowedLayersMask,
bool aHideCheckBoxes =
false );
93 void OnMouseMove( wxUpdateUIEvent& aEvent )
override;
110 LSET aNotAllowedLayersMask,
111 bool aHideCheckBoxes ) :
127 if( aHideCheckBoxes )
136 GetSizer()->SetSizeHints(
this );
184 if( event.GetKeyCode() == WXK_ESCAPE )
204 wxColour
color( wxColour::AlphaBlend( fg.Red(), bg.Red(), fg.Alpha() / 255.0 ),
205 wxColour::AlphaBlend( fg.Green(), bg.Green(), fg.Alpha() / 255.0 ),
206 wxColour::AlphaBlend( fg.Blue(), bg.Blue(), fg.Alpha() / 255.0 ) );
276 wxPoint aDlgPosition )
280 if( aDlgPosition != wxDefaultPosition )
282 wxSize dlgSize = dlg.GetSize();
283 aDlgPosition.x -= dlgSize.x/2;
284 aDlgPosition.y -= dlgSize.y/2;
288 if( dlg.ShowModal() != wxID_CANCEL )
334 if( dlg.ShowModal() == wxID_OK )
367 GetSizer()->SetSizeHints(
this );
386 wxColour
color( wxColour::AlphaBlend( fg.Red(), bg.Red(), fg.Alpha() / 255.0 ),
387 wxColour::AlphaBlend( fg.Green(), bg.Green(), fg.Alpha() / 255.0 ),
388 wxColour::AlphaBlend( fg.Blue(), bg.Blue(), fg.Alpha() / 255.0 ) );
429 int row =
event.GetRow();
444 int row =
event.GetRow();
Information pertinent to a Pcbnew printed circuit board.
LSET GetEnabledLayers() const
A proxy function that calls the corresponding function in m_BoardSettings.
bool IsLayerEnabled(PCB_LAYER_ID aLayer) const
A proxy function that calls the correspondent function in m_BoardSettings tests whether a given layer...
const wxString GetLayerName(PCB_LAYER_ID aLayer) const
Return the name of a aLayer.
COLOR4D GetColor(int aLayer) const
Class DIALOG_COPPER_LAYER_PAIR_SELECTION_BASE.
wxGrid * m_rightGridLayers
wxGrid * m_leftGridLayers
Class DIALOG_LAYER_SELECTION_BASE.
wxGrid * m_leftGridLayers
wxGrid * m_rightGridLayers
bool IsQuasiModal() const
void EndQuasiModal(int retCode)
void SetPosition(const wxPoint &aNewPosition)
Force the position of the dialog to a new position.
A color representation with 4 components: red, green, blue, alpha.
wxColour ToColour() const
Base class to build a layer list.
LSEQ is a sequence (and therefore also a set) of PCB_LAYER_IDs.
LSET is a set of PCB_LAYER_IDs.
Base PCB main window class for Pcbnew, Gerbview, and CvPcb footprint viewer.
PCB_LAYER_ID SelectOneLayer(PCB_LAYER_ID aDefaultLayer, LSET aNotAllowedLayersMask=LSET(), wxPoint aDlgPosition=wxDefaultPosition)
Show the dialog box for a layer selection.
PCB_SCREEN * GetScreen() const override
Return a pointer to a BASE_SCREEN or one of its derivatives.
virtual COLOR_SETTINGS * GetColorSettings(bool aForceRefresh=false) const override
Helper to retrieve the current color settings.
bool isLayerEnabled(int aLayer) const override
COLOR4D getLayerColor(int aLayer) const override
PCB_LAYER_SELECTOR(PCB_BASE_FRAME *aFrame)
wxString getLayerName(int aLayer) const override
Display a PCB layers list in a dialog to select one layer from this list.
void OnLeftGridCellClick(wxGridEvent &aEvent) override
void OnRightGridCellClick(wxGridEvent &aEvent) override
void onCharHook(wxKeyEvent &event)
~PCB_ONE_LAYER_SELECTOR()
std::vector< PCB_LAYER_ID > m_layersIdLeftColumn
LSET m_notAllowedLayersMask
PCB_ONE_LAYER_SELECTOR(PCB_BASE_FRAME *aParent, BOARD *aBrd, PCB_LAYER_ID aDefaultLayer, LSET aNotAllowedLayersMask, bool aHideCheckBoxes=false)
std::vector< PCB_LAYER_ID > m_layersIdRightColumn
void OnMouseMove(wxUpdateUIEvent &aEvent) override
PCB_LAYER_ID m_layerSelected
PCB_LAYER_ID m_Route_Layer_TOP
PCB_LAYER_ID m_Route_Layer_BOTTOM
Display a pair PCB copper layers list in a dialog to select a layer pair from these lists.
std::vector< PCB_LAYER_ID > m_layersId
void GetLayerPair(PCB_LAYER_ID &aFrontLayer, PCB_LAYER_ID &aBackLayer)
PCB_LAYER_ID m_frontLayer
void OnRightGridCellClick(wxGridEvent &event) override
void OnLeftGridCellClick(wxGridEvent &event) override
SELECT_COPPER_LAYERS_PAIR_DIALOG(PCB_BASE_FRAME *aParent, BOARD *aPcb, PCB_LAYER_ID aFrontLayer, PCB_LAYER_ID aBackLayer)
void DisplayInfoMessage(wxWindow *aParent, const wxString &aMessage, const wxString &aExtraInfo)
Display an informational message box with aMessage.
This file is part of the common library.
bool IsCopperLayer(int aLayerId)
Tests whether a layer is a copper layer.
@ LAYER_PCB_BACKGROUND
PCB background color.
PCB_LAYER_ID
A quick note on layer IDs:
PCB_LAYER_ID ToLAYER_ID(int aLayer)