更改ListViewItem的边界 [英] Change ListViewItem Bounds
本文介绍了更改ListViewItem的边界的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有办法在LargeIcon模式下的所有的ListView项目的范围设置为特定的大小?
Is there any way to set the bounds of a all ListView items in LargeIcon mode to a specific size?
欲手动绘制为每一个项目的圆角矩形背景,但在DrawItem事件e.Bounds异基于该项目的状态。
I want to manually draw a rounded rectangle background for each of the items, but in the DrawItem event e.Bounds differs based on the state of the items.
感谢。
推荐答案
使用<一个href=\"http://msdn.microsoft.com/en-us/library/system.windows.forms.systeminformation.iconspacingsize.aspx\"相对=nofollow> SystemInformation.IconSpacingSize 发现用于安排LargeIcon模式图标网格方块的大小。
Use SystemInformation.IconSpacingSize to discover the size of the grid square used to arrange icons in LargeIcon mode.
这篇关于更改ListViewItem的边界的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文