Windows 7和ListView控件. [英] Windows 7 and the ListView control.

查看:117
本文介绍了Windows 7和ListView控件.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我们的应用程序中,我们有一个标准的ListView,不需要任何滚动条即可显示26行.

在Windows 7中运行该应用程序时,相同的ListView 在清晰可见的位置仅显示21行,您必须滚动才能看到其余部分.

显然,Windows 7渲染ListViewItem 更大,具有更大的间距或填充或其他内容.

如何在不更改字体大小的情况下对此进行补偿?它需要显示与Windows XP中相同的行数,而无需滚动.我可以以某种方式访问​​ListViewItem上的padding或interval属性吗?

到目前为止,对答案的回答是-
Jason9825:ListView的大小不是问题,而是ListView内的行的大小,即ListViewItems.

Abhinav S:不,这不是解决问题.

danberlove:为什么要执行此操作无关紧要,我们应该重点关注的问题是如何完成此操作.

In our application we have a standard ListView, displaying 26 lines without requiring any scrollbars.

When running the application in Windows 7, the same ListView displays only 21 lines in plain sight and you have to scroll to see the rest.

Obviously, Windows 7 renders the ListViewItem larger, with more spacing or padding or something.

How do I compensate for this without changing the font size? It needs to display the same amount of rows as in Windows XP without scrolling. Can I somehow access a padding or spacing property on a ListViewItem?

In reply to the answers give thus far -
Jason9825: The ListView''s sizing is not the problem, but rather the size of the rows WITHIN the listview, I.E, the ListViewItems.

Abhinav S: No, it''s not a resolution problem.

danberlove: The question of WHY I want to do this is irrelevant, the question we should focus on is HOW can this be done.

推荐答案

不是一个答案我"恐怕,就像我注意到的那样,通过MonthCalendar控件加入一样……在Weven下,它的体积要大得多,这导致了我在现有应用程序中的一些布局问题. :mad:
Not an answer I''m afraid, just joining in as I noticed the same sort of thing with the MonthCalendar control... it is quite a lot larger under Weven which caused me some layout issues in an existing application. :mad:


Windows窗体上的AutoSizeMode属性如何?通过按比例增加Windows窗体的大小,这是否可以弥补日益增长的ListBox?只是一个疯狂的猜测.
What about the AutoSizeMode property on the Windows Form? Does that compensate for the growing ListBox by proportionally increasing the size of the Windows Form? Just a wild guess.


这顶帽子,这可能是一个简单的解决问题吗?
Off the top of my hat, could this be a simple resolution issue?


这篇关于Windows 7和ListView控件.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆