MCPcopy Create free account
hub / github.com/PyQt5/PyQtClient / loadFont

Method loadFont

Utils/ThemeManager.py:298–306  ·  view source on GitHub ↗

加载字体

(cls)

Source from the content-addressed store, hash-verified

296
297 @classmethod
298 def loadFont(cls):
299 """加载字体
300 """
301 ThemeManager.ThemeName = Setting.value('theme', 'Default', str)
302 # 加载主题中的字体
303 path = cls.fontPath()
304 AppLog.info('fontPath: {}'.format(path))
305 if os.path.isfile(path):
306 QFontDatabase.addApplicationFont(path)
307
308 @classmethod
309 def loadUserTheme(cls, theme='Default'):

Callers 1

_initUiMethod · 0.80

Calls 2

fontPathMethod · 0.80
valueMethod · 0.45

Tested by

no test coverage detected