diff --git a/common/dialogs/dialog_color_picker.cpp b/common/dialogs/dialog_color_picker.cpp index 41ec8f051f..26586a78d9 100644 --- a/common/dialogs/dialog_color_picker.cpp +++ b/common/dialogs/dialog_color_picker.cpp @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2018-2022 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 2018-2024 KiCad Developers, see AUTHORS.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 @@ -28,6 +28,7 @@ #include #define ALPHA_MAX 100 // the max value returned by the alpha (opacity) slider +#define SLOPE_AXIS ( bmsize.y / 5.28 ) // was 50 at 264 size using KIGFX::COLOR4D; @@ -52,13 +53,17 @@ DIALOG_COLOR_PICKER::DIALOG_COLOR_PICKER( wxWindow* aParent, const COLOR4D& aCur m_allowOpacityCtrl = aAllowOpacityControl; m_previousColor4D = aCurrentColor; m_newColor4D = aCurrentColor; - m_cursorsSize = 8; // Size of square cursors drawn on color bitmaps m_newColor4D.ToHSV( m_hue, m_sat, m_val, true ); m_bitmapRGB = nullptr; m_bitmapHSV = nullptr; m_selectedCursor = nullptr; m_defaultColor = aDefaultColor; + updateHandleSize(); + + m_OldColorRect->SetMinSize( FromDIP( wxSize( 24, 24 ) ) ); + m_NewColorRect->SetMinSize( FromDIP( wxSize( 24, 24 ) ) ); + if( !m_allowOpacityCtrl ) { m_SizerTransparency->Show( false ); @@ -121,16 +126,15 @@ void DIALOG_COLOR_PICKER::updatePreview( wxStaticBitmap* aStaticBitmap, COLOR4D& wxBitmap newBm = COLOR_SWATCH::MakeBitmap( aColor4D, COLOR4D::WHITE, aStaticBitmap->GetSize(), ConvertDialogToPixels( CHECKERBOARD_SIZE_DU ), aStaticBitmap->GetParent()->GetBackgroundColour() ); + + newBm.SetScaleFactor( GetDPIScaleFactor() ); aStaticBitmap->SetBitmap( newBm ); } bool DIALOG_COLOR_PICKER::TransferDataToWindow() { - // Draw all bitmaps, with colors according to the color 4D - updatePreview( m_OldColorRect, m_previousColor4D ); SetEditVals( ALL_CHANGED, false ); - drawAll(); // Configure the spin control sizes configureSpinCtrl( m_spinCtrlGreen ); @@ -144,6 +148,10 @@ bool DIALOG_COLOR_PICKER::TransferDataToWindow() finishDialogSettings(); + // Draw all bitmaps, with colors according to the color 4D + updatePreview( m_OldColorRect, m_previousColor4D ); + drawAll(); + return true; } @@ -171,6 +179,8 @@ void DIALOG_COLOR_PICKER::initDefinedColors( CUSTOM_COLORS_LIST* aPredefinedColo { wxBitmap bm = COLOR_SWATCH::MakeBitmap( aColor, COLOR4D::WHITE, swatchSize, checkerboardSize, checkboardBackground ); + + bm.SetScaleFactor( GetDPIScaleFactor() ); wxStaticBitmap* swatch = new wxStaticBitmap( m_panelDefinedColors, aId, bm ); m_fgridColor->Add( swatch, 0, wxALIGN_CENTER_VERTICAL, 5 ); @@ -245,7 +255,6 @@ void DIALOG_COLOR_PICKER::createRGBBitmap() // Red blue area in X Z 3d axis double inc = 255.0 / half_size; - #define SLOPE_AXIS 50.0 double slope = SLOPE_AXIS/half_size; color.g = 0.0; @@ -315,6 +324,7 @@ void DIALOG_COLOR_PICKER::createRGBBitmap() delete m_bitmapRGB; m_bitmapRGB = new wxBitmap( img, 24 ); + m_bitmapRGB->SetScaleFactor( m_RgbBitmap->GetDPIScaleFactor() ); m_RgbBitmap->SetBitmap( *m_bitmapRGB ); } @@ -379,6 +389,7 @@ void DIALOG_COLOR_PICKER::createHSVBitmap() delete m_bitmapHSV; m_bitmapHSV = new wxBitmap( img, 24 ); + m_bitmapHSV->SetScaleFactor( m_HsvBitmap->GetDPIScaleFactor() ); m_HsvBitmap->SetBitmap( *m_bitmapHSV ); } @@ -413,8 +424,7 @@ void DIALOG_COLOR_PICKER::drawRGBPalette() bitmapDC.SetBrush( brush ); int half_csize = m_cursorsSize / 2; - #define SLOPE_AXIS 50.0 - double slope = SLOPE_AXIS / half_size; + double slope = SLOPE_AXIS / ( half_size ); // Red axis cursor (Z 3Daxis): m_cursorBitmapRed.x = 0; @@ -539,8 +549,15 @@ void DIALOG_COLOR_PICKER::SetEditVals( CHANGED_COLOR aChanged, bool aCheckTransp } +void DIALOG_COLOR_PICKER::updateHandleSize() +{ + m_cursorsSize = FromDIP( 8 ); // Size of square cursors drawn on color bitmaps +} + + void DIALOG_COLOR_PICKER::drawAll() { + updateHandleSize(); m_NewColorRect->Freeze(); // Avoid flicker m_HsvBitmap->Freeze(); m_RgbBitmap->Freeze(); @@ -699,6 +716,14 @@ void DIALOG_COLOR_PICKER::onHSVMouseDrag( wxMouseEvent& event ) } +void DIALOG_COLOR_PICKER::onSize( wxSizeEvent& event ) +{ + drawAll(); + + event.Skip(); +} + + void DIALOG_COLOR_PICKER::OnColorValueText( wxCommandEvent& event ) { if( m_newColor4D.SetFromHexString( m_colorValue->GetValue() ) ) diff --git a/common/dialogs/dialog_color_picker_base.cpp b/common/dialogs/dialog_color_picker_base.cpp index b40402c780..cd59e03724 100644 --- a/common/dialogs/dialog_color_picker_base.cpp +++ b/common/dialogs/dialog_color_picker_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version 3.10.1-0-g8feb16b) +// C++ code generated with wxFormBuilder (version 4.1.0-0-g733bf3d) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -33,7 +33,10 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID m_RgbBitmap = new wxStaticBitmap( sbSizerViewRGB->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( 264,264 ), 0 ); m_RgbBitmap->SetMinSize( wxSize( 264,264 ) ); - sbSizerViewRGB->Add( m_RgbBitmap, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); + sbSizerViewRGB->Add( m_RgbBitmap, 0, wxALIGN_CENTER_HORIZONTAL|wxALL|wxEXPAND|wxSHAPED, 5 ); + + + sbSizerViewRGB->Add( 0, 0, 1, wxEXPAND, 5 ); wxFlexGridSizer* fgSizerRGB; fgSizerRGB = new wxFlexGridSizer( 0, 3, 0, 0 ); @@ -68,18 +71,18 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID sbSizerViewRGB->Add( fgSizerRGB, 0, wxEXPAND, 5 ); - bSizerPanels->Add( sbSizerViewRGB, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); + bSizerPanels->Add( sbSizerViewRGB, 1, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 ); wxStaticBoxSizer* sbSizerViewHSV; - sbSizerViewHSV = new wxStaticBoxSizer( new wxStaticBox( m_panelFreeColors, wxID_ANY, _("HSV") ), wxHORIZONTAL ); - - wxBoxSizer* bSizer10; - bSizer10 = new wxBoxSizer( wxVERTICAL ); + sbSizerViewHSV = new wxStaticBoxSizer( new wxStaticBox( m_panelFreeColors, wxID_ANY, _("HSV") ), wxVERTICAL ); m_HsvBitmap = new wxStaticBitmap( sbSizerViewHSV->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( 264,264 ), 0 ); m_HsvBitmap->SetMinSize( wxSize( 264,264 ) ); - bSizer10->Add( m_HsvBitmap, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); + sbSizerViewHSV->Add( m_HsvBitmap, 0, wxALIGN_CENTER_HORIZONTAL|wxALL|wxEXPAND|wxSHAPED, 5 ); + + + sbSizerViewHSV->Add( 0, 0, 1, wxEXPAND, 5 ); wxFlexGridSizer* fgSizerHSV; fgSizerHSV = new wxFlexGridSizer( 0, 2, 0, 0 ); @@ -103,26 +106,23 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID fgSizerHSV->Add( m_spinCtrlSaturation, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - bSizer10->Add( fgSizerHSV, 0, wxEXPAND, 5 ); + sbSizerViewHSV->Add( fgSizerHSV, 0, wxEXPAND, 5 ); - sbSizerViewHSV->Add( bSizer10, 0, wxEXPAND, 5 ); + bSizerPanels->Add( sbSizerViewHSV, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); wxBoxSizer* bSizerBright; bSizerBright = new wxBoxSizer( wxVERTICAL ); - m_staticTextBright = new wxStaticText( sbSizerViewHSV->GetStaticBox(), wxID_ANY, _("Value:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextBright = new wxStaticText( m_panelFreeColors, wxID_ANY, _("Value:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextBright->Wrap( -1 ); bSizerBright->Add( m_staticTextBright, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 ); - m_sliderBrightness = new wxSlider( sbSizerViewHSV->GetStaticBox(), wxID_ANY, 255, 0, 255, wxDefaultPosition, wxDefaultSize, wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL ); + m_sliderBrightness = new wxSlider( m_panelFreeColors, wxID_ANY, 255, 0, 255, wxDefaultPosition, wxDefaultSize, wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL ); bSizerBright->Add( m_sliderBrightness, 1, wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxTOP, 5 ); - sbSizerViewHSV->Add( bSizerBright, 0, wxEXPAND, 5 ); - - - bSizerPanels->Add( sbSizerViewHSV, 0, wxEXPAND|wxBOTTOM|wxRIGHT, 5 ); + bSizerPanels->Add( bSizerBright, 0, wxALL|wxEXPAND, 5 ); bSizerUpperFreeColors->Add( bSizerPanels, 1, wxEXPAND, 5 ); @@ -153,7 +153,7 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID m_SizerDefinedColors->Fit( m_panelDefinedColors ); m_notebook->AddPage( m_panelDefinedColors, _("Defined Colors"), false ); - bSizerUpperMain->Add( m_notebook, 0, wxEXPAND | wxALL, 5 ); + bSizerUpperMain->Add( m_notebook, 1, wxEXPAND | wxALL, 5 ); m_SizerTransparency = new wxBoxSizer( wxVERTICAL ); @@ -171,35 +171,29 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID bSizerUpperMain->Add( m_SizerTransparency, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 ); - bSizerUpperMain->Add( 0, 0, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 ); - - - bSizerMain->Add( bSizerUpperMain, 0, wxEXPAND, 5 ); + bSizerMain->Add( bSizerUpperMain, 1, wxEXPAND, 5 ); wxBoxSizer* bButtonsSizer; bButtonsSizer = new wxBoxSizer( wxHORIZONTAL ); m_staticTextOldColor = new wxStaticText( this, wxID_ANY, _("Preview (old/new):"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextOldColor->Wrap( -1 ); - bButtonsSizer->Add( m_staticTextOldColor, 0, wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 ); + bButtonsSizer->Add( m_staticTextOldColor, 0, wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT, 5 ); m_OldColorRect = new wxStaticBitmap( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), 0 ); m_OldColorRect->SetMinSize( wxSize( 24,24 ) ); - bButtonsSizer->Add( m_OldColorRect, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); + bButtonsSizer->Add( m_OldColorRect, 0, wxALIGN_CENTER_VERTICAL|wxSHAPED, 5 ); m_NewColorRect = new wxStaticBitmap( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), 0 ); m_NewColorRect->SetMinSize( wxSize( 24,24 ) ); - bButtonsSizer->Add( m_NewColorRect, 0, wxALIGN_CENTER_VERTICAL, 5 ); - - - bButtonsSizer->Add( 10, 0, 0, wxEXPAND, 5 ); + bButtonsSizer->Add( m_NewColorRect, 0, wxALIGN_CENTER_VERTICAL|wxSHAPED, 5 ); m_colorValue = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); m_colorValue->SetMinSize( wxSize( 176,-1 ) ); - bButtonsSizer->Add( m_colorValue, 0, wxALIGN_CENTER_VERTICAL, 5 ); + bButtonsSizer->Add( m_colorValue, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 ); bButtonsSizer->Add( 20, 0, 0, wxEXPAND, 5 ); @@ -217,7 +211,7 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID bButtonsSizer->Add( m_sdbSizer, 1, wxALL, 5 ); - bSizerMain->Add( bButtonsSizer, 1, wxEXPAND|wxLEFT, 10 ); + bSizerMain->Add( bButtonsSizer, 0, wxEXPAND|wxLEFT, 10 ); this->SetSizer( bSizerMain ); @@ -234,6 +228,7 @@ DIALOG_COLOR_PICKER_BASE::DIALOG_COLOR_PICKER_BASE( wxWindow* parent, wxWindowID m_spinCtrlBlue->Connect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditBlue ), NULL, this ); m_HsvBitmap->Connect( wxEVT_LEFT_DOWN, wxMouseEventHandler( DIALOG_COLOR_PICKER_BASE::onHSVMouseClick ), NULL, this ); m_HsvBitmap->Connect( wxEVT_MOTION, wxMouseEventHandler( DIALOG_COLOR_PICKER_BASE::onHSVMouseDrag ), NULL, this ); + m_HsvBitmap->Connect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_COLOR_PICKER_BASE::onSize ), NULL, this ); m_spinCtrlHue->Connect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditHue ), NULL, this ); m_spinCtrlSaturation->Connect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditSat ), NULL, this ); m_sliderBrightness->Connect( wxEVT_SCROLL_TOP, wxScrollEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeBrightness ), NULL, this ); @@ -268,6 +263,7 @@ DIALOG_COLOR_PICKER_BASE::~DIALOG_COLOR_PICKER_BASE() m_spinCtrlBlue->Disconnect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditBlue ), NULL, this ); m_HsvBitmap->Disconnect( wxEVT_LEFT_DOWN, wxMouseEventHandler( DIALOG_COLOR_PICKER_BASE::onHSVMouseClick ), NULL, this ); m_HsvBitmap->Disconnect( wxEVT_MOTION, wxMouseEventHandler( DIALOG_COLOR_PICKER_BASE::onHSVMouseDrag ), NULL, this ); + m_HsvBitmap->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_COLOR_PICKER_BASE::onSize ), NULL, this ); m_spinCtrlHue->Disconnect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditHue ), NULL, this ); m_spinCtrlSaturation->Disconnect( wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeEditSat ), NULL, this ); m_sliderBrightness->Disconnect( wxEVT_SCROLL_TOP, wxScrollEventHandler( DIALOG_COLOR_PICKER_BASE::OnChangeBrightness ), NULL, this ); diff --git a/common/dialogs/dialog_color_picker_base.fbp b/common/dialogs/dialog_color_picker_base.fbp index 1922504d55..c0998c90dc 100644 --- a/common/dialogs/dialog_color_picker_base.fbp +++ b/common/dialogs/dialog_color_picker_base.fbp @@ -1,1768 +1,1783 @@ - + - - - - C++ - 1 - source_name - 0 - 0 - res - UTF-8 - connect - dialog_color_picker_base - 1000 - none - - - 1 - DIALOG_COLOR_PICKER_BASE - - . - - 1 - 1 - 1 - 1 - UI - 0 - 0 - 0 - - 0 - wxAUI_MGR_DEFAULT - - wxBOTH - - 1 - 1 - impl_virtual - - - - 0 - wxID_ANY - + + + + C++ + 1 + source_name + 0 + 0 + res + UTF-8 + connect + dialog_color_picker_base + 1000 + none + + + 1 + DIALOG_COLOR_PICKER_BASE + + . + + 1 + 1 + 1 + 1 + UI + 0 + 0 + 0 + + 0 + wxAUI_MGR_DEFAULT + + wxBOTH + + 1 + 0 + 1 + impl_virtual + + + + 0 + wxID_ANY + + + DIALOG_COLOR_PICKER_BASE + + -1,-1 + wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER + DIALOG_SHIM; dialog_shim.h + Color Picker + + 0 + + + + + + bSizerMain + wxVERTICAL + none + + 5 + wxEXPAND + 1 + - DIALOG_COLOR_PICKER_BASE - - -1,-1 - wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER - DIALOG_SHIM; dialog_shim.h - Color Picker - - 0 - - - - + bSizerUpperMain + wxHORIZONTAL + none + + 5 + wxEXPAND | wxALL + 1 + + 1 + 1 + 1 + 1 + + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 - bSizerMain - wxVERTICAL - none - - 5 - wxEXPAND - 0 - - - bSizerUpperMain - wxHORIZONTAL - none - + 1 + m_notebook + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + + + Color Picker + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_panelFreeColors + 1 + + + protected + 1 + + Resizable + 1 + + + 0 + + + + wxTAB_TRAVERSAL + + + bSizerUpperFreeColors + wxVERTICAL + none + + 5 + wxEXPAND + 1 + + + bSizerPanels + wxHORIZONTAL + none + 5 - wxEXPAND | wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_notebook - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - - - Color Picker - 1 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_panelFreeColors - 1 - - - protected - 1 - - Resizable - 1 - - - 0 - - - - wxTAB_TRAVERSAL - - - bSizerUpperFreeColors - wxVERTICAL - none - - 5 - wxEXPAND - 1 - - - bSizerPanels - wxHORIZONTAL - none - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - wxID_ANY - RGB - -1,-1 - sbSizerViewRGB - wxVERTICAL - 1 - none - - 5 - wxALL|wxALIGN_CENTER_HORIZONTAL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - -1,-1 - - 0 - 264,264 - 1 - m_RgbBitmap - 1 - - - protected - 1 - - Resizable - 1 - 264,264 - - 0 - - - - - onRGBMouseClick - onRGBMouseDrag - - - - 5 - wxEXPAND - 0 - - 3 - wxBOTH - 0,1,2 - - 0 - - fgSizerRGB - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 0 - - 5 - wxTOP|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Red: - 0 - - 0 - - - 0 - - 1 - m_staticTextR - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxTOP|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Green: - 0 - - 0 - - - 0 - - 1 - m_staticTextG - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxTOP|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Blue: - 0 - - 0 - - - 0 - - 1 - m_staticTextB - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 128 - 255 - - 0 - - 0 - - 0 - -1,-1 - 1 - m_spinCtrlRed - 1 - - - protected - 1 - - Resizable - 1 - - wxSP_ARROW_KEYS - - 0 - - - - - - OnChangeEditRed - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 128 - 255 - - 0 - - 0 - - 0 - -1,-1 - 1 - m_spinCtrlGreen - 1 - - - protected - 1 - - Resizable - 1 - - wxSP_ARROW_KEYS - - 0 - - - - - - OnChangeEditGreen - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 128 - 255 - - 0 - - 0 - - 0 - -1,-1 - 1 - m_spinCtrlBlue - 1 - - - protected - 1 - - Resizable - 1 - - wxSP_ARROW_KEYS - - 0 - - - - - - OnChangeEditBlue - - - - - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT - 0 - - wxID_ANY - HSV - - sbSizerViewHSV - wxHORIZONTAL - 1 - none - - 5 - wxEXPAND - 0 - - - bSizer10 - wxVERTICAL - none - - 5 - wxALL|wxALIGN_CENTER_HORIZONTAL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - -1,-1 - - 0 - 264,264 - 1 - m_HsvBitmap - 1 - - - protected - 1 - - Resizable - 1 - 264,264 - - 0 - - - - - onHSVMouseClick - onHSVMouseDrag - - - - 5 - wxEXPAND - 0 - - 2 - wxBOTH - 0,1 - - 0 - - fgSizerHSV - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 0 - - 5 - wxTOP|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Hue: - 0 - - 0 - - - 0 - - 1 - m_staticTextHue - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxTOP|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Saturation: - 0 - - 0 - - - 0 - - 1 - m_staticTextSat - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 0 - 359 - - 0 - - 0 - - 0 - -1,-1 - 1 - m_spinCtrlHue - 1 - - - protected - 1 - - Resizable - 1 - - wxSP_ARROW_KEYS|wxSP_WRAP - - 0 - - - - - - OnChangeEditHue - - - - 5 - wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 128 - 255 - - 0 - - 0 - - 0 - -1,-1 - 1 - m_spinCtrlSaturation - 1 - - - protected - 1 - - Resizable - 1 - - wxSP_ARROW_KEYS - - 0 - - - - - - OnChangeEditSat - - - - - - - - 5 - wxEXPAND - 0 - - - bSizerBright - wxVERTICAL - none - - 5 - wxALL|wxALIGN_CENTER_HORIZONTAL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Value: - 0 - - 0 - - - 0 - - 1 - m_staticTextBright - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxTOP - 1 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 255 - - 0 - - 0 - - 0 - - 1 - m_sliderBrightness - 1 - - - protected - 1 - - Resizable - 1 - - wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - 255 - - - - OnChangeBrightness - - - - - - - - - - - - - - Defined Colors - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - - 1 - m_panelDefinedColors - 1 - - - protected - 1 - - Resizable - 1 - - - 0 - - - - wxTAB_TRAVERSAL - - - m_SizerDefinedColors - wxVERTICAL - protected - - 10 - wxALL|wxEXPAND - 1 - - 10 - wxBOTH - 1,3,5,7,9 - - 5 - - m_fgridColor - wxFLEX_GROWMODE_SPECIFIED - protected - 0 - 25 - - - - - - - - - 5 - wxEXPAND|wxRIGHT|wxLEFT - 0 - - - m_SizerTransparency - wxVERTICAL - protected - - 5 - wxTOP - 0 - - 20 - protected - 0 - - - - 5 - wxALIGN_CENTER_HORIZONTAL|wxTOP|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Opacity: - 0 - - 0 - - - 0 - - 1 - m_opacityLabel - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 10 - wxTOP|wxBOTTOM|wxRIGHT|wxALIGN_CENTER_HORIZONTAL - 1 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - 100 - - 0 - - 0 - - 0 - - 1 - m_sliderTransparency - 1 - - - protected - 1 - - Resizable - 1 - - wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - 80 - - - - OnChangeAlpha - - - - - - 5 - wxEXPAND|wxRIGHT|wxLEFT + wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT 1 - - 0 - protected - 0 + + wxID_ANY + RGB + -1,-1 + sbSizerViewRGB + wxVERTICAL + 1 + none + + 5 + wxALIGN_CENTER_HORIZONTAL|wxALL|wxEXPAND|wxSHAPED + 0 + + 1 + 1 + 1 + 1 + + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + -1,-1 + + 0 + 264,264 + 1 + m_RgbBitmap + 1 + + + protected + 1 + + Resizable + 1 + 264,264 + + 0 + + + + + onRGBMouseClick + onRGBMouseDrag + + + + 5 + wxEXPAND + 1 + + 0 + protected + 0 + + + + 5 + wxEXPAND + 0 + + 3 + wxBOTH + 0,1,2 + + 0 + + fgSizerRGB + wxFLEX_GROWMODE_SPECIFIED + none + 0 + 0 + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Red: + 0 + + 0 + + + 0 + + 1 + m_staticTextR + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Green: + 0 + + 0 + + + 0 + + 1 + m_staticTextG + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Blue: + 0 + + 0 + + + 0 + + 1 + m_staticTextB + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 128 + 255 + + 0 + + 0 + + 0 + -1,-1 + 1 + m_spinCtrlRed + 1 + + + protected + 1 + + Resizable + 1 + + wxSP_ARROW_KEYS + + 0 + + + + + + OnChangeEditRed + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 128 + 255 + + 0 + + 0 + + 0 + -1,-1 + 1 + m_spinCtrlGreen + 1 + + + protected + 1 + + Resizable + 1 + + wxSP_ARROW_KEYS + + 0 + + + + + + OnChangeEditGreen + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 128 + 255 + + 0 + + 0 + + 0 + -1,-1 + 1 + m_spinCtrlBlue + 1 + + + protected + 1 + + Resizable + 1 + + wxSP_ARROW_KEYS + + 0 + + + + + + OnChangeEditBlue + + + + - - - - - 10 - wxEXPAND|wxLEFT - 1 - - - bButtonsSizer - wxHORIZONTAL - none - + + 5 - wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Preview (old/new): - 0 - - 0 - - - 0 - - 1 - m_staticTextOldColor - 1 - - - protected - 1 - - Resizable - 1 - - - - 0 - - - - - -1 - - - - 5 - wxALIGN_CENTER_VERTICAL|wxLEFT - 0 - - 1 - 1 - 1 - 1 - - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - 24,24 - 1 - m_OldColorRect - 1 - - - protected - 1 - - Resizable - 1 - -1,-1 - - 0 - - - - - - - - 5 - wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - 0 - 24,24 - 1 - m_NewColorRect - 1 - - - protected - 1 - - Resizable - 1 - -1,-1 - - 0 - - - - - - - - 5 - wxEXPAND - 0 - - 0 - protected - 10 - - - - 5 - wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - 0 - - - - 0 - 176,-1 - 1 - m_colorValue - 1 - - - protected - 1 - - Resizable - 1 - - - ; ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - OnColorValueText - - - - 5 - wxEXPAND - 0 - - 0 - protected - 20 - - - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 0 - - - - - 1 - 0 - 1 - - 1 - - 0 - 0 - - Dock - 0 - Left - 1 - - 1 - - - 0 - 0 - wxID_ANY - Reset to Default - - 0 - - 0 - - - 0 - - 1 - m_resetToDefault - 1 - - - protected - 1 - - - - Resizable - 1 - - - ; ; forward_declare - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnResetButton - - - - 5 - wxALL + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT 1 - - 0 - 1 - 0 - 0 - 0 - 1 - 0 - 0 - - m_sdbSizer - protected + + wxID_ANY + HSV + + sbSizerViewHSV + wxVERTICAL + 1 + none + + 5 + wxALIGN_CENTER_HORIZONTAL|wxALL|wxEXPAND|wxSHAPED + 0 + + 1 + 1 + 1 + 1 + + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + -1,-1 + + 0 + 264,264 + 1 + m_HsvBitmap + 1 + + + protected + 1 + + Resizable + 1 + 264,264 + + 0 + + + + + onHSVMouseClick + onHSVMouseDrag + onSize + + + + 5 + wxEXPAND + 1 + + 0 + protected + 0 + + + + 5 + wxEXPAND + 0 + + 2 + wxBOTH + 0,1 + + 0 + + fgSizerHSV + wxFLEX_GROWMODE_SPECIFIED + none + 0 + 0 + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Hue: + 0 + + 0 + + + 0 + + 1 + m_staticTextHue + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxTOP|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Saturation: + 0 + + 0 + + + 0 + + 1 + m_staticTextSat + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 0 + 359 + + 0 + + 0 + + 0 + -1,-1 + 1 + m_spinCtrlHue + 1 + + + protected + 1 + + Resizable + 1 + + wxSP_ARROW_KEYS|wxSP_WRAP + + 0 + + + + + + OnChangeEditHue + + + + 5 + wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 128 + 255 + + 0 + + 0 + + 0 + -1,-1 + 1 + m_spinCtrlSaturation + 1 + + + protected + 1 + + Resizable + 1 + + wxSP_ARROW_KEYS + + 0 + + + + + + OnChangeEditSat + + + + + + + 5 + wxALL|wxEXPAND + 0 + + + bSizerBright + wxVERTICAL + none + + 5 + wxALL|wxALIGN_CENTER_HORIZONTAL + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Value: + 0 + + 0 + + + 0 + + 1 + m_staticTextBright + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxTOP + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 255 + + 0 + + 0 + + 0 + + 1 + m_sliderBrightness + 1 + + + protected + 1 + + Resizable + 1 + + wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + 255 + + + + OnChangeBrightness + + + + + + + + + Defined Colors + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + + 1 + m_panelDefinedColors + 1 + + + protected + 1 + + Resizable + 1 + + + 0 + + + + wxTAB_TRAVERSAL + + + m_SizerDefinedColors + wxVERTICAL + protected + + 10 + wxALL|wxEXPAND + 1 + + 10 + wxBOTH + 1,3,5,7,9 + + 5 + + m_fgridColor + wxFLEX_GROWMODE_SPECIFIED + protected + 0 + 25 + + + + + + + + 5 + wxEXPAND|wxRIGHT|wxLEFT + 0 + + + m_SizerTransparency + wxVERTICAL + protected + + 5 + wxTOP + 0 + + 20 + protected + 0 + + + + 5 + wxALIGN_CENTER_HORIZONTAL|wxTOP|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Opacity: + 0 + + 0 + + + 0 + + 1 + m_opacityLabel + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 10 + wxTOP|wxBOTTOM|wxRIGHT|wxALIGN_CENTER_HORIZONTAL + 1 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + 100 + + 0 + + 0 + + 0 + + 1 + m_sliderTransparency + 1 + + + protected + 1 + + Resizable + 1 + + wxSL_INVERSE|wxSL_LABELS|wxSL_LEFT|wxSL_VERTICAL + + 0 + + + wxFILTER_NONE + wxDefaultValidator + + 80 + + + + OnChangeAlpha + + + + + + + 10 + wxEXPAND|wxLEFT + 0 + + + bButtonsSizer + wxHORIZONTAL + none + + 5 + wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + Preview (old/new): + 0 + + 0 + + + 0 + + 1 + m_staticTextOldColor + 1 + + + protected + 1 + + Resizable + 1 + + + + 0 + + + + + -1 + + + + 5 + wxALIGN_CENTER_VERTICAL|wxSHAPED + 0 + + 1 + 1 + 1 + 1 + + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + 24,24 + 1 + m_OldColorRect + 1 + + + protected + 1 + + Resizable + 1 + -1,-1 + + 0 + + + + + + + + 5 + wxALIGN_CENTER_VERTICAL|wxSHAPED + 0 + + 1 + 1 + 1 + 1 + + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + 0 + 24,24 + 1 + m_NewColorRect + 1 + + + protected + 1 + + Resizable + 1 + -1,-1 + + 0 + + + + + + + + 5 + wxALIGN_CENTER_VERTICAL|wxLEFT + 0 + + 1 + 1 + 1 + 1 + + + + + + + + 1 + 0 + 1 + + 1 + 0 + Dock + 0 + Left + 0 + 1 + + 1 + + 0 + 0 + wxID_ANY + + 0 + + + + 0 + 176,-1 + 1 + m_colorValue + 1 + + + protected + 1 + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + + OnColorValueText + + + + 5 + wxEXPAND + 0 + + 0 + protected + 20 + + + + 5 + wxALL|wxALIGN_CENTER_VERTICAL + 0 + + 1 + 1 + 1 + 1 + + + + + 0 + + + + + 1 + 0 + 1 + + 1 + + 0 + 0 + + Dock + 0 + Left + 0 + 1 + + 1 + + + 0 + 0 + wxID_ANY + Reset to Default + + 0 + + 0 + + + 0 + + 1 + m_resetToDefault + 1 + + + protected + 1 + + + + Resizable + 1 + + + ; ; forward_declare + 0 + + + wxFILTER_NONE + wxDefaultValidator + + + + + OnResetButton + + + + 5 + wxALL + 1 + + 0 + 1 + 0 + 0 + 0 + 1 + 0 + 0 + + m_sdbSizer + protected + + + + + + diff --git a/common/dialogs/dialog_color_picker_base.h b/common/dialogs/dialog_color_picker_base.h index 1120bab611..3817e3f958 100644 --- a/common/dialogs/dialog_color_picker_base.h +++ b/common/dialogs/dialog_color_picker_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version 3.10.1-0-g8feb16b) +// C++ code generated with wxFormBuilder (version 4.1.0-0-g733bf3d) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -81,6 +81,7 @@ class DIALOG_COLOR_PICKER_BASE : public DIALOG_SHIM virtual void OnChangeEditBlue( wxSpinEvent& event ) { event.Skip(); } virtual void onHSVMouseClick( wxMouseEvent& event ) { event.Skip(); } virtual void onHSVMouseDrag( wxMouseEvent& event ) { event.Skip(); } + virtual void onSize( wxSizeEvent& event ) { event.Skip(); } virtual void OnChangeEditHue( wxSpinEvent& event ) { event.Skip(); } virtual void OnChangeEditSat( wxSpinEvent& event ) { event.Skip(); } virtual void OnChangeBrightness( wxScrollEvent& event ) { event.Skip(); } diff --git a/include/dialogs/dialog_color_picker.h b/include/dialogs/dialog_color_picker.h index a97ca18da7..315809500c 100644 --- a/include/dialogs/dialog_color_picker.h +++ b/include/dialogs/dialog_color_picker.h @@ -1,7 +1,7 @@ /* * This program source code file is part of KiCad, a free EDA CAD application. * - * Copyright (C) 2018-2021 KiCad Developers, see AUTHORS.txt for contributors. + * Copyright (C) 2018-2024 KiCad Developers, see AUTHORS.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 @@ -156,6 +156,8 @@ private: void onHSVMouseClick( wxMouseEvent& event ) override; void onHSVMouseDrag( wxMouseEvent& event ) override; + void onSize( wxSizeEvent& event ) override; + void OnColorValueText( wxCommandEvent& event ) override; ///< Event handler for the reset button press @@ -187,6 +189,8 @@ private: */ void initDefinedColors( CUSTOM_COLORS_LIST* aPredefinedColors ); + void updateHandleSize(); + // convert double value 0 ... 1 to int 0 ... aValMax int normalizeToInt( double aValue, int aValMax = 255 ) {