如何重置 Qt 窗口字体的大小? [英] How to reset the size of the Qt's window font?

查看:126
本文介绍了如何重置 Qt 窗口字体的大小?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我把我的电脑开了一整夜,早上我注意到,QtCreator 中的窗口字体比原来大得多,虽然不是无处不在.文本编辑器、菜单和侧面板以通常的字体大小显示(参见第一个屏幕截图).我还注意到,此更改会影响其他 Qt 程序,例如维护工具和 QtLinguist.

I have left my computer on overnight and in the morning I have noticed, that the font of the windows in QtCreator is significantly bigger as it was, though not everywhere. The text editor, the menu and the side panels are shown with the usual font size (see the first screenshot). I have also noticed, that this change affects other Qt programs, as the Maintenance tool and QtLinguist.

图例: 红色 - 巨大的字体,应该重新设置.Green - 字体应有的样子.

Legend: Red - huge font, should be reset. Green - font is as it should be.

所有其他已安装程序的字体大小不变.以防万一我检查了 Windows 的显示设置,并且比例是 100%,原来的位置.

The font size of all other installed programs is unchanged. Just in case I have checked the display settings of Windows and the scale is at 100%, where it was.

注意:我曾尝试删除 user/AppData... 下的设置,但没有帮助.

Note: I have tried deleting the settings under user/AppData..., but it didn't help.

如何重置字体恢复正常?

How to reset the font back to normal?

推荐答案

对于改变源代码中字体的大小,你可以使用快捷方式(编辑器聚焦)

for changing the size of the font in the source code you can use the short cuts (with the editor focused)

放大:ctrl"和+"

to zoom in: "ctrl" and "+"

缩小:ctrl"和-"

to zoom out: "ctrl" and "-"

对于环境,您可以设置环境变量

for the environment the you can set the environment variable

export QT_SCALE_FACTOR=1.5

这篇关于如何重置 Qt 窗口字体的大小?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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