Is there a standard for toolbar icon dimensions based on DPI?

夙愿已清 提交于 2020-02-25 13:17:49

问题


I have a 32 pixel toolbar:

Is there a known standard for using different pixel heights for the toolbar based on different DPI configurations? If so, can you please point in in the right direction of this resource?

The only thing I have located about this concept is here and I quote the example pseudo code:

UINT smallToolbarID;
if ( DPI == smaller )
{
  smallToolbarID = 16x16;
  largeToolbarID = 32x32
}
else if ( DPI == medium )
{
  smallToolbarID = 20x20;
  largeToolbarID = 40x40
}
else if ( DPI == larger)
{
  smallToolbarID = 24x24;
  largeToolbarID = 48x48
}

In the above link the comment states:

Now if I have to do this "by the book" I would need to generate toolbars with buttons 16x16, 20x20, 24x24, 32x32, 40x40 and 48x48.

I would appreciate guidance for statement.

来源:https://stackoverflow.com/questions/59604082/is-there-a-standard-for-toolbar-icon-dimensions-based-on-dpi

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!