如何(以编程方式)确定Windows 7 PC上是否正在使用大字体 [英] How can you tell (programmatically) if large fonts are in use on a Windows 7 PC
本文介绍了如何(以编程方式)确定Windows 7 PC上是否正在使用大字体的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要从C ++编写的应用程序中确定Windows 7上是否正在使用大字体.任何帮助将不胜感激.
I need to identify whether or not large fonts are in use on Windows 7 from within an app written in C++. Any assistance would be appreciated.
推荐答案
在MFC中:
void CTestFontDlg::OnBnClickedButton1()
{
CDC* pDC = GetDC();
int nRes = GetDeviceCaps(*pDC, LOGPIXELSY);
}
普通字体大小= 96(100%),中(125%)= 120 ...
Normal font size = 96 (100%), medium (125%)= 120...
这篇关于如何(以编程方式)确定Windows 7 PC上是否正在使用大字体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文