获取控件的宽度和高度 [英] Getting width and height of controls

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

问题描述

大家好,我已经为我的项目制作了一个屏幕截图并将其粘贴到MS Paint中.现在,我想在该屏幕截图中获得正确的控件宽度和高度,从而可以在对话框中放置更多控件宽度和高度.我该如何移动?请帮助我.您还可以使用其他各种复杂的图像编辑器.


实际上,我不确定您是否希望使用程序或在mspaint的帮助下控制控件的宽度和高度. >
1)如果使用mspaint,则可以首先从工具中选择放大镜",并将其范围选择为8x,然后按"Ctrl + g",然后检查控件的宽度和高度.

2)使用GetRect()获取控件的大小,并借助矩形获得控件的宽度和高度.


hi all, i''ve taken a screenshot of my project and paste that in MS Paint.now i want to get the correct width and height of controls in that screenshot, thereby i can place more controls in my dialog with same width and height.how can i move with this?please help me,plase..

解决方案

Use Adobe Photoshop, there you have ruler and scale to measure pixels. There are various other complex image editors which you can take in handy.


Actually I am not sure that you want your control width and height using program or with the help of mspaint.

1) If using mspaint than you can first select "magnifier" from the tool and select its range to 8x and than press "Ctrl + g" and than check the width and height of the control.

2)Use GetRect() to get the size of control and with the help of the rectangle you get you can find the width and height of control.


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

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