Add bitmap bundle support to BITMAP_SCALE

Change a bunch of buttons and toolbars to use it

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14119
This commit is contained in:
Jon Evans
2023-10-22 14:02:06 -04:00
parent 71fb1afe4c
commit eb5b3db063
1038 changed files with 1382 additions and 372 deletions
+15 -1
View File
@@ -107,8 +107,22 @@ wxBitmap KiBitmap( BITMAPS aBitmap, int aHeightTag )
}
wxBitmapBundle KiBitmapBundle( BITMAPS aBitmap )
{
return GetBitmapStore()->GetBitmapBundle( aBitmap );
}
wxBitmapBundle KiDisabledBitmapBundle( BITMAPS aBitmap )
{
return GetBitmapStore()->GetDisabledBitmapBundle( aBitmap );
}
int KiIconScale( wxWindow* aWindow )
{
// For historical reasons, "4" here means unity (no scaling)
#if defined( __WXMSW__)
// Basically don't try and scale within kicad and let wx do its thing
// with wx introducing bitmap bundles, it will auto scale automatically with dpi
@@ -197,4 +211,4 @@ wxBitmap* KiBitmapNew( BITMAPS aBitmap )
wxBitmap* bitmap = new wxBitmap( GetBitmapStore()->GetBitmap( aBitmap ) );
return bitmap;
}
}