7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-04-11 11:20:09 +00:00

Fix image size in Layer selector in Properties panel on hidpi.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/13105
This commit is contained in:
Alex Shvartzkop 2025-01-20 22:13:45 +03:00
parent 5eed4e41a4
commit 8b24496b79

View File

@ -540,8 +540,12 @@ wxValidator* PGPROPERTY_ANGLE::DoGetValidator() const
wxSize PGPROPERTY_COLORENUM::OnMeasureImage( int aItem ) const
{
// TODO(JE) calculate size from window metrics?
return wxSize( 16, 12 );
wxSize size( 16, -1 );
if( wxPropertyGrid* pg = GetGrid() )
size = pg->FromDIP( size );
return size;
}