日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

qt使用ttf在2440上字体太小的问题

發布時間:2024/1/18 编程问答 36 豆豆
生活随笔 收集整理的這篇文章主要介紹了 qt使用ttf在2440上字体太小的问题 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

使用windows的ttf字體,發現字體都變得看不到了,找到這篇博客,還有其朋友做過的都是設置QWS_DISPLAY,變量,

http://stackoverflow.com/questions/15475971/text-size-and-style-differs-in-qt-desktop-and-embedded-applications


抄選關鍵部分:

Rebuilt Qt Embedded with freetype support (-qt-freetype option) and get desired result. Also it was needed to play with QWS_DISPLAY variable (mmWidth and mmHeight options), the value QWS_DISPLAY=LinuxFB:mmWidth=250:mmHeight=150 seems to be the best solution for my 7 inch touchscreen (previous value QWS_DISPLAY=LinuxFB:mmWidth=800:mmHeight=480 results in too small font size with freetype-supported Qt lib).?



Building Qt Embedded with freetype support solved the problem。


我設置的參數為

export QWS_DISPLAY=LinuxFB:mmWidth162:mmHeight121:0
export QWS_SIZE=800x600


1,也具體不知道那個mmwidth是什么意思,就按照屏幕的寬度是162mm,高度是121mm設置上去。看起來效果還可以,字體大小也差不多。

2,我也不知道我的qt是否編譯了freetype,好像默認是使用了系統 的freetype庫,反正現在是可以用了。


關于mmwidth, mmheight的解釋:

http://qt-project.org/doc/qt-4.8/qt-embedded-displaymanagement.html

總結

以上是生活随笔為你收集整理的qt使用ttf在2440上字体太小的问题的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。