Add multiple size icons for programs
In theory, the WM should now choose the closest size icon for its purpose, making it easier to distinguish in space-constrained settings Fixes https://gitlab.com/kicad/code/kicad/issues/6798
This commit is contained in:
parent
9828f56c08
commit
61ac9c8d90
|
@ -171,8 +171,16 @@ BM2CMP_FRAME::BM2CMP_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_bitmap2component_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_bitmap2component_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_bitmap2component_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
GetSizer()->SetSizeHints( this );
|
||||
|
||||
|
|
|
@ -242,7 +242,7 @@ EXTERN_BITMAP( icon_pcbnew_16_xpm )
|
|||
EXTERN_BITMAP( icon_bitmap2component_32_xpm )
|
||||
EXTERN_BITMAP( icon_eeschema_32_xpm )
|
||||
EXTERN_BITMAP( icon_gerbview_32_xpm )
|
||||
EXTERN_BITMAP( icon_kicad_132_xpm )
|
||||
EXTERN_BITMAP( icon_kicad_32_xpm )
|
||||
EXTERN_BITMAP( icon_libedit_32_xpm )
|
||||
EXTERN_BITMAP( icon_modedit_32_xpm )
|
||||
EXTERN_BITMAP( icon_pagelayout_editor_32_xpm )
|
||||
|
|
|
@ -222,8 +222,16 @@ SCH_EDIT_FRAME::SCH_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_eeschema_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_eeschema_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_eeschema_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
LoadSettings( eeconfig() );
|
||||
|
||||
|
|
|
@ -111,8 +111,16 @@ SYMBOL_EDIT_FRAME::SYMBOL_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
m_aboutTitle = _( "Symbol Editor" );
|
||||
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_libedit_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_libedit_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_libedit_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
m_settings = Pgm().GetSettingsManager().GetAppSettings<SYMBOL_EDITOR_SETTINGS>();
|
||||
LoadSettings( m_settings );
|
||||
|
|
|
@ -111,8 +111,16 @@ GERBVIEW_FRAME::GERBVIEW_FRAME( KIWAY* aKiway, wxWindow* aParent )
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_gerbview_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_gerbview_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_gerbview_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
// Be sure a page info is set. this default value will be overwritten later.
|
||||
PAGE_INFO pageInfo( wxT( "GERBER" ) );
|
||||
|
|
|
@ -112,8 +112,16 @@ KICAD_MANAGER_FRAME::KICAD_MANAGER_FRAME( wxWindow* parent, const wxString& titl
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_kicad_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_kicad_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_kicad_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
// Load the settings
|
||||
LoadSettings( config() );
|
||||
|
|
|
@ -97,8 +97,16 @@ PL_EDITOR_FRAME::PL_EDITOR_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pagelayout_editor_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pagelayout_editor_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pagelayout_editor_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
// Create GAL canvas
|
||||
auto* drawPanel = new PL_DRAW_PANEL_GAL( this, -1, wxPoint( 0, 0 ), m_frameSize,
|
||||
|
|
|
@ -87,8 +87,16 @@ PCB_CALCULATOR_FRAME::PCB_CALCULATOR_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbcalculator_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbcalculator_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbcalculator_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
GetSizer()->SetSizeHints( this );
|
||||
|
||||
|
|
|
@ -121,8 +121,16 @@ FOOTPRINT_EDIT_FRAME::FOOTPRINT_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent,
|
|||
|
||||
// Give an icon
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_modedit_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_modedit_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_modedit_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
// Create GAL canvas
|
||||
if( aBackend == EDA_DRAW_PANEL_GAL::GAL_TYPE_UNKNOWN )
|
||||
|
|
|
@ -197,9 +197,17 @@ PCB_EDIT_FRAME::PCB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
|
||||
SetBoard( new BOARD() );
|
||||
|
||||
wxIcon icon;
|
||||
wxIcon icon;
|
||||
wxIconBundle icon_bundle;
|
||||
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbnew_xpm ) );
|
||||
SetIcon( icon );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbnew_32_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
icon.CopyFromBitmap( KiBitmap( icon_pcbnew_16_xpm ) );
|
||||
icon_bundle.AddIcon( icon );
|
||||
|
||||
SetIcons( icon_bundle );
|
||||
|
||||
// LoadSettings() *after* creating m_LayersManager, because LoadSettings()
|
||||
// initialize parameters in m_LayersManager
|
||||
|
|
Loading…
Reference in New Issue