QT5 label text
續前篇: QT5 Widget Button
程式: github
- label 的前景和背景色可以用 setStyleSheet 來做
對齊方式:
執行結果:
Ref: QT 字型
列出支援繁體字的字型
程式:
QFontDatabase database;
foreach(const QString &family, database.families(QFontDatabase::TraditionalChinese)) {
qDebug() << family;
}
".PingFang HK"
".PingFang TC"
"Adobe Fan Heiti Std"
"Adobe Ming Std"
"Apple LiGothic"
"Apple LiSung"
"Arial Unicode MS"
"Baoli TC"
"BiauKai"
"Hannotate TC"
"HanziPen TC"
"Heiti SC"
"Heiti TC"
"Hiragino Sans CNS"
"Kaiti TC"
"Lantinghei TC"
"Libian TC"
"LiHei Pro"
"LingWai TC"
"LiSong Pro"
"PingFang HK"
"PingFang TC"
"Songti TC"
"Wawati TC"
"Weibei TC"
"Xingkai TC"
"Yuanti TC"
"Yuppy TC"
留言
張貼留言